Merge "Allow creating EAP_TLS network without specifying Phase2.None" into lmp-dev
diff --git a/Android.mk b/Android.mk
index d0c8070..6a9da2f 100644
--- a/Android.mk
+++ b/Android.mk
@@ -347,14 +347,14 @@
 	media/java/android/media/tv/ITvInputSessionCallback.aidl \
 	media/java/android/service/media/IMediaBrowserService.aidl \
 	media/java/android/service/media/IMediaBrowserServiceCallbacks.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 \
+	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 \
diff --git a/CleanSpec.mk b/CleanSpec.mk
index 547ec6c..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)
@@ -223,6 +223,7 @@
 $(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 69f55fb..293dca6 100644
--- a/api/current.txt
+++ b/api/current.txt
@@ -225,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
@@ -260,7 +232,6 @@
 
   public static final class R.attr {
     ctor public R.attr();
-    field public static final int __removed2 = 16843937; // 0x10104a1
     field public static final int absListViewStyle = 16842858; // 0x101006a
     field public static final int accessibilityEventTypes = 16843648; // 0x1010380
     field public static final int accessibilityFeedbackType = 16843650; // 0x1010382
@@ -325,9 +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 ambientShadowAlpha = 16843967; // 0x10104bf
+    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
@@ -406,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
@@ -459,18 +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 = 16843962; // 0x10104ba
+    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 country = 16843963; // 0x10104bb
+    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
@@ -479,8 +450,8 @@
     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 dayOfWeekBackground = 16843924; // 0x1010494
@@ -583,14 +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 = 16843981; // 0x10104cd
+    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
@@ -604,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
@@ -614,20 +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 = 16843977; // 0x10104c9
-    field public static final int fragmentAllowReturnTransitionOverlap = 16843978; // 0x10104ca
+    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 = 16843972; // 0x10104c4
-    field public static final int fragmentExitTransition = 16843971; // 0x10104c3
+    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 = 16843976; // 0x10104c8
-    field public static final int fragmentReturnTransition = 16843974; // 0x10104c6
-    field public static final int fragmentSharedElementEnterTransition = 16843973; // 0x10104c5
-    field public static final int fragmentSharedElementReturnTransition = 16843975; // 0x10104c7
+    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
@@ -721,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
@@ -762,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
@@ -847,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
@@ -914,8 +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 = 16843970; // 0x10104c2
-    field public static final int navigationIcon = 16843969; // 0x10104c1
+    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
@@ -929,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
@@ -943,7 +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 = 16843961; // 0x10104b9
+    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
@@ -966,10 +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 = 16843979; // 0x10104cb
+    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
@@ -987,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
@@ -1041,8 +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 = 16843965; // 0x10104bd
-    field public static final int reparentWithOverlay = 16843966; // 0x10104be
+    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
@@ -1063,7 +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 = 16843955; // 0x10104b3
+    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
@@ -1142,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
@@ -1161,7 +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 = 16843968; // 0x10104c0
+    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
@@ -1204,12 +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 strokeAlpha = 16843980; // 0x10104cc
-    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
@@ -1332,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
@@ -1349,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
@@ -1362,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 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
@@ -1398,8 +1343,8 @@
     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 visible = 16843156; // 0x1010194
     field public static final int vmSafeMode = 16843448; // 0x10102b8
@@ -1429,16 +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 = 16843982; // 0x10104ce
+    field public static final int windowActivityTransitions = 16843981; // 0x10104cd
     field public static final int windowAllowEnterTransitionOverlap = 16843836; // 0x101043c
     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
@@ -1457,13 +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 windowSharedElementsUseOverlay = 16843964; // 0x10104bc
+    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
@@ -1525,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
@@ -1750,29 +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 = 16908355; // 0x1020043
+    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
@@ -1781,7 +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 = 16908354; // 0x1020042
+    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
@@ -1816,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
   }
 
@@ -1888,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
@@ -2025,60 +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_Notification = 16974560; // 0x10302e0
-    field public static final int TextAppearance_Material_Notification_Emphasis = 16974565; // 0x10302e5
-    field public static final int TextAppearance_Material_Notification_Info = 16974563; // 0x10302e3
-    field public static final int TextAppearance_Material_Notification_Line2 = 16974562; // 0x10302e2
-    field public static final int TextAppearance_Material_Notification_Time = 16974564; // 0x10302e4
-    field public static final int TextAppearance_Material_Notification_Title = 16974561; // 0x10302e1
-    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_Widget_Toolbar_Subtitle = 16974569; // 0x10302e9
-    field public static final int TextAppearance_Material_Widget_Toolbar_Title = 16974568; // 0x10302e8
-    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
@@ -2104,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
@@ -2139,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
@@ -2177,41 +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_Alert = 16974570; // 0x10302ea
-    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_Dialog_Presentation = 16974571; // 0x10302eb
-    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_Alert = 16974572; // 0x10302ec
-    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_Dialog_Presentation = 16974573; // 0x10302ed
-    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
@@ -2273,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
@@ -2307,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
@@ -2331,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
@@ -2355,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
@@ -2366,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
@@ -2491,137 +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_DatePicker = 16974578; // 0x10302f2
-    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_SearchView = 16974575; // 0x10302ef
-    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_Underlined = 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_Light_TimePicker = 16974577; // 0x10302f1
+    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_SearchView = 16974574; // 0x10302ee
-    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_Underlined = 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_TimePicker = 16974576; // 0x10302f0
-    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
@@ -2636,48 +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 __removed1 = 16974559; // 0x10302df
-    field public static final int __removed3 = 16974341; // 0x1030205
-    field public static final int __removed4 = 16974342; // 0x1030206
-    field public static final int __removed5 = 16974343; // 0x1030207
-    field public static final int __removed6 = 16974344; // 0x1030208
-    field public static final int __removed7 = 16974345; // 0x1030209
-    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 {
@@ -7386,7 +7239,7 @@
     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";
@@ -28197,11 +28050,11 @@
 
 }
 
-package android.telecomm {
+package android.telecom {
 
   public final class AudioState implements android.os.Parcelable {
     ctor public AudioState(boolean, int, int);
-    ctor public AudioState(android.telecomm.AudioState);
+    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;
@@ -28216,20 +28069,20 @@
   }
 
   public abstract class Conference {
-    ctor public Conference(android.telecomm.PhoneAccountHandle);
-    method public final boolean addConnection(android.telecomm.Connection);
+    ctor public Conference(android.telecom.PhoneAccountHandle);
+    method public final boolean addConnection(android.telecom.Connection);
     method public final void destroy();
     method public final int getCapabilities();
-    method public final java.util.List<android.telecomm.Connection> getConnections();
-    method public final android.telecomm.PhoneAccountHandle getPhoneAccountHandle();
+    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 onDisconnect();
     method public void onHold();
     method public void onMerge();
-    method public void onSeparate(android.telecomm.Connection);
+    method public void onSeparate(android.telecom.Connection);
     method public void onSwap();
     method public void onUnhold();
-    method public final void removeConnection(android.telecomm.Connection);
+    method public final void removeConnection(android.telecom.Connection);
     method public final void setActive();
     method public final void setCapabilities(int);
     method public final void setDisconnected(int, java.lang.String);
@@ -28238,27 +28091,27 @@
 
   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(int, java.lang.String);
     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 android.telecomm.Conference getConference();
-    method public final java.util.List<android.telecomm.Connection> getConferenceableConnections();
+    method public final android.telecom.Conference getConference();
+    method public final java.util.List<android.telecom.Connection> getConferenceableConnections();
     method public final int getDisconnectCause();
     method public final java.lang.String getDisconnectMessage();
     method public final int getState();
-    method public final android.telecomm.StatusHints getStatusHints();
+    method public final android.telecom.StatusHints getStatusHints();
     method public final boolean isRingbackRequested();
     method public void onAbort();
     method public void onAnswer();
-    method public void onAudioStateChanged(android.telecomm.AudioState);
-    method public void onConferenceWith(android.telecomm.Connection);
+    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 onPlayDtmfTone(char);
@@ -28273,8 +28126,8 @@
     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 setConferenceableConnections(java.util.List<android.telecomm.Connection>);
-    method public final void setConnectionService(android.telecomm.ConnectionService);
+    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 setInitialized();
@@ -28283,7 +28136,7 @@
     method public final void setPostDialWait(java.lang.String);
     method public final void setRingbackRequested(boolean);
     method public final void setRinging();
-    method public final void setStatusHints(android.telecomm.StatusHints);
+    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_DIALING = 3; // 0x3
@@ -28295,9 +28148,9 @@
   }
 
   public final class ConnectionRequest implements android.os.Parcelable {
-    ctor public ConnectionRequest(android.telecomm.PhoneAccountHandle, android.net.Uri, android.os.Bundle);
+    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 void writeToParcel(android.os.Parcel, int);
@@ -28306,17 +28159,17 @@
 
   public abstract class ConnectionService extends android.app.Service {
     ctor public ConnectionService();
-    method public final void addConference(android.telecomm.Conference);
-    method public final void conferenceRemoteConnections(android.telecomm.RemoteConnection, android.telecomm.RemoteConnection);
-    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 onConference(android.telecomm.Connection, 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);
-    method public void onRemoteConferenceAdded(android.telecomm.RemoteConference);
-    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 class GatewayInfo implements android.os.Parcelable {
@@ -28330,9 +28183,9 @@
   }
 
   public class PhoneAccount implements android.os.Parcelable {
-    method public static android.telecomm.PhoneAccount.Builder builder(android.telecomm.PhoneAccountHandle, java.lang.CharSequence);
+    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.graphics.drawable.Drawable getIcon(android.content.Context);
@@ -28355,15 +28208,15 @@
   }
 
   public static class PhoneAccount.Builder {
-    ctor public PhoneAccount.Builder(android.telecomm.PhoneAccountHandle, java.lang.CharSequence);
-    ctor public PhoneAccount.Builder(android.telecomm.PhoneAccount);
-    method public android.telecomm.PhoneAccount build();
-    method public android.telecomm.PhoneAccount.Builder setAddress(android.net.Uri);
-    method public android.telecomm.PhoneAccount.Builder setCapabilities(int);
-    method public android.telecomm.PhoneAccount.Builder setIconResId(int);
-    method public android.telecomm.PhoneAccount.Builder setShortDescription(java.lang.CharSequence);
-    method public android.telecomm.PhoneAccount.Builder setSubscriptionAddress(android.net.Uri);
-    method public android.telecomm.PhoneAccount.Builder setSupportedUriSchemes(java.util.List<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 {
@@ -28393,25 +28246,25 @@
   public final class RemoteConference {
     method public void disconnect();
     method public final int getCallCapabilities();
-    method public final java.util.List<android.telecomm.RemoteConnection> getConnections();
+    method public final java.util.List<android.telecom.RemoteConnection> getConnections();
     method public int getDisconnectCause();
     method public java.lang.String getDisconnectMessage();
     method public final int getState();
     method public void hold();
-    method public final void registerCallback(android.telecomm.RemoteConference.Callback);
-    method public void separate(android.telecomm.RemoteConnection);
+    method public final void registerCallback(android.telecom.RemoteConference.Callback);
+    method public void separate(android.telecom.RemoteConnection);
     method public void unhold();
-    method public final void unregisterCallback(android.telecomm.RemoteConference.Callback);
+    method public final void unregisterCallback(android.telecom.RemoteConference.Callback);
   }
 
   public static abstract class RemoteConference.Callback {
     ctor public RemoteConference.Callback();
-    method public void onCapabilitiesChanged(android.telecomm.RemoteConference, int);
-    method public void onConnectionAdded(android.telecomm.RemoteConference, android.telecomm.RemoteConnection);
-    method public void onConnectionRemoved(android.telecomm.RemoteConference, android.telecomm.RemoteConnection);
-    method public void onDestroyed(android.telecomm.RemoteConference);
-    method public void onDisconnected(android.telecomm.RemoteConference, int, java.lang.String);
-    method public void onStateChanged(android.telecomm.RemoteConference, int, int);
+    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, int, java.lang.String);
+    method public void onStateChanged(android.telecom.RemoteConference, int, int);
   }
 
   public final class RemoteConnection {
@@ -28423,41 +28276,41 @@
     method public int getCallCapabilities();
     method public java.lang.CharSequence getCallerDisplayName();
     method public int getCallerDisplayNamePresentation();
-    method public android.telecomm.RemoteConference getConference();
-    method public java.util.List<android.telecomm.RemoteConnection> getConferenceableConnections();
+    method public android.telecom.RemoteConference getConference();
+    method public java.util.List<android.telecom.RemoteConnection> getConferenceableConnections();
     method public int getDisconnectCauseCode();
     method public java.lang.String getDisconnectCauseMessage();
     method public int getFailureCode();
     method public java.lang.String getFailureMessage();
     method public int getState();
-    method public android.telecomm.StatusHints getStatusHints();
+    method public android.telecom.StatusHints getStatusHints();
     method public void hold();
     method public boolean isRingbackRequested();
     method public boolean isVoipAudioMode();
     method public void playDtmfTone(char);
     method public void postDialContinue(boolean);
-    method public void registerCallback(android.telecomm.RemoteConnection.Callback);
+    method public void registerCallback(android.telecom.RemoteConnection.Callback);
     method public void reject();
-    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.telecomm.RemoteConnection.Callback);
+    method public void unregisterCallback(android.telecom.RemoteConnection.Callback);
   }
 
   public static abstract class RemoteConnection.Callback {
     ctor public RemoteConnection.Callback();
-    method public void onAddressChanged(android.telecomm.RemoteConnection, android.net.Uri, int);
-    method public void onCallCapabilitiesChanged(android.telecomm.RemoteConnection, int);
-    method public void onCallerDisplayNameChanged(android.telecomm.RemoteConnection, java.lang.String, int);
-    method public void onConferenceChanged(android.telecomm.RemoteConnection, android.telecomm.RemoteConference);
-    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 onPostDialWait(android.telecomm.RemoteConnection, java.lang.String);
-    method public void onRingbackRequested(android.telecomm.RemoteConnection, boolean);
-    method public void onStateChanged(android.telecomm.RemoteConnection, int);
-    method public void onStatusHintsChanged(android.telecomm.RemoteConnection, android.telecomm.StatusHints);
-    method public void onVoipAudioChanged(android.telecomm.RemoteConnection, boolean);
+    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, int, java.lang.String);
+    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 {
@@ -28472,36 +28325,36 @@
     field public static final android.os.Parcelable.Creator CREATOR;
   }
 
-  public class TelecommManager {
-    method public void addNewIncomingCall(android.telecomm.PhoneAccountHandle, android.os.Bundle);
+  public class TelecomManager {
+    method public void addNewIncomingCall(android.telecom.PhoneAccountHandle, android.os.Bundle);
     method public void cancelMissedCallsNotification();
     method public void clearAccounts();
-    method public android.telecomm.PhoneAccountHandle getConnectionManager();
-    method public android.telecomm.PhoneAccountHandle getDefaultOutgoingPhoneAccount(java.lang.String);
-    method public java.util.List<android.telecomm.PhoneAccountHandle> getEnabledPhoneAccounts();
-    method public android.telecomm.PhoneAccount getPhoneAccount(android.telecomm.PhoneAccountHandle);
-    method public java.util.List<android.telecomm.PhoneAccountHandle> getPhoneAccountsSupportingScheme(java.lang.String);
+    method public android.telecom.PhoneAccountHandle getConnectionManager();
+    method public android.telecom.PhoneAccountHandle getDefaultOutgoingPhoneAccount(java.lang.String);
+    method public java.util.List<android.telecom.PhoneAccountHandle> getEnabledPhoneAccounts();
+    method public android.telecom.PhoneAccount getPhoneAccount(android.telecom.PhoneAccountHandle);
+    method public java.util.List<android.telecom.PhoneAccountHandle> getPhoneAccountsSupportingScheme(java.lang.String);
     method public boolean handleMmi(java.lang.String);
     method public boolean hasMultipleEnabledAccounts();
     method public boolean isInCall();
-    method public void registerPhoneAccount(android.telecomm.PhoneAccount);
+    method public void registerPhoneAccount(android.telecom.PhoneAccount);
     method public void showInCallScreen(boolean);
-    method public void unregisterPhoneAccount(android.telecomm.PhoneAccountHandle);
-    field public static final java.lang.String ACTION_CHANGE_PHONE_ACCOUNTS = "android.telecomm.action.CHANGE_PHONE_ACCOUNTS";
-    field public static final java.lang.String ACTION_CONNECTION_SERVICE_CONFIGURE = "android.telecomm.action.CONNECTION_SERVICE_CONFIGURE";
+    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_PHONE_ACCOUNT_DISABLED = "android.telecom.action.PHONE_ACCOUNT_DISABLED";
     field public static final java.lang.String ACTION_PHONE_ACCOUNT_ENABLED = "android.telecom.action.PHONE_ACCOUNT_ENABLED";
-    field public static final java.lang.String ACTION_SHOW_CALL_SETTINGS = "android.telecomm.action.SHOW_CALL_SETTINGS";
+    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.telecomm.extra.PHONE_ACCOUNT_HANDLE";
-    field public static final java.lang.String EXTRA_START_CALL_WITH_SPEAKERPHONE = "android.telecomm.extra.START_CALL_WITH_SPEAKERPHONE";
-    field public static final java.lang.String GATEWAY_ORIGINAL_ADDRESS = "android.telecomm.extra.GATEWAY_ORIGINAL_ADDRESS";
-    field public static final java.lang.String GATEWAY_PROVIDER_PACKAGE = "android.telecomm.extra.GATEWAY_PROVIDER_PACKAGE";
+    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
diff --git a/core/java/android/app/ContextImpl.java b/core/java/android/app/ContextImpl.java
index 64eafb0..e9340eb 100644
--- a/core/java/android/app/ContextImpl.java
+++ b/core/java/android/app/ContextImpl.java
@@ -124,7 +124,7 @@
 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;
@@ -148,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;
@@ -562,9 +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());
+                    return new TelecomManager(ctx.getOuterContext());
                 }});
 
         registerService(UI_MODE_SERVICE, new ServiceFetcher() {
diff --git a/core/java/android/content/Context.java b/core/java/android/content/Context.java
index 4f20705..158a40c 100644
--- a/core/java/android/content/Context.java
+++ b/core/java/android/content/Context.java
@@ -2115,7 +2115,7 @@
             AUDIO_SERVICE,
             MEDIA_ROUTER_SERVICE,
             TELEPHONY_SERVICE,
-            TELECOMM_SERVICE,
+            TELECOM_SERVICE,
             CLIPBOARD_SERVICE,
             INPUT_METHOD_SERVICE,
             TEXT_SERVICES_MANAGER_SERVICE,
@@ -2588,13 +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";
+    public static final String TELECOM_SERVICE = "telecom";
 
     /**
      * Use with {@link #getSystemService} to retrieve a
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/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/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/PowerManager.java b/core/java/android/os/PowerManager.java
index 18b2082..3b6ce53 100644
--- a/core/java/android/os/PowerManager.java
+++ b/core/java/android/os/PowerManager.java
@@ -796,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.
      */
diff --git a/core/java/android/provider/CallLog.java b/core/java/android/provider/CallLog.java
index a5e86d8..c8d0fd5 100644
--- a/core/java/android/provider/CallLog.java
+++ b/core/java/android/provider/CallLog.java
@@ -33,7 +33,7 @@
 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;
 
diff --git a/core/java/android/view/View.java b/core/java/android/view/View.java
index ac00667..87ad036 100644
--- a/core/java/android/view/View.java
+++ b/core/java/android/view/View.java
@@ -3187,9 +3187,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.
@@ -3205,6 +3203,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.
@@ -4044,13 +4049,21 @@
                     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,
@@ -16210,7 +16223,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
@@ -16223,26 +16236,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
@@ -16251,26 +16269,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);
+                }
+            }
         }
     }
 
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/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/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/ImageView.java b/core/java/android/widget/ImageView.java
index 6a15078..6eb9471 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,25 @@
             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, the tint mode was always SRC_ATOP.
+            if (mContext.getApplicationInfo().targetSdkVersion <= Build.VERSION_CODES.L) {
+                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 +460,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 +473,7 @@
      * @see Drawable#setTintList(ColorStateList)
      */
     public void setImageTintList(@Nullable ColorStateList tint) {
-        mDrawableTint = tint;
+        mDrawableTintList = tint;
         mHasDrawableTint = true;
 
         applyImageTint();
@@ -476,13 +486,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 +502,7 @@
      */
     public void setImageTintMode(@Nullable PorterDuff.Mode tintMode) {
         mDrawableTintMode = tintMode;
+        mHasDrawableTintMode = true;
 
         applyImageTint();
     }
@@ -507,10 +518,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/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/com/android/internal/inputmethod/InputMethodUtils.java b/core/java/com/android/internal/inputmethod/InputMethodUtils.java
index d47d031..2d067d5 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";
@@ -127,10 +128,23 @@
 
     public static ArrayList<InputMethodInfo> getDefaultEnabledImes(
             Context context, boolean isSystemReady, ArrayList<InputMethodInfo> imis) {
-        final ArrayList<InputMethodInfo> retval = new ArrayList<InputMethodInfo>();
+        if (!isSystemReady) {
+            final ArrayList<InputMethodInfo> retval = new ArrayList<>();
+            for (int i = 0; i < imis.size(); ++i) {
+                final InputMethodInfo imi = imis.get(i);
+                if (isSystemImeThatHasEnglishKeyboardSubtype(imi)) {
+                    retval.add(imi);
+                }
+            }
+            return retval;
+        }
+
+        final ArrayList<InputMethodInfo> retval = new ArrayList<>();
         boolean auxilialyImeAdded = false;
         for (int i = 0; i < imis.size(); ++i) {
             final InputMethodInfo imi = imis.get(i);
+            // TODO: We should check isAsciiCapable instead of relying on
+            // isSystemImeThatHasEnglishKeyboardSubtype().
             if (isValidSystemDefaultIme(isSystemReady, imi, context)
                     || isSystemImeThatHasEnglishKeyboardSubtype(imi)) {
                 retval.add(imi);
@@ -139,6 +153,7 @@
                 }
             }
         }
+        // If one or more auxiliary input methods are available, OK to stop populating the list.
         if (auxilialyImeAdded) {
             return retval;
         }
@@ -164,7 +179,7 @@
             try {
                 if (imi.isDefault(context) && containsSubtypeOf(
                         imi, context.getResources().getConfiguration().locale.getLanguage(),
-                        null /* mode */)) {
+                        SUBTYPE_MODE_ANY)) {
                     return true;
                 }
             } catch (Resources.NotFoundException ex) {
@@ -179,13 +194,14 @@
     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;
     }
@@ -212,8 +228,7 @@
         return subtypes;
     }
 
-    public static InputMethodInfo getMostApplicableDefaultIME(
-            List<InputMethodInfo> enabledImes) {
+    public static InputMethodInfo getMostApplicableDefaultIME(List<InputMethodInfo> enabledImes) {
         if (enabledImes == null || enabledImes.isEmpty()) {
             return null;
         }
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/widget/ActionBarContainer.java b/core/java/com/android/internal/widget/ActionBarContainer.java
index 8111e63..d24f32f 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) {
@@ -312,8 +315,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;
@@ -374,7 +385,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/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/LockPatternUtils.java b/core/java/com/android/internal/widget/LockPatternUtils.java
index c84708e..f25cf9b 100644
--- a/core/java/com/android/internal/widget/LockPatternUtils.java
+++ b/core/java/com/android/internal/widget/LockPatternUtils.java
@@ -35,7 +35,7 @@
 import android.os.storage.IMountService;
 import android.os.storage.StorageManager;
 import android.provider.Settings;
-import android.telecomm.TelecommManager;
+import android.telecom.TelecomManager;
 import android.text.TextUtils;
 import android.util.Log;
 import android.view.IWindowManager;
@@ -1477,8 +1477,8 @@
         return getTelecommManager().isInCall();
     }
 
-    private TelecommManager getTelecommManager() {
-        return (TelecommManager) mContext.getSystemService(Context.TELECOMM_SERVICE);
+    private TelecomManager getTelecommManager() {
+        return (TelecomManager) mContext.getSystemService(Context.TELECOM_SERVICE);
     }
 
     private void finishBiometricWeak() {
diff --git a/core/res/res/anim/progress_indeterminate_horizontal_rect1.xml b/core/res/res/anim/progress_indeterminate_horizontal_rect1.xml
index 980c8e4..96a9d45 100644
--- a/core/res/res/anim/progress_indeterminate_horizontal_rect1.xml
+++ b/core/res/res/anim/progress_indeterminate_horizontal_rect1.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,19 +13,18 @@
      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:propertyYName="translateY"
-        android:repeatCount="infinite"
-        android:pathData="M -522.59998 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.0 0 l 0.1294 0 l 0.33832 0 l 0.5545 0 l 0.77088 0 l 0.98065 0 l 1.19641 0 l 1.41351 0 l 1.63153 0 l 1.85053 0 l 2.07052 0 l 2.29081 0 l 2.5115 0 l 2.73261 0 l 2.95355 0 l 3.17404 0 l 3.39423 0 l 3.61355 0 l 3.83164 0 l 4.04849 0 l 4.26367 0 l 5.74725 0 l 6.10266 0 l 6.45981 0 l 6.81781 0 l 7.17655 0 l 7.53366 0 l 7.88861 0 l 8.23975 0 l 8.58447 0 l 8.92157 0 l 9.24811 0 l 9.56137 0 l 9.85907 0 l 10.13778 0 l 10.39557 0 l 10.62876 0 l 10.83572 0 l 11.01492 0 l 11.16397 0 l 11.28324 0 l 11.3714 0 l 11.43011 0 l 11.45966 0 l 11.4611 0 l 11.43691 0 l 11.38878 0 l 11.31834 0 l 11.2276 0 l 11.11856 0 l 10.99338 0 l 10.85347 0 l 10.69954 0 l 10.53393 0 l 10.37447 0 l 10.37077 0 l 10.43095 0 l 10.52757 0 l 10.6715 0 l 10.8764 0 l 11.15665 0 l 11.52708 0 l 11.9948 0 l 12.55024 0 l 13.14534 0 l 13.68079 0 l 14.02233 0 l 14.06503 0 l 13.79804 0 l 13.295 0 l 12.65849 0 l 11.9693 0 l 11.2773 0 l 10.60766 0 l 9.97053 0 l 9.36723 0 l 8.79752 0 l 8.25793 0 l 7.74495 0 l 7.25633 0 l 6.78856 0 l 6.33934 0 l 5.9071 0 l 5.48941 0 l 5.08502 0 l 4.69292 0 l 4.33431 0 l 4.00734 0 l 3.68829 0 l 3.37685 0 l 3.07246 0 l 2.7744 0 l 2.48253 0 l 2.20102 0 l 1.91748 0 l 1.63726 0 l 1.36773 0 "
-        android:interpolator="@interpolator/progress_indeterminate_horizontal_rect1_grp_position" />
+        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:propertyXName="scaleX"
-        android:propertyYName="scaleY"
-        android:repeatCount="infinite"
-        android:pathData="M 0.1 1 l 0.0 0 l 0.00882427215576 0 l 0.00982859611511 0 l 0.0108650398254 0 l 0.011930847168 0 l 0.0130220413208 0 l 0.0141334056854 0 l 0.0152582168579 0 l 0.0163880157471 0 l 0.0175127220154 0 l 0.0186203575134 0 l 0.0196973228455 0 l 0.0207285499573 0 l 0.0216978645325 0 l 0.0225887107849 0 l 0.0233847427368 0 l 0.0240707015991 0 l 0.0246334838867 0 l 0.0250626373291 0 l 0.0253514099121 0 l 0.0254969406128 0 l 0.0255004882813 0 l 0.0253670883179 0 l 0.0251052856445 0 l 0.0247262573242 0 l 0.0242431640625 0 l 0.0236701583862 0 l 0.0230218887329 0 l 0.0223124694824 0 l 0.021555557251 0 l 0.0207632446289 0 l 0.0199468231201 0 l 0.0191157531738 0 l 0.0182782745361 0 l 0.0173241424561 0 l 0.0152210998535 0 l 0.0126258087158 0 l 0.00973388671875 0 l 0.00647575378418 0 l 0.00276618957519 0 l -0.00149223327636 0 l -0.00639404296875 0 l -0.0119906616211 0 l -0.0182067108154 0 l -0.0247090148926 0 l -0.0308044433594 0 l -0.0355574798584 0 l -0.0382397460938 0 l -0.0387688446045 0 l -0.0376621246338 0 l -0.0356225204468 0 l -0.03321434021 0 l -0.0307815170288 0 l -0.0284958267212 0 l -0.0264254379272 0 l -0.024584236145 0 l -0.0229611587524 0 l -0.0215351867676 0 l -0.0202828598023 0 l -0.0191815567017 0 l -0.018210849762 0 l -0.0173528671265 0 l -0.0165923118591 0 l -0.0159160423279 0 l -0.0153129196167 0 l -0.0147735023499 0 l -0.0141336250305 0 l -0.0133926582336 0 l -0.01270362854 0 l -0.0120610809326 0 l -0.0114603328705 0 l -0.0108972930908 0 l -0.0103683567047 0 l -0.00987038612366 0 l -0.00940062522888 0 l -0.00895661354065 0 l -0.00853617668152 0 "
-        android:interpolator="@interpolator/progress_indeterminate_horizontal_rect1_grp_scale" />
-</set>
\ No newline at end of file
+        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
index 8f0b2e8..32759fa 100644
--- a/core/res/res/anim/progress_indeterminate_horizontal_rect2.xml
+++ b/core/res/res/anim/progress_indeterminate_horizontal_rect2.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.
@@ -19,15 +18,13 @@
     <objectAnimator
         android:duration="2000"
         android:propertyXName="translateX"
-        android:propertyYName="translateY"
-        android:repeatCount="infinite"
-        android:pathData="M -197.60001 0 l 1.42626 0 l 1.80754 0 l 2.18779 0 l 2.5611 0 l 2.9181 0 l 3.25482 0 l 3.5716 0 l 3.86255 0 l 4.12494 0 l 4.35758 0 l 4.56035 0 l 4.73427 0 l 4.88091 0 l 5.00271 0 l 5.10274 0 l 5.18401 0 l 5.24911 0 l 5.30098 0 l 5.34226 0 l 5.37535 0 l 5.40181 0 l 5.42322 0 l 5.44123 0 l 5.45705 0 l 5.47099 0 l 5.48396 0 l 5.4967 0 l 5.5095 0 l 5.52215 0 l 5.53528 0 l 5.54913 0 l 5.56306 0 l 5.57743 0 l 5.59244 0 l 5.60744 0 l 5.62244 0 l 5.63767 0 l 5.65263 0 l 5.6669 0 l 5.6807 0 l 5.69401 0 l 5.70899 0 l 5.7517 0 l 5.80327 0 l 5.8571 0 l 5.914 0 l 5.9745 0 l 6.03849 0 l 6.10729 0 l 6.18126 0 l 6.26117 0 l 6.3484 0 l 6.44406 0 l 6.54867 0 l 6.66372 0 l 6.79021 0 l 6.92859 0 l 7.07807 0 l 7.23712 0 l 7.40254 0 l 7.56885 0 l 7.72841 0 l 7.87199 0 l 7.98993 0 l 8.07417 0 l 8.12013 0 l 8.12656 0 l 8.09511 0 l 8.03091 0 l 7.93996 0 l 7.82788 0 l 7.69977 0 l 7.56065 0 l 7.41323 0 l 7.26063 0 l 7.10471 0 l 6.94624 0 l 6.78694 0 l 6.63904 0 l 6.50302 0 l 6.36688 0 l 6.23044 0 l 6.09357 0 l 5.95706 0 l 5.82065 0 l 5.68396 0 l 5.54773 0 l 5.41144 0 l 5.27533 0 l 5.13922 0 l 5.00348 0 l 4.86804 0 l 4.73251 0 l 4.59732 0 l 4.46259 0 l 4.32812 0 l 4.19373 0 l 4.05993 0 l 3.92673 0 l 3.79376 0 l 3.6612 0 l 3.52936 0 l 3.39819 0 l 3.26749 0 l 3.13726 0 l 3.00797 0 l 2.87939 0 l 2.75159 0 l 2.62445 0 l 2.49811 0 l 2.37268 0 l 2.24817 0 l 2.12457 0 l 2.00174 0 l 1.87997 0 l 1.76185 0 l 1.64154 0 l 1.51962 0 l 1.40018 0 l 1.28421 0 "
-        android:interpolator="@interpolator/progress_indeterminate_horizontal_rect2_grp_position" />
+        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:propertyXName="scaleX"
-        android:propertyYName="scaleY"
-        android:repeatCount="infinite"
-        android:pathData="M 0.1 1 l 0.00930031776428 0 l 0.0112302875519 0 l 0.0131314373016 0 l 0.014971075058 0 l 0.0167151069641 0 l 0.0183303451538 0 l 0.0197867202759 0 l 0.0210597610474 0 l 0.0221322822571 0 l 0.0229952049255 0 l 0.0236479568482 0 l 0.0240972709656 0 l 0.0243561935425 0 l 0.0244421386719 0 l 0.0243751525879 0 l 0.0241764450073 0 l 0.0238669586182 0 l 0.0234665298462 0 l 0.0229933547974 0 l 0.0224634552002 0 l 0.0218908691406 0 l 0.0212874603272 0 l 0.0206631851196 0 l 0.0200262451172 0 l 0.019383354187 0 l 0.0187397766113 0 l 0.018099899292 0 l 0.0174669647217 0 l 0.0168434906006 0 l 0.0162316131592 0 l 0.0156324005127 0 l 0.0150471496582 0 l 0.0144763183594 0 l 0.0139205169678 0 l 0.0133796691894 0 l 0.0128540802002 0 l 0.0123434448242 0 l 0.0118475341797 0 l 0.0113663482666 0 l 0.0108992004395 0 l 0.0104459381103 0 l 0.00998542785645 0 l 0.00933837890625 0 l 0.0086334991455 0 l 0.00791206359864 0 l 0.00717010498047 0 l 0.00640274047851 0 l 0.00560478210449 0 l 0.00477012634278 0 l 0.00389221191406 0 l 0.00296325683594 0 l 0.00197517395019 0 l 0.00091903686524 0 l -0.00021408081055 0 l -0.00143287658691 0 l -0.00274444580079 0 l -0.00415267944336 0 l -0.00565589904785 0 l -0.00724327087402 0 l -0.00889205932617 0 l -0.0105648040771 0 l -0.0122087860107 0 l -0.0137604522705 0 l -0.0151544952393 0 l -0.0163356018066 0 l -0.0172690582275 0 l -0.017946395874 0 l -0.0183829498291 0 l -0.0186113739014 0 l -0.018671798706 0 l -0.0186050415039 0 l -0.0184476470947 0 l -0.018229598999 0 l -0.017974319458 0 l -0.0176993560791 0 l -0.0174169921875 0 l -0.0171360397339 0 l -0.0168621444702 0 l -0.0165135955811 0 l -0.0160948562622 0 l -0.0156935882568 0 l -0.0153102493286 0 l -0.0149446105957 0 l -0.0145963287353 0 l -0.0142646408081 0 l -0.0139489364624 0 l -0.0136483383179 0 l -0.0133620071411 0 l -0.0130891799927 0 l -0.0128289794922 0 l -0.0125807571411 0 l -0.0123436355591 0 l -0.0121170043945 0 l -0.0119002914429 0 l -0.0116927337646 0 l -0.0114939498901 0 l -0.0113032531738 0 l -0.0111202430725 0 l -0.010944442749 0 l -0.0107754516601 0 l -0.0106128692627 0 l -0.0104563140869 0 l -0.0103054428101 0 l -0.0101600074768 0 l -0.0100196266174 0 l -0.0098840713501 0 l -0.00975311279297 0 l -0.00962644577026 0 l -0.00950393676758 0 l -0.00938529968262 0 l -0.00927038192749 0 l -0.00915899276733 0 l -0.00905097961426 0 l -0.00894614219665 0 l -0.0088443851471 0 l -0.00874552726745 0 l -0.00864946365357 0 l -0.00855606079101 0 l -0.00846519470215 0 l -0.00837676048279 0 "
-        android:interpolator="@interpolator/progress_indeterminate_horizontal_rect2_grp_scale" />
-</set>
\ No newline at end of file
+        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/drawable/progress_indeterminate_horizontal_material.xml b/core/res/res/drawable/progress_indeterminate_horizontal_material.xml
index e92f090..9ffe1ea 100644
--- a/core/res/res/drawable/progress_indeterminate_horizontal_material.xml
+++ b/core/res/res/drawable/progress_indeterminate_horizontal_material.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.
@@ -22,4 +22,4 @@
     <target
         android:name="rect1_grp"
         android:animation="@anim/progress_indeterminate_horizontal_rect1" />
-</animated-vector>
\ No newline at end of file
+</animated-vector>
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 cd999d5..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.
@@ -16,44 +16,35 @@
 
 <vector xmlns:android="http://schemas.android.com/apk/res/android"
     android:height="10dp"
+    android:width="360dp"
     android:viewportHeight="10"
-    android:viewportWidth="360"
-    android:width="360dp" >
-
+    android:viewportWidth="360" >
     <group
-        android:name="v21"
+        android:name="progress_group"
         android:translateX="180"
         android:translateY="5" >
-        <group android:name="v21_pivot" >
-            <group
-                android:name="rectangle_path_1_position">
-                <path
-                    android:name="rectangle_path_1"
-                    android:fillColor="?attr/colorControlActivated"
-                    android:fillAlpha="0.1"
-                    android:pathData="M -180.0 -1.0 l 360 0 l 0 2 l -360 0 Z" />
-            </group>
-            <group
-                android:name="rect2_grp"
-                android:scaleX="0.1"
-                android:scaleY="1"
-                android:translateX="-197.60001" >
-                <path
-                    android:name="rect2"
-                    android:fillColor="?attr/colorControlActivated"
-                    android:pathData="M -144.0 -1.0 l 288 0 l 0 2 l -288 0 Z" />
-            </group>
-            <group
-                android:name="rect1_grp"
-                android:scaleX="0.1"
-                android:scaleY="1"
-                android:translateX="-522.59998" >
-                <path
-                    android:name="rect1"
-                    android:fillColor="?attr/colorControlActivated"
-                    android:pathData="M -144.0 -1.0 l 288 0 l 0 2 l -288 0 Z" />
-            </group>
+        <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="rect2_grp"
+            android:translateX="-197.60001"
+            android:scaleX="0.1" >
+            <path
+                android:name="rect2"
+                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_grp_position.xml b/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_grp_position.xml
deleted file mode 100644
index 1e5490b..0000000
--- a/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_grp_position.xml
+++ /dev/null
@@ -1,17 +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.
--->
-<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
-    android:pathData="M 0.0 0.0 L 0.00833333333334 0.0 L 0.0166666666667 0.0 L 0.025 0.0 L 0.0333333333333 0.0 L 0.0416666666667 0.0 L 0.05 0.0 L 0.0583333333333 0.0 L 0.0666666666667 0.0 L 0.075 0.0 L 0.0833333333333 0.0 L 0.0916666666667 0.0 L 0.1 0.0 L 0.108333333333 0.0 L 0.116666666667 0.0 L 0.125 0.0 L 0.133333333333 0.0 L 0.141666666667 0.0 L 0.15 0.0 L 0.158333333333 0.0 L 0.166666666667 0.0 L 0.175 0.0 L 0.183333333333 0.0 L 0.191666666667 0.0 L 0.2 0.0 L 0.208333333333 0.000179174746319 L 0.216666666667 0.000647632243805 L 0.225 0.0014154251096 L 0.233333333333 0.00248283027531 L 0.241666666667 0.00384069515149 L 0.25 0.00549731383962 L 0.258333333333 0.00745454178143 L 0.266666666667 0.00971365286228 L 0.275 0.012276004047 L 0.283333333333 0.0151429661471 L 0.291666666667 0.0183149545599 L 0.3 0.0217925231486 L 0.308333333333 0.0255762534696 L 0.316666666667 0.0296659101311 L 0.325 0.0340608700368 L 0.333333333333 0.0387607177895 L 0.341666666667 0.0437642487367 L 0.35 0.049069759749 L 0.358333333333 0.0546755338504 L 0.366666666667 0.0605792586621 L 0.375 0.0685372344023 L 0.383333333333 0.0769873314454 L 0.391666666667 0.0859319590963 L 0.4 0.0953722943142 L 0.408333333333 0.105309361746 L 0.416666666667 0.1157409044 L 0.425 0.126663931413 L 0.433333333333 0.13807316724 L 0.441666666667 0.149959722376 L 0.45 0.162313045726 L 0.458333333333 0.175118515302 L 0.466666666667 0.188357742846 L 0.475 0.20200918308 L 0.483333333333 0.216046541347 L 0.491666666667 0.230440850602 L 0.5 0.245158048258 L 0.508333333333 0.260161814735 L 0.516666666667 0.275413711928 L 0.525 0.290871992396 L 0.533333333333 0.306495421026 L 0.541666666667 0.322240921106 L 0.55 0.338067714457 L 0.558333333333 0.353935424452 L 0.566666666667 0.369805128355 L 0.575 0.385641337381 L 0.583333333333 0.401410902817 L 0.591666666667 0.417082932942 L 0.6 0.4326293192 L 0.608333333333 0.448024722349 L 0.616666666667 0.463246794008 L 0.625 0.478275138165 L 0.633333333333 0.493090341915 L 0.641666666667 0.507676232452 L 0.65 0.522041325423 L 0.658333333333 0.536401295159 L 0.666666666667 0.550844593615 L 0.675 0.565421677727 L 0.683333333333 0.580198055666 L 0.691666666667 0.595258150031 L 0.7 0.610706294803 L 0.708333333333 0.626667358442 L 0.716666666667 0.643276054324 L 0.725 0.66065384465 L 0.733333333333 0.678855644958 L 0.741666666667 0.697798860396 L 0.75 0.71721499193 L 0.758333333333 0.736690248362 L 0.766666666667 0.755795814951 L 0.775 0.774204843176 L 0.783333333333 0.791732522732 L 0.791666666667 0.808305909835 L 0.8 0.823921113596 L 0.808333333333 0.838609094968 L 0.816666666667 0.852414869183 L 0.825 0.865385279222 L 0.833333333333 0.877566835746 L 0.841666666667 0.889001244655 L 0.85 0.899725351699 L 0.858333333333 0.909772887147 L 0.866666666667 0.919172721118 L 0.875 0.927950539019 L 0.883333333333 0.936129852342 L 0.891666666667 0.943730807861 L 0.9 0.950771821528 L 0.908333333333 0.95726991079 L 0.916666666667 0.963271447844 L 0.925 0.968820243268 L 0.933333333333 0.973927263555 L 0.941666666667 0.978603045951 L 0.95 0.982857352297 L 0.958333333333 0.986698947476 L 0.966666666667 0.990136402522 L 0.975 0.993184062492 L 0.983333333333 0.995839116531 L 0.991666666667 0.998106161702 L 1.0 1.0 " />
diff --git a/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_grp_scale.xml b/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_grp_scale.xml
deleted file mode 100644
index dc0e485..0000000
--- a/core/res/res/interpolator/progress_indeterminate_horizontal_rect1_grp_scale.xml
+++ /dev/null
@@ -1,17 +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.
--->
-<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
-    android:pathData="M 0.0 0.0 L 0.366666666667 0.0 L 0.375 0.00607022199531 L 0.383333333333 0.0128313190317 L 0.391666666667 0.0203053863048 L 0.4 0.0285126230744 L 0.408333333333 0.0374704929422 L 0.416666666667 0.0471928710088 L 0.425 0.0576890073411 L 0.433333333333 0.0689623329923 L 0.441666666667 0.0810093447457 L 0.45 0.0938182996083 L 0.458333333333 0.107368099555 L 0.466666666667 0.121627281237 L 0.475 0.136553254984 L 0.483333333333 0.152092042392 L 0.491666666667 0.168178420646 L 0.5 0.184736670404 L 0.508333333333 0.201682058428 L 0.516666666667 0.218922661357 L 0.525 0.236361911116 L 0.533333333333 0.253901271529 L 0.541666666667 0.271443072385 L 0.55 0.288893107328 L 0.558333333333 0.306163048058 L 0.566666666667 0.323172254984 L 0.575 0.339849141772 L 0.583333333333 0.356131857619 L 0.591666666667 0.371968628391 L 0.6 0.387317389244 L 0.608333333333 0.402145469729 L 0.616666666667 0.416428517896 L 0.625 0.430149949228 L 0.633333333333 0.443299687056 L 0.641666666667 0.455873322838 L 0.65 0.467790610602 L 0.658333333333 0.478261214125 L 0.666666666667 0.486946515351 L 0.675 0.493642461739 L 0.683333333333 0.498097136568 L 0.691666666667 0.5 L 0.7 0.501026508147 L 0.708333333333 0.505424974058 L 0.716666666667 0.513673357225 L 0.725 0.526197764281 L 0.733333333333 0.543195110129 L 0.741666666667 0.564385504796 L 0.75 0.588845516061 L 0.758333333333 0.615150659843 L 0.766666666667 0.641819770802 L 0.775 0.667727568443 L 0.783333333333 0.692232321167 L 0.791666666667 0.715080485292 L 0.8 0.736255108924 L 0.808333333333 0.755857404851 L 0.816666666667 0.774035479111 L 0.825 0.790946989585 L 0.833333333333 0.806741984167 L 0.841666666667 0.821556051785 L 0.85 0.835508642948 L 0.858333333333 0.848703647061 L 0.866666666667 0.861230901301 L 0.875 0.873167948783 L 0.883333333333 0.884581809849 L 0.891666666667 0.895530464709 L 0.9 0.906064231101 L 0.908333333333 0.916226932039 L 0.916666666667 0.925949460993 L 0.925 0.935162278452 L 0.933333333333 0.943901111981 L 0.941666666667 0.952197936634 L 0.95 0.960081506342 L 0.958333333333 0.967577760656 L 0.966666666667 0.974710159318 L 0.975 0.981500003726 L 0.983333333333 0.987966699339 L 0.991666666667 0.994127959051 L 1.0 1.0 " />
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_grp_position.xml b/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_grp_position.xml
deleted file mode 100644
index e2c463d..0000000
--- a/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_grp_position.xml
+++ /dev/null
@@ -1,17 +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.
--->
-<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
-    android:pathData="M 0.0 0.0 L 0.00833333333334 0.00229967744922 L 0.0166666666667 0.00521412430783 L 0.025 0.00874167982129 L 0.0333333333333 0.0128711540512 L 0.0416666666667 0.0175762490301 L 0.05 0.0228242656297 L 0.0583333333333 0.0285830529319 L 0.0666666666667 0.0348109630825 L 0.075 0.0414619464217 L 0.0833333333333 0.0484880345538 L 0.0916666666667 0.0558410655969 L 0.1 0.0634745223001 L 0.108333333333 0.0713444188538 L 0.116666666667 0.079410703663 L 0.125 0.0876382751487 L 0.133333333333 0.0959968850049 L 0.141666666667 0.104460460998 L 0.15 0.113007671299 L 0.158333333333 0.121621440773 L 0.166666666667 0.130288564002 L 0.175 0.138998350887 L 0.183333333333 0.147742658893 L 0.191666666667 0.156516005917 L 0.2 0.165314860841 L 0.208333333333 0.174136192385 L 0.216666666667 0.182978436537 L 0.225 0.191841222449 L 0.233333333333 0.200724646865 L 0.241666666667 0.209628467926 L 0.25 0.218553459576 L 0.258333333333 0.227500782731 L 0.266666666667 0.236470566383 L 0.275 0.245463519979 L 0.283333333333 0.254480675444 L 0.291666666667 0.263522016655 L 0.3 0.272587543612 L 0.308333333333 0.281677627163 L 0.316666666667 0.290791831964 L 0.325 0.299929045471 L 0.333333333333 0.309088509865 L 0.341666666667 0.318269435077 L 0.35 0.327474513787 L 0.358333333333 0.336748457377 L 0.366666666667 0.346105551561 L 0.375 0.355549440324 L 0.383333333333 0.365085073683 L 0.391666666667 0.374718256217 L 0.4 0.384454615142 L 0.408333333333 0.394301906021 L 0.416666666667 0.404268464874 L 0.425 0.414363869256 L 0.433333333333 0.424599921812 L 0.441666666667 0.434990214931 L 0.45 0.445549179441 L 0.458333333333 0.45629364862 L 0.466666666667 0.467242068132 L 0.475 0.478413609209 L 0.483333333333 0.489826169306 L 0.491666666667 0.501495178926 L 0.5 0.513430908951 L 0.508333333333 0.525634794401 L 0.516666666667 0.53809595169 L 0.525 0.550788614937 L 0.533333333333 0.563671442642 L 0.541666666667 0.576690097495 L 0.55 0.589782857472 L 0.558333333333 0.602885985073 L 0.566666666667 0.615938403227 L 0.575 0.628887306389 L 0.583333333333 0.641689563312 L 0.591666666667 0.654311104343 L 0.6 0.666726082982 L 0.608333333333 0.678916746891 L 0.616666666667 0.69086971329 L 0.625 0.702576630036 L 0.633333333333 0.714032144017 L 0.641666666667 0.725232143656 L 0.65 0.736175290675 L 0.658333333333 0.746879966241 L 0.666666666667 0.757365325464 L 0.675 0.767631174859 L 0.683333333333 0.77767703071 L 0.691666666667 0.787502199694 L 0.7 0.797107262267 L 0.708333333333 0.806492379668 L 0.716666666667 0.81565710043 L 0.725 0.82460216625 L 0.733333333333 0.833327480383 L 0.741666666667 0.841833333059 L 0.75 0.850119724279 L 0.758333333333 0.858187250623 L 0.766666666667 0.866036395807 L 0.775 0.873667014716 L 0.783333333333 0.88107965556 L 0.791666666667 0.888275060036 L 0.8 0.895253647364 L 0.808333333333 0.902015546533 L 0.816666666667 0.90856170885 L 0.825 0.914893101745 L 0.833333333333 0.921010096065 L 0.841666666667 0.926913352889 L 0.85 0.932604033131 L 0.858333333333 0.938083217089 L 0.866666666667 0.943351662581 L 0.875 0.94841012743 L 0.883333333333 0.953260127273 L 0.891666666667 0.957902806904 L 0.9 0.962339423981 L 0.908333333333 0.966571042677 L 0.916666666667 0.970598952899 L 0.925 0.974424621915 L 0.933333333333 0.978049533117 L 0.941666666667 0.981475153774 L 0.95 0.984702725421 L 0.958333333333 0.987733957184 L 0.966666666667 0.990574734261 L 0.975 0.993221525533 L 0.983333333333 0.995671735064 L 0.991666666667 0.997929361563 L 1.0 1.0 " />
diff --git a/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_grp_scale.xml b/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_grp_scale.xml
deleted file mode 100644
index e19e3bd..0000000
--- a/core/res/res/interpolator/progress_indeterminate_horizontal_rect2_grp_scale.xml
+++ /dev/null
@@ -1,17 +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.
--->
-<pathInterpolator xmlns:android="http://schemas.android.com/apk/res/android"
-    android:pathData="M 0.0 0.0 L 0.00833333333334 0.00574128947512 L 0.0166666666667 0.0126739914922 L 0.025 0.0207803148119 L 0.0333333333333 0.0300222867359 L 0.0416666666667 0.0403408876828 L 0.05 0.0516566104757 L 0.0583333333333 0.0638713854701 L 0.0666666666667 0.0768720363634 L 0.075 0.0905347780463 L 0.0833333333333 0.104730220757 L 0.0916666666667 0.1193286215 L 0.1 0.134204393671 L 0.108333333333 0.149240004408 L 0.116666666667 0.164328670953 L 0.125 0.179375985524 L 0.133333333333 0.194300633561 L 0.141666666667 0.209034228885 L 0.15 0.223520630773 L 0.158333333333 0.237714931359 L 0.166666666667 0.25158211334 L 0.175 0.265095825429 L 0.183333333333 0.278237040065 L 0.191666666667 0.290992875969 L 0.2 0.303355514884 L 0.208333333333 0.315321283173 L 0.216666666667 0.326889756956 L 0.225 0.33806322048 L 0.233333333333 0.348845959658 L 0.241666666667 0.35924381463 L 0.25 0.369263944281 L 0.258333333333 0.378914166866 L 0.266666666667 0.388203101304 L 0.275 0.397139649102 L 0.283333333333 0.40573308855 L 0.291666666667 0.413992650841 L 0.3 0.421927755558 L 0.308333333333 0.429547633895 L 0.316666666667 0.436861375749 L 0.325 0.44387807102 L 0.333333333333 0.450606385724 L 0.341666666667 0.457054891684 L 0.35 0.463219114597 L 0.358333333333 0.468983900047 L 0.366666666667 0.474313547811 L 0.375 0.47919783764 L 0.383333333333 0.483624100194 L 0.391666666667 0.487576651865 L 0.4 0.491036606388 L 0.408333333333 0.493981309661 L 0.416666666667 0.496384057166 L 0.425 0.498213340392 L 0.433333333333 0.499432658452 L 0.441666666667 0.5 L 0.45 0.500132156764 L 0.458333333333 0.501016702806 L 0.466666666667 0.502710909197 L 0.475 0.505274449001 L 0.483333333333 0.50876595913 L 0.491666666667 0.51323738859 L 0.5 0.518726651206 L 0.508333333333 0.525248535726 L 0.516666666667 0.532785286233 L 0.525 0.541279914244 L 0.533333333333 0.550635115456 L 0.541666666667 0.560719439572 L 0.55 0.571380006744 L 0.558333333333 0.582458709253 L 0.566666666667 0.593806906062 L 0.575 0.605296114045 L 0.583333333333 0.61682262358 L 0.591666666667 0.628307922435 L 0.6 0.639696058281 L 0.608333333333 0.65094958827 L 0.616666666667 0.662045528618 L 0.625 0.67297172806 L 0.633333333333 0.6837236181 L 0.641666666667 0.694302070048 L 0.65 0.704711440462 L 0.658333333333 0.714905644026 L 0.666666666667 0.724841350655 L 0.675 0.734529345772 L 0.683333333333 0.743980697388 L 0.691666666667 0.753206332221 L 0.7 0.762216965048 L 0.708333333333 0.771022839665 L 0.716666666667 0.779633823089 L 0.725 0.788059240706 L 0.733333333333 0.796307899828 L 0.741666666667 0.804388136787 L 0.75 0.812307746289 L 0.758333333333 0.820074122707 L 0.766666666667 0.827694118788 L 0.775 0.835174210498 L 0.783333333333 0.842520520564 L 0.791666666667 0.849738700738 L 0.8 0.856834167281 L 0.808333333333 0.863811912571 L 0.816666666667 0.870676681725 L 0.825 0.877432925497 L 0.833333333333 0.884084847374 L 0.841666666667 0.890636403584 L 0.85 0.897091314861 L 0.858333333333 0.90345309 L 0.866666666667 0.909725084729 L 0.875 0.915910419285 L 0.883333333333 0.92201207261 L 0.891666666667 0.928032882355 L 0.9 0.933975497778 L 0.908333333333 0.939842485715 L 0.916666666667 0.945636236386 L 0.925 0.951359045815 L 0.933333333333 0.95701309228 L 0.941666666667 0.962600459864 L 0.95 0.968123109018 L 0.958333333333 0.973582941322 L 0.966666666667 0.978981746494 L 0.975 0.984321249498 L 0.983333333333 0.989603092873 L 0.991666666667 0.994828842625 L 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/values/attrs.xml b/core/res/res/values/attrs.xml
index 0e597d0..12fc291 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. -->
@@ -1772,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" />
@@ -3454,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>
diff --git a/core/res/res/values/config.xml b/core/res/res/values/config.xml
index 0e4f965..5c0e5cf 100644
--- a/core/res/res/values/config.xml
+++ b/core/res/res/values/config.xml
@@ -353,7 +353,27 @@
     <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">-60</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">-82</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>
diff --git a/core/res/res/values/public.xml b/core/res/res/values/public.xml
index 99918a0..4bc1ff3 100644
--- a/core/res/res/values/public.xml
+++ b/core/res/res/values/public.xml
@@ -2103,8 +2103,6 @@
      =============================================================== -->
   <eat-comment />
 
-  <public-padding type="attr" name="l_resource_pad" end="0x1010410" />
-
   <public type="attr" name="fastScrollStyle" />
   <public type="attr" name="windowContentTransitions" />
   <public type="attr" name="windowContentTransitionManager" />
@@ -2248,7 +2246,6 @@
   <public type="attr" name="timePickerDialogTheme" />
   <public type="attr" name="headerTimeTextAppearance" />
   <public type="attr" name="headerAmPmTextAppearance" />
-  <public type="attr" name="__removed2" />
   <public type="attr" name="numbersTextColor" />
   <public type="attr" name="numbersBackgroundColor" />
   <public type="attr" name="numbersSelectorColor" />
@@ -2295,43 +2292,49 @@
   <public type="attr" name="fillAlpha" />
   <public type="attr" name="windowActivityTransitions" />
 
-  <public-padding type="dimen" name="l_resource_pad" end="0x01050010" />
-
-  <public-padding type="id" name="l_resource_pad" end="0x01020040" />
-
   <public type="id" name="mask" />
   <public type="id" name="statusBarBackground" />
   <public type="id" name="navigationBarBackground" />
 
-  <public-padding type="style" name="l_resource_pad" end="0x01030200" />
-
   <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="__removed3" />
-  <public type="style" name="__removed4" />
-  <public type="style" name="__removed5" />
-  <public type="style" name="__removed6" />
-  <public type="style" name="__removed7" />
-
   <public type="style" name="Widget.DeviceDefault.FastScroll" />
   <public type="style" name="Widget.DeviceDefault.StackView" />
   <public type="style" name="Widget.DeviceDefault.Light.FastScroll" />
   <public type="style" name="Widget.DeviceDefault.Light.StackView" />
 
   <public type="style" name="TextAppearance.Material" />
+  <public type="style" name="TextAppearance.Material.Button" />
+  <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.DialogWindowTitle" />
+  <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.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.Menu" />
+  <public type="style" name="TextAppearance.Material.Notification" />
+  <public type="style" name="TextAppearance.Material.Notification.Emphasis" />
+  <public type="style" name="TextAppearance.Material.Notification.Info" />
+  <public type="style" name="TextAppearance.Material.Notification.Line2" />
+  <public type="style" name="TextAppearance.Material.Notification.Time" />
+  <public type="style" name="TextAppearance.Material.Notification.Title" />
   <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.Subhead" />
+  <public type="style" name="TextAppearance.Material.Title" />
   <public type="style" name="TextAppearance.Material.WindowTitle" />
 
   <public type="style" name="TextAppearance.Material.Widget" />
@@ -2356,14 +2359,18 @@
   <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" />
+  <public type="style" name="TextAppearance.Material.Widget.Toolbar.Subtitle" />
+  <public type="style" name="TextAppearance.Material.Widget.Toolbar.Title" />
 
   <public type="style" name="Theme.DeviceDefault.Settings" />
 
   <public type="style" name="Theme.Material" />
   <public type="style" name="Theme.Material.Dialog" />
+  <public type="style" name="Theme.Material.Dialog.Alert" />
   <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.Dialog.Presentation" />
   <public type="style" name="Theme.Material.DialogWhenLarge" />
   <public type="style" name="Theme.Material.DialogWhenLarge.NoActionBar" />
   <public type="style" name="Theme.Material.InputMethod" />
@@ -2380,9 +2387,11 @@
   <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.Alert" />
   <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.Dialog.Presentation" />
   <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" />
@@ -2412,6 +2421,7 @@
   <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.Colored" />
   <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" />
@@ -2448,14 +2458,17 @@
   <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.SearchView" />
   <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.Spinner.Underlined" />
   <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.TimePicker" />
   <public type="style" name="Widget.Material.Toolbar" />
   <public type="style" name="Widget.Material.Toolbar.Button.Navigation" />
   <public type="style" name="Widget.Material.WebTextView" />
@@ -2474,6 +2487,7 @@
   <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.Colored" />
   <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" />
@@ -2485,6 +2499,7 @@
   <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.DatePicker" />
   <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" />
@@ -2512,70 +2527,27 @@
   <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.SearchView" />
   <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.Spinner.Underlined" />
   <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.TimePicker" />
   <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" />
-
+  <!-- @hide This really shouldn't be public; clients using it should use @* to ref it.  -->
   <public type="style" name="Theme.Leanback.FormWizard"/>
 
-  <public type="style" name="__removed1" />
-  <public type="style" name="TextAppearance.Material.Notification" />
-  <public type="style" name="TextAppearance.Material.Notification.Title" />
-  <public type="style" name="TextAppearance.Material.Notification.Line2" />
-  <public type="style" name="TextAppearance.Material.Notification.Info" />
-  <public type="style" name="TextAppearance.Material.Notification.Time" />
-  <public type="style" name="TextAppearance.Material.Notification.Emphasis" />
-
-  <public type="style" name="Widget.Material.Spinner.Underlined" />
-  <public type="style" name="Widget.Material.Light.Spinner.Underlined" />
-
-  <public type="style" name="TextAppearance.Material.Widget.Toolbar.Title" />
-  <public type="style" name="TextAppearance.Material.Widget.Toolbar.Subtitle" />
-
-  <public type="style" name="Theme.Material.Dialog.Alert" />
-  <public type="style" name="Theme.Material.Dialog.Presentation" />
-  <public type="style" name="Theme.Material.Light.Dialog.Alert" />
-  <public type="style" name="Theme.Material.Light.Dialog.Presentation" />
-
-  <public type="style" name="Widget.Material.SearchView" />
-  <public type="style" name="Widget.Material.Light.SearchView" />
-  <public type="style" name="Widget.Material.TimePicker" />
-  <public type="style" name="Widget.Material.Light.TimePicker" />
-  <public type="style" name="Widget.Material.Light.DatePicker" />
-
-  <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. -->
diff --git a/core/res/res/values/symbols.xml b/core/res/res/values/symbols.xml
index e4ca36d..dfd3071 100644
--- a/core/res/res/values/symbols.xml
+++ b/core/res/res/values/symbols.xml
@@ -312,6 +312,24 @@
   <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" />
@@ -2042,4 +2060,5 @@
   <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" />
 </resources>
diff --git a/core/res/res/values/themes.xml b/core/res/res/values/themes.xml
index d0097aac..0577659 100644
--- a/core/res/res/values/themes.xml
+++ b/core/res/res/values/themes.xml
@@ -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>
diff --git a/core/res/res/values/themes_material.xml b/core/res/res/values/themes_material.xml
index 008e170..aefca72 100644
--- a/core/res/res/values/themes_material.xml
+++ b/core/res/res/values/themes_material.xml
@@ -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>
@@ -489,7 +489,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>
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/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/src/android/os/InputMethodTest.java b/core/tests/inputmethodtests/src/android/os/InputMethodTest.java
index cb85fc5..d56c5a9 100644
--- a/core/tests/inputmethodtests/src/android/os/InputMethodTest.java
+++ b/core/tests/inputmethodtests/src/android/os/InputMethodTest.java
@@ -53,10 +53,8 @@
     public void testVoiceImes() throws Exception {
         // locale: en_US
         assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_EN_US, !IS_SYSTEM_READY,
-                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
-                "DummyDefaultEnKeyboardIme", "DummyDefaultAutoVoiceIme");
+                "DummyDefaultEnKeyboardIme");
         assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_EN_US, !IS_SYSTEM_READY,
-                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
                 "DummyDefaultEnKeyboardIme");
         assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_EN_US, IS_SYSTEM_READY,
                 "DummyDefaultAutoVoiceIme", "DummyDefaultEnKeyboardIme");
@@ -66,10 +64,8 @@
 
         // locale: en_GB
         assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_EN_GB, !IS_SYSTEM_READY,
-                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
-                "DummyDefaultEnKeyboardIme", "DummyDefaultAutoVoiceIme");
+                "DummyDefaultEnKeyboardIme");
         assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_EN_GB, !IS_SYSTEM_READY,
-                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
                 "DummyDefaultEnKeyboardIme");
         assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_EN_GB, IS_SYSTEM_READY,
                 "DummyDefaultEnKeyboardIme", "DummyDefaultAutoVoiceIme");
@@ -79,10 +75,8 @@
 
         // locale: ja_JP
         assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_JA_JP, !IS_SYSTEM_READY,
-                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
-                "DummyDefaultEnKeyboardIme", "DummyDefaultAutoVoiceIme");
+                "DummyDefaultEnKeyboardIme");
         assertDefaultEnabledImes(getImesWithoutDefaultVoiceIme(), LOCALE_JA_JP, !IS_SYSTEM_READY,
-                "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
                 "DummyDefaultEnKeyboardIme");
         assertDefaultEnabledImes(getImesWithDefaultVoiceIme(), LOCALE_JA_JP, IS_SYSTEM_READY,
                 "DummyNonDefaultAutoVoiceIme0", "DummyNonDefaultAutoVoiceIme1",
@@ -96,40 +90,35 @@
     public void testKeyboardImes() throws Exception {
         // locale: en_US
         assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_US, !IS_SYSTEM_READY,
-                "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
-                "com.android.apps.inputmethod.hindi");
+                "com.android.apps.inputmethod.latin", "com.android.apps.inputmethod.hindi");
         assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_US, IS_SYSTEM_READY,
                 "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
                 "com.android.apps.inputmethod.hindi");
 
         // locale: en_GB
         assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_GB, !IS_SYSTEM_READY,
-                "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
-                "com.android.apps.inputmethod.hindi");
+                "com.android.apps.inputmethod.latin", "com.android.apps.inputmethod.hindi");
         assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_GB, IS_SYSTEM_READY,
                 "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
                 "com.android.apps.inputmethod.hindi");
 
         // locale: en_IN
         assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_EN_IN, !IS_SYSTEM_READY,
-                "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
-                "com.android.apps.inputmethod.hindi");
+                "com.android.apps.inputmethod.latin", "com.android.apps.inputmethod.hindi");
         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.voice", "com.android.apps.inputmethod.latin",
-                "com.android.apps.inputmethod.hindi");
+                "com.android.apps.inputmethod.latin", "com.android.apps.inputmethod.hindi");
         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.voice", "com.android.apps.inputmethod.latin",
-                "com.android.apps.inputmethod.hindi");
+                "com.android.apps.inputmethod.latin", "com.android.apps.inputmethod.hindi");
         assertDefaultEnabledImes(getSamplePreinstalledImes(), LOCALE_JA_JP, IS_SYSTEM_READY,
                 "com.android.apps.inputmethod.voice", "com.android.apps.inputmethod.latin",
                 "com.android.apps.inputmethod.hindi", "com.android.apps.inputmethod.japanese");
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/media/java/android/media/AudioService.java b/media/java/android/media/AudioService.java
index 6c9fb9a..86c4d02 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;
@@ -2939,9 +2938,9 @@
     private boolean isInCommunication() {
         boolean IsInCall = false;
 
-        TelecommManager telecommManager =
-                (TelecommManager) mContext.getSystemService(Context.TELECOMM_SERVICE);
-        IsInCall = telecommManager.isInCall();
+        TelecomManager telecomManager =
+                (TelecomManager) mContext.getSystemService(Context.TELECOM_SERVICE);
+        IsInCall = telecomManager.isInCall();
 
         return (IsInCall || getMode() == AudioManager.MODE_IN_COMMUNICATION);
     }
diff --git a/media/java/android/media/tv/TvInputService.java b/media/java/android/media/tv/TvInputService.java
index 317d472..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";
 
     /**
diff --git a/media/java/android/media/tv/TvView.java b/media/java/android/media/tv/TvView.java
index 213e34c..0949b1a 100644
--- a/media/java/android/media/tv/TvView.java
+++ b/media/java/android/media/tv/TvView.java
@@ -57,8 +57,7 @@
  */
 public class TvView extends ViewGroup {
     private static final String TAG = "TvView";
-    // STOPSHIP: Turn debugging off.
-    private static final boolean DEBUG = true;
+    private static final boolean DEBUG = false;
 
     private static final int VIDEO_SIZE_VALUE_UNKNOWN = 0;
 
diff --git a/packages/PrintSpooler/res/layout/print_activity_controls.xml b/packages/PrintSpooler/res/layout/print_activity_controls.xml
index f0b8adf..0bf64aa 100644
--- a/packages/PrintSpooler/res/layout/print_activity_controls.xml
+++ b/packages/PrintSpooler/res/layout/print_activity_controls.xml
@@ -59,6 +59,7 @@
                     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"
@@ -89,7 +90,8 @@
                 <Spinner
                     android:id="@+id/paper_size_spinner"
                     android:layout_width="fill_parent"
-                    android:layout_height="wrap_content">
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dip">
                 </Spinner>
 
             </LinearLayout>
@@ -116,7 +118,8 @@
                 <Spinner
                     android:id="@+id/color_spinner"
                     android:layout_width="fill_parent"
-                    android:layout_height="wrap_content">
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dip">
                 </Spinner>
 
             </LinearLayout>
@@ -143,7 +146,8 @@
                 <Spinner
                     android:id="@+id/orientation_spinner"
                     android:layout_width="fill_parent"
-                    android:layout_height="wrap_content">
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dip">
                 </Spinner>
 
             </LinearLayout>
@@ -170,7 +174,8 @@
                 <Spinner
                     android:id="@+id/range_options_spinner"
                     android:layout_width="fill_parent"
-                    android:layout_height="wrap_content">
+                    android:layout_height="wrap_content"
+                    android:layout_marginStart="4dip">
                 </Spinner>
 
             </LinearLayout>
@@ -202,6 +207,7 @@
                     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"
@@ -239,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/src/com/android/printspooler/model/PageContentRepository.java b/packages/PrintSpooler/src/com/android/printspooler/model/PageContentRepository.java
index 1d8261b..14c41da 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/model/PageContentRepository.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/model/PageContentRepository.java
@@ -345,7 +345,7 @@
             Iterator<Map.Entry<Integer, RenderedPage>> iterator =
                     mRenderedPages.entrySet().iterator();
             while (iterator.hasNext()) {
-                iterator.next().getValue().recycle();
+                iterator.next();
                 iterator.remove();
             }
         }
@@ -425,10 +425,6 @@
             return content.getBitmap().getByteCount();
         }
 
-        public void recycle() {
-            content.getBitmap().recycle();
-        }
-
         public void erase() {
             content.getBitmap().eraseColor(Color.WHITE);
         }
@@ -738,7 +734,6 @@
                                 + " with different size.");
                     }
                     mPageContentCache.removeRenderedPage(mPageIndex);
-                    mRenderedPage.recycle();
                     mRenderedPage = null;
                 }
 
@@ -762,7 +757,6 @@
                             Log.i(LOG_TAG, "Recycling bitmap for page: " + mPageIndex
                                    + " with different size.");
                         }
-                        renderedPage.recycle();
                         continue;
                     }
 
diff --git a/packages/PrintSpooler/src/com/android/printspooler/model/RemotePrintDocument.java b/packages/PrintSpooler/src/com/android/printspooler/model/RemotePrintDocument.java
index 429437d..c53fcad 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/model/RemotePrintDocument.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/model/RemotePrintDocument.java
@@ -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();
diff --git a/packages/PrintSpooler/src/com/android/printspooler/widget/PageContentView.java b/packages/PrintSpooler/src/com/android/printspooler/widget/PageContentView.java
index c22c0e2..1000117 100644
--- a/packages/PrintSpooler/src/com/android/printspooler/widget/PageContentView.java
+++ b/packages/PrintSpooler/src/com/android/printspooler/widget/PageContentView.java
@@ -46,16 +46,12 @@
 
     private boolean mContentRequested;
 
-    private boolean mNeedsLayout;
-
     public PageContentView(Context context, AttributeSet attrs) {
         super(context, attrs);
     }
 
     @Override
-    protected void onLayout(boolean changed, int left, int top, int right, int bottom) {
-        super.onLayout(changed, left, top, right, bottom);
-        mNeedsLayout = false;
+    protected void onSizeChanged(int w, int h, int oldw, int oldh) {
         requestPageContentIfNeeded();
     }
 
@@ -91,7 +87,6 @@
 
         mEmptyState = emptyState;
         mContentRequested = false;
-        mNeedsLayout = mNeedsLayout || mediaSizeChanged || marginsChanged;
 
         // If there is no provider we want immediately to switch to
         // the empty state, so pages with no content appear blank.
@@ -104,7 +99,7 @@
 
     private void requestPageContentIfNeeded() {
         if (getWidth() > 0 && getHeight() > 0 && !mContentRequested
-                && mProvider != null && !mNeedsLayout) {
+                && mProvider != null) {
             mContentRequested = true;
             mProvider.getPageContent(new RenderSpec(getWidth(), getHeight(),
                     mMediaSize, mMinMargins), this);
diff --git a/packages/SystemUI/res/layout-sw600dp/navigation_bar.xml b/packages/SystemUI/res/layout-sw600dp/navigation_bar.xml
index b5983bb..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>
 
diff --git a/packages/SystemUI/res/layout/navigation_bar.xml b/packages/SystemUI/res/layout/navigation_bar.xml
index a165940..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"
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/src/com/android/systemui/power/PowerNotificationWarnings.java b/packages/SystemUI/src/com/android/systemui/power/PowerNotificationWarnings.java
index 4c7f8ec..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;
@@ -72,6 +73,7 @@
 
     private final Context mContext;
     private final NotificationManager mNoMan;
+    private final PowerManager mPowerMan;
     private final Handler mHandler = new Handler();
     private final Receiver mReceiver = new Receiver();
     private final Intent mOpenBatterySettings = settings(Intent.ACTION_POWER_USAGE_SUMMARY);
@@ -93,6 +95,7 @@
     public PowerNotificationWarnings(Context context, PhoneStatusBar phoneStatusBar) {
         mContext = context;
         mNoMan = (NotificationManager) context.getSystemService(Context.NOTIFICATION_SERVICE);
+        mPowerMan = (PowerManager) context.getSystemService(Context.POWER_SERVICE);
         mReceiver.init();
     }
 
@@ -356,9 +359,8 @@
         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 {
@@ -384,7 +386,7 @@
             } else if (action.equals(ACTION_STOP_SAVER)) {
                 dismissSaverNotification();
                 dismissLowBatteryNotification();
-                setSaverSetting(false);
+                setSaverMode(false);
             }
         }
     }
@@ -395,7 +397,7 @@
             AsyncTask.execute(new Runnable() {
                 @Override
                 public void run() {
-                    setSaverSetting(true);
+                    setSaverMode(true);
                 }
             });
         }
diff --git a/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java b/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
index ed5c126..2a2caa0 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/RecentsConfiguration.java
@@ -347,8 +347,8 @@
         Rect searchBarBounds = new Rect();
         getSearchBarBounds(windowWidth, windowHeight, topInset, searchBarBounds);
         if (isLandscape && hasTransposedSearchBar) {
-            // In landscape, the search bar appears on the left
-            taskStackBounds.set(searchBarBounds.right, topInset, windowWidth - rightInset, windowHeight);
+            // 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);
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 bbd0a0d..11b7b8b 100644
--- a/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java
+++ b/packages/SystemUI/src/com/android/systemui/recents/misc/SystemServicesProxy.java
@@ -179,6 +179,12 @@
                 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()) {
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 20eed3f..e323dd6 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/KeyguardBottomAreaView.java
@@ -30,7 +30,7 @@
 import android.os.RemoteException;
 import android.os.UserHandle;
 import android.provider.MediaStore;
-import android.telecomm.TelecommManager;
+import android.telecom.TelecomManager;
 import android.util.AttributeSet;
 import android.util.Log;
 import android.util.TypedValue;
@@ -331,7 +331,7 @@
     }
 
     public void launchPhone() {
-        final TelecommManager tm = TelecommManager.from(mContext);
+        final TelecomManager tm = TelecomManager.from(mContext);
         if (tm.isInCall()) {
             AsyncTask.execute(new Runnable() {
                 @Override
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 70b6952..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,6 +17,7 @@
 package com.android.systemui.statusbar.phone;
 
 import android.content.Context;
+import android.view.Choreographer;
 import android.view.KeyEvent;
 import android.view.LayoutInflater;
 import android.view.View;
@@ -43,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,
@@ -57,7 +59,7 @@
 
     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.
@@ -68,10 +70,27 @@
         // 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/NavigationBarView.java b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
index 0fb2192..e0319f0 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/NavigationBarView.java
@@ -507,7 +507,16 @@
         }
     }
 
-
+    @Override
+    public void setVisibility(int visibility) {
+        super.setVisibility(visibility);
+        boolean visible = visibility == View.VISIBLE;
+        getBackButton().getBackground().setVisible(visible, false /* restart */);
+        getHomeButton().getBackground().setVisible(visible, false /* restart */);
+        getRecentsButton().getBackground().setVisible(visible, false /* restart */);
+        getMenuButton().getBackground().setVisible(visible, false /* restart */);
+        getImeSwitchButton().getBackground().setVisible(visible, false /* restart */);
+    }
 
     /*
     @Override
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 e6db2c8..5f582bb 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/PhoneStatusBar.java
@@ -2364,8 +2364,6 @@
         mStackScroller.setVisibility(View.VISIBLE);
         mNotificationPanel.setVisibility(View.GONE);
 
-        setAreThereNotifications(); // show the clear button
-
         mNotificationPanel.closeQs();
 
         mExpandedVisible = false;
@@ -3580,6 +3578,10 @@
         disable(mDisabledUnmodified, true /* animate */);
     }
 
+    public boolean isKeyguardFadingAway() {
+        return mKeyguardFadingAway;
+    }
+
     /**
      * Notifies that the Keyguard fading away animation is done.
      */
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 237b782..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,7 +27,7 @@
 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;
@@ -93,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)) {
@@ -115,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);
 
@@ -279,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);
 
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 b4e2d57..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;
@@ -323,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) {
@@ -342,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 42cfd39..78554525 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarWindowView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/phone/StatusBarWindowView.java
@@ -55,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;
     }
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 16c0e66..b814b61 100644
--- a/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java
+++ b/packages/SystemUI/src/com/android/systemui/statusbar/policy/KeyButtonView.java
@@ -17,11 +17,15 @@
 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.Paint;
+import android.graphics.RectF;
 import android.hardware.input.InputManager;
 import android.media.AudioManager;
 import android.os.Bundle;
@@ -34,10 +38,12 @@
 import android.view.KeyEvent;
 import android.view.MotionEvent;
 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 com.android.systemui.R;
 
@@ -50,15 +56,21 @@
 
     // TODO: Get rid of this
     public static final float DEFAULT_QUIESCENT_ALPHA = 1f;
+    public static final float MAX_ALPHA = 0.15f;
+    public static final float GLOW_MAX_SCALE_FACTOR = 1.5f;
 
     private long mDownTime;
     private int mCode;
     private int mTouchSlop;
+    private float mGlowAlpha = 0f;
+    private float mGlowScale = 1f;
     private float mDrawingAlpha = 1f;
     private float mQuiescentAlpha = DEFAULT_QUIESCENT_ALPHA;
     private boolean mSupportsLongpress = true;
+    private AnimatorSet mPressedAnim;
     private Animator mAnimateToQuiescent = new ObjectAnimator();
-    private Drawable mBackground;
+    private Paint mRipplePaint;
+    private final TimeInterpolator mInterpolator = (TimeInterpolator) new LogInterpolator();
     private AudioManager mAudioManager;
 
     private final Runnable mCheckLongPress = new Runnable() {
@@ -90,11 +102,6 @@
 
         mSupportsLongpress = a.getBoolean(R.styleable.KeyButtonView_keyRepeat, true);
 
-        Drawable d = getBackground();
-        if (d != null) {
-            mBackground = d.mutate();
-            setBackground(mBackground);
-        }
 
         setDrawingAlpha(mQuiescentAlpha);
 
@@ -134,13 +141,45 @@
         return super.performAccessibilityAction(action, arguments);
     }
 
+    private Paint getRipplePaint() {
+        if (mRipplePaint == null) {
+            mRipplePaint = new Paint();
+            mRipplePaint.setAntiAlias(true);
+            mRipplePaint.setColor(0xffffffff);
+        }
+        return mRipplePaint;
+    }
+
+    @Override
+    protected void onDraw(Canvas canvas) {
+        final Paint p = getRipplePaint();
+        p.setAlpha((int)(MAX_ALPHA * mDrawingAlpha * mGlowAlpha * 255));
+
+        final float w = getWidth();
+        final float h = getHeight();
+        final boolean horizontal = w > h;
+        final float diameter = (horizontal ? w : h) * 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);
+
+        super.onDraw(canvas);
+    }
+
     public void setQuiescentAlpha(float alpha, boolean animate) {
         mAnimateToQuiescent.cancel();
         alpha = Math.min(Math.max(alpha, 0), 1);
         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 {
@@ -162,34 +201,79 @@
 
     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);
+    public float getGlowAlpha() {
+        return mGlowAlpha;
     }
 
-    private void setHotspot(float x, float y) {
-        if (mBackground != null) {
-            mBackground.setHotspot(x, y);
+    public void setGlowAlpha(float x) {
+        mGlowAlpha = x;
+        invalidate();
+    }
+
+    public float getGlowScale() {
+        return mGlowScale;
+    }
+
+    public void setGlowScale(float x) {
+        mGlowScale = x;
+        final float w = getWidth();
+        final float h = getHeight();
+        if (GLOW_MAX_SCALE_FACTOR <= 1.0f) {
+            // this only works if we know the glow will never leave our bounds
+            invalidate();
+        } else {
+            final float rx = (w * (GLOW_MAX_SCALE_FACTOR - 1.0f)) / 2.0f + 1.0f;
+            final float ry = (h * (GLOW_MAX_SCALE_FACTOR - 1.0f)) / 2.0f + 1.0f;
+            com.android.systemui.SwipeHelper.invalidateGlobalRegion(
+                    this,
+                    new RectF(getLeft() - rx,
+                              getTop() - ry,
+                              getRight() + rx,
+                              getBottom() + ry));
+
+            // also invalidate our immediate parent to help avoid situations where nearby glows
+            // interfere
+            ((View)getParent()).invalidate();
         }
     }
 
+    public void setPressed(boolean pressed) {
+        if (pressed != isPressed()) {
+            if (mPressedAnim != null && mPressedAnim.isRunning()) {
+                mPressedAnim.cancel();
+            }
+            final AnimatorSet as = mPressedAnim = new AnimatorSet();
+            final ObjectAnimator scaleAnimator = ObjectAnimator.ofFloat(this,
+                    "glowScale", GLOW_MAX_SCALE_FACTOR);
+            scaleAnimator.setInterpolator(mInterpolator);
+            if (pressed) {
+                mGlowScale = 0f;
+                if (mGlowAlpha < mQuiescentAlpha)
+                    mGlowAlpha = mQuiescentAlpha;
+                setDrawingAlpha(1f);
+                as.playTogether(
+                    ObjectAnimator.ofFloat(this, "glowAlpha", 1f),
+                    scaleAnimator
+                );
+                as.setDuration(500);
+            } else {
+                mAnimateToQuiescent.cancel();
+                mAnimateToQuiescent = animateToQuiescent();
+                as.playTogether(
+                    ObjectAnimator.ofFloat(this, "glowAlpha", mGlowAlpha, mGlowAlpha * .2f, 0f),
+                    scaleAnimator,
+                    mAnimateToQuiescent
+                );
+                as.setDuration(500);
+            }
+            as.start();
+        }
+        super.setPressed(pressed);
+    }
+
     public boolean onTouchEvent(MotionEvent ev) {
         final int action = ev.getAction();
         int x, y;
@@ -209,7 +293,6 @@
                     removeCallbacks(mCheckLongPress);
                     postDelayed(mCheckLongPress, ViewConfiguration.getLongPressTimeout());
                 }
-                setHotspot(ev.getX(), ev.getY());
                 break;
             case MotionEvent.ACTION_MOVE:
                 x = (int)ev.getX();
@@ -218,7 +301,6 @@
                         && x < getWidth() + mTouchSlop
                         && y >= -mTouchSlop
                         && y < getHeight() + mTouchSlop);
-                setHotspot(ev.getX(), ev.getY());
                 break;
             case MotionEvent.ACTION_CANCEL:
                 setPressed(false);
@@ -272,6 +354,17 @@
         InputManager.getInstance().injectInputEvent(ev,
                 InputManager.INJECT_INPUT_EVENT_MODE_ASYNC);
     }
+
+    /**
+    * 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/policy/src/com/android/internal/policy/impl/PhoneWindow.java b/policy/src/com/android/internal/policy/impl/PhoneWindow.java
index 92171c1..6f7f1fb 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;
 
@@ -211,6 +212,7 @@
     private ProgressBar mHorizontalProgressBar;
 
     private int mBackgroundResource = 0;
+    private int mBackgroundFallbackResource = 0;
 
     private Drawable mBackgroundDrawable;
 
@@ -1326,6 +1328,9 @@
             if (mDecor != null) {
                 mDecor.setWindowBackground(drawable);
             }
+            if (mBackgroundFallbackResource != 0) {
+                mDecor.setBackgroundFallback(drawable != null ? 0 : mBackgroundFallbackResource);
+            }
         }
     }
 
@@ -2153,6 +2158,7 @@
 
         private View mStatusColorView;
         private View mNavigationColorView;
+        private final BackgroundFallback mBackgroundFallback = new BackgroundFallback();
 
         private int mLastTopInset = 0;
         private int mLastBottomInset = 0;
@@ -2165,6 +2171,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();
@@ -3342,6 +3359,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: "
@@ -3557,6 +3576,10 @@
                 }
             }
 
+            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_ACTIVITY_TRANSITIONS)) {
diff --git a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java
index 4713a98..02adef4 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;
@@ -72,7 +68,7 @@
 import android.service.dreams.DreamService;
 import android.service.dreams.IDreamManager;
 import android.speech.RecognizerIntent;
-import android.telecomm.TelecommManager;
+import android.telecom.TelecomManager;
 import android.util.DisplayMetrics;
 import android.util.EventLog;
 import android.util.Log;
@@ -101,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;
@@ -120,9 +115,7 @@
 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;
@@ -231,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
@@ -2131,8 +2127,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() {
@@ -2221,8 +2217,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;
                 }
@@ -4322,9 +4318,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
@@ -4336,14 +4332,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.isInCall()
+                        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.
@@ -4369,10 +4365,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 {
@@ -4409,19 +4405,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.isInCall() && 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
@@ -4459,9 +4455,9 @@
             case KeyEvent.KEYCODE_MEDIA_PAUSE:
             case KeyEvent.KEYCODE_MEDIA_PLAY_PAUSE:
                 if (down) {
-                    TelecommManager telecommManager = getTelecommService();
-                    if (telecommManager != null) {
-                        if (telecommManager.isInCall()) {
+                    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;
@@ -4494,12 +4490,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.)
@@ -4778,7 +4774,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.
diff --git a/services/core/java/com/android/server/NsdService.java b/services/core/java/com/android/server/NsdService.java
index cb1748d..39aa972 100644
--- a/services/core/java/com/android/server/NsdService.java
+++ b/services/core/java/com/android/server/NsdService.java
@@ -716,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/am/ActiveServices.java b/services/core/java/com/android/server/am/ActiveServices.java
index 599c3b9..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;
@@ -609,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
@@ -639,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;
@@ -751,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) {
@@ -1445,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.
@@ -1700,7 +1722,7 @@
                 b.client.updateHasAboveClientLocked();
             }
             if (s.app != null) {
-                updateServiceClientActivitiesLocked(s.app, c);
+                updateServiceClientActivitiesLocked(s.app, c, true);
             }
         }
         clist = mServiceConnections.get(binder);
@@ -2077,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);
+                    }
+                }
             }
         }
 
@@ -2085,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 2c39691..95d33e7 100755
--- a/services/core/java/com/android/server/am/ActivityManagerService.java
+++ b/services/core/java/com/android/server/am/ActivityManagerService.java
@@ -937,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;
@@ -4866,7 +4873,7 @@
         try {
             File tracesDir = tracesFile.getParentFile();
             if (!tracesDir.exists()) {
-                tracesFile.mkdirs();
+                tracesDir.mkdirs();
                 if (!SELinux.restorecon(tracesDir)) {
                     return null;
                 }
@@ -4976,7 +4983,7 @@
             final File tracesTmp = new File(tracesDir, "__tmp__");
             try {
                 if (!tracesDir.exists()) {
-                    tracesFile.mkdirs();
+                    tracesDir.mkdirs();
                     if (!SELinux.restorecon(tracesDir.getPath())) {
                         return;
                     }
@@ -6242,6 +6249,7 @@
             synchronized (this) {
                 if (DEBUG_LOCKSCREEN) logLockScreen("");
                 mWindowManager.keyguardWaitingForActivityDrawn();
+                mKeyguardWaitingForDraw = true;
             }
         } finally {
             Binder.restoreCallingIdentity(token);
@@ -9935,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() {
@@ -9961,6 +9969,7 @@
         if (mWentToSleep && !mRunningVoice) {
             if (!mSleeping) {
                 mSleeping = true;
+                mKeyguardWaitingForDraw = false;
                 mStackSupervisor.goingToSleepLocked();
 
                 // Initialize the wake times of all processes.
@@ -10070,6 +10079,7 @@
             try {
                 if (DEBUG_LOCKSCREEN) logLockScreen(" shown=" + shown);
                 mLockScreenShown = shown;
+                mKeyguardWaitingForDraw = false;
                 comeOutOfSleepIfNeededLocked();
             } finally {
                 Binder.restoreCallingIdentity(ident);
@@ -16404,8 +16414,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;
@@ -17793,7 +17803,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");
+            }
         }
     }
 
diff --git a/services/core/java/com/android/server/am/ActivityStack.java b/services/core/java/com/android/server/am/ActivityStack.java
index d71f94e..e224ac0 100755
--- a/services/core/java/com/android/server/am/ActivityStack.java
+++ b/services/core/java/com/android/server/am/ActivityStack.java
@@ -3195,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();
diff --git a/services/core/java/com/android/server/am/ActivityStackSupervisor.java b/services/core/java/com/android/server/am/ActivityStackSupervisor.java
index b8261a4..7b6a202 100644
--- a/services/core/java/com/android/server/am/ActivityStackSupervisor.java
+++ b/services/core/java/com/android/server/am/ActivityStackSupervisor.java
@@ -350,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);
             }
 
@@ -1200,6 +1203,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;
     }
 
@@ -3261,6 +3268,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);
             }
         }
@@ -3902,8 +3913,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/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/ProcessList.java b/services/core/java/com/android/server/am/ProcessList.java
index 80d0510..5022b28 100644
--- a/services/core/java/com/android/server/am/ProcessList.java
+++ b/services/core/java/com/android/server/am/ProcessList.java
@@ -124,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;
@@ -138,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;
@@ -300,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) {
diff --git a/services/core/java/com/android/server/input/InputManagerService.java b/services/core/java/com/android/server/input/InputManagerService.java
index 9c567ac..81b579d 100644
--- a/services/core/java/com/android/server/input/InputManagerService.java
+++ b/services/core/java/com/android/server/input/InputManagerService.java
@@ -1387,7 +1387,7 @@
         }
 
         if ((switchMask & SW_CAMERA_LENS_COVER_BIT) != 0) {
-            final boolean lensCovered = ((switchValues & SW_CAMERA_LENS_COVER_BIT) == 0);
+            final boolean lensCovered = ((switchValues & SW_CAMERA_LENS_COVER_BIT) != 0);
             mWindowManagerCallbacks.notifyCameraLensCoverSwitchChanged(whenNanos, lensCovered);
         }
 
diff --git a/services/core/java/com/android/server/media/MediaSessionService.java b/services/core/java/com/android/server/media/MediaSessionService.java
index a12dd1c..aaa29fc 100644
--- a/services/core/java/com/android/server/media/MediaSessionService.java
+++ b/services/core/java/com/android/server/media/MediaSessionService.java
@@ -31,6 +31,7 @@
 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;
@@ -800,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");
                     }
diff --git a/services/core/java/com/android/server/notification/ZenModeHelper.java b/services/core/java/com/android/server/notification/ZenModeHelper.java
index 41d7fa8f..479af89 100644
--- a/services/core/java/com/android/server/notification/ZenModeHelper.java
+++ b/services/core/java/com/android/server/notification/ZenModeHelper.java
@@ -40,7 +40,7 @@
 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;
 
@@ -346,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);
         }
diff --git a/services/core/java/com/android/server/power/PowerManagerService.java b/services/core/java/com/android/server/power/PowerManagerService.java
index eeebe04..c79a6d6 100644
--- a/services/core/java/com/android/server/power/PowerManagerService.java
+++ b/services/core/java/com/android/server/power/PowerManagerService.java
@@ -416,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.
@@ -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, lowPowerModeEnabled ? 1 : 0);
-            mLowPowerModeEnabled = lowPowerModeEnabled;
             BackgroundThread.getHandler().post(new Runnable() {
                 @Override
                 public void run() {
@@ -2083,6 +2062,35 @@
         }
     }
 
+    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();
@@ -2347,7 +2355,7 @@
             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);
@@ -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/tv/TvInputHal.java b/services/core/java/com/android/server/tv/TvInputHal.java
index c7d95aa..558ffb5 100644
--- a/services/core/java/com/android/server/tv/TvInputHal.java
+++ b/services/core/java/com/android/server/tv/TvInputHal.java
@@ -32,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;
diff --git a/services/core/java/com/android/server/tv/TvInputManagerService.java b/services/core/java/com/android/server/tv/TvInputManagerService.java
index adae84fd..5bfc834 100644
--- a/services/core/java/com/android/server/tv/TvInputManagerService.java
+++ b/services/core/java/com/android/server/tv/TvInputManagerService.java
@@ -95,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;
diff --git a/telecomm/java/android/telecomm/AudioState.aidl b/telecomm/java/android/telecom/AudioState.aidl
similarity index 95%
rename from telecomm/java/android/telecomm/AudioState.aidl
rename to telecomm/java/android/telecom/AudioState.aidl
index 03772b6..b36e238 100644
--- a/telecomm/java/android/telecomm/AudioState.aidl
+++ b/telecomm/java/android/telecom/AudioState.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/AudioState.java b/telecomm/java/android/telecom/AudioState.java
similarity index 99%
rename from telecomm/java/android/telecomm/AudioState.java
rename to telecomm/java/android/telecom/AudioState.java
index 314704b..d0e2860 100644
--- a/telecomm/java/android/telecomm/AudioState.java
+++ b/telecomm/java/android/telecom/AudioState.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.os.Parcel;
 import android.os.Parcelable;
diff --git a/telecomm/java/android/telecomm/Call.java b/telecomm/java/android/telecom/Call.java
similarity index 94%
rename from telecomm/java/android/telecomm/Call.java
rename to telecomm/java/android/telecom/Call.java
index 7ada9b1..1d33b3b 100644
--- a/telecomm/java/android/telecomm/Call.java
+++ b/telecomm/java/android/telecom/Call.java
@@ -14,10 +14,9 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.annotation.SystemApi;
-import android.app.PendingIntent;
 import android.net.Uri;
 import android.os.Bundle;
 import android.telephony.DisconnectCause;
@@ -108,7 +107,7 @@
 
         /**
          * @return The presentation requirements for the handle. See
-         * {@link TelecommManager} for valid values.
+         * {@link TelecomManager} for valid values.
          */
         public int getHandlePresentation() {
             return mHandlePresentation;
@@ -123,7 +122,7 @@
 
         /**
          * @return The presentation requirements for the caller display name. See
-         * {@link TelecommManager} for valid values.
+         * {@link TelecomManager} for valid values.
          */
         public int getCallerDisplayNamePresentation() {
             return mCallerDisplayNamePresentation;
@@ -193,7 +192,7 @@
         }
 
         /**
-         * @return The current {@link android.telecomm.StatusHints}, or {@code null} if none
+         * @return The current {@link android.telecom.StatusHints}, or {@code null} if none
          * have been set.
          */
         public StatusHints getStatusHints() {
@@ -369,7 +368,7 @@
     }
 
     private final Phone mPhone;
-    private final String mTelecommCallId;
+    private final String mTelecomCallId;
     private final InCallAdapter mInCallAdapter;
     private final List<String> mChildrenIds = new ArrayList<>();
     private final List<Call> mChildren = new ArrayList<>();
@@ -402,7 +401,7 @@
      * @param videoState The video state in which to answer the call.
      */
     public void answer(int videoState) {
-        mInCallAdapter.answerCall(mTelecommCallId, videoState);
+        mInCallAdapter.answerCall(mTelecomCallId, videoState);
     }
 
     /**
@@ -412,28 +411,28 @@
      * @param textMessage An optional text message with which to respond.
      */
     public void reject(boolean rejectWithMessage, String textMessage) {
-        mInCallAdapter.rejectCall(mTelecommCallId, rejectWithMessage, textMessage);
+        mInCallAdapter.rejectCall(mTelecomCallId, rejectWithMessage, textMessage);
     }
 
     /**
      * Instructs this {@code Call} to disconnect.
      */
     public void disconnect() {
-        mInCallAdapter.disconnectCall(mTelecommCallId);
+        mInCallAdapter.disconnectCall(mTelecomCallId);
     }
 
     /**
      * Instructs this {@code Call} to go on hold.
      */
     public void hold() {
-        mInCallAdapter.holdCall(mTelecommCallId);
+        mInCallAdapter.holdCall(mTelecomCallId);
     }
 
     /**
      * Instructs this {@link #STATE_HOLDING} call to release from hold.
      */
     public void unhold() {
-        mInCallAdapter.unholdCall(mTelecommCallId);
+        mInCallAdapter.unholdCall(mTelecomCallId);
     }
 
     /**
@@ -445,7 +444,7 @@
      *         value must be one of {@code '0'} through {@code '9'}, {@code '*'} or {@code '#'}.
      */
     public void playDtmfTone(char digit) {
-        mInCallAdapter.playDtmfTone(mTelecommCallId, digit);
+        mInCallAdapter.playDtmfTone(mTelecomCallId, digit);
     }
 
     /**
@@ -456,7 +455,7 @@
      * currently playing, this method will do nothing.
      */
     public void stopDtmfTone() {
-        mInCallAdapter.stopDtmfTone(mTelecommCallId);
+        mInCallAdapter.stopDtmfTone(mTelecomCallId);
     }
 
     /**
@@ -465,10 +464,10 @@
      * 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
+     * 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 TelecommManager#DTMF_CHARACTER_WAIT} symbol, this
+     * 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
@@ -478,7 +477,7 @@
      * @param proceed Whether or not to continue with the post-dial sequence.
      */
     public void postDialContinue(boolean proceed) {
-        mInCallAdapter.postDialContinue(mTelecommCallId, proceed);
+        mInCallAdapter.postDialContinue(mTelecomCallId, proceed);
     }
 
     /**
@@ -486,7 +485,7 @@
      * an outgoing call.
      */
     public void phoneAccountSelected(PhoneAccountHandle accountHandle) {
-        mInCallAdapter.phoneAccountSelected(mTelecommCallId, accountHandle);
+        mInCallAdapter.phoneAccountSelected(mTelecomCallId, accountHandle);
 
     }
 
@@ -497,7 +496,7 @@
      */
     public void conference(Call callToConferenceWith) {
         if (callToConferenceWith != null) {
-            mInCallAdapter.conference(mTelecommCallId, callToConferenceWith.mTelecommCallId);
+            mInCallAdapter.conference(mTelecomCallId, callToConferenceWith.mTelecomCallId);
         }
     }
 
@@ -506,21 +505,21 @@
      * connected.
      */
     public void splitFromConference() {
-        mInCallAdapter.splitFromConference(mTelecommCallId);
+        mInCallAdapter.splitFromConference(mTelecomCallId);
     }
 
     /**
      * Merges the calls within this conference. See {@link PhoneCapabilities#MERGE_CONFERENCE}.
      */
     public void mergeConference() {
-        mInCallAdapter.mergeConference(mTelecommCallId);
+        mInCallAdapter.mergeConference(mTelecomCallId);
     }
 
     /**
      * Swaps the calls within this conference. See {@link PhoneCapabilities#SWAP_CONFERENCE}.
      */
     public void swapConference() {
-        mInCallAdapter.swapConference(mTelecommCallId);
+        mInCallAdapter.swapConference(mTelecomCallId);
     }
 
     /**
@@ -531,7 +530,7 @@
      */
     public Call getParent() {
         if (mParentId != null) {
-            return mPhone.internalGetCallByTelecommId(mParentId);
+            return mPhone.internalGetCallByTelecomId(mParentId);
         }
         return null;
     }
@@ -548,7 +547,7 @@
             mChildren.clear();
 
             for(String id : mChildrenIds) {
-                Call call = mPhone.internalGetCallByTelecommId(id);
+                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;
@@ -632,16 +631,16 @@
     }
 
     /** {@hide} */
-    Call(Phone phone, String telecommCallId, InCallAdapter inCallAdapter) {
+    Call(Phone phone, String telecomCallId, InCallAdapter inCallAdapter) {
         mPhone = phone;
-        mTelecommCallId = telecommCallId;
+        mTelecomCallId = telecomCallId;
         mInCallAdapter = inCallAdapter;
         mState = STATE_NEW;
     }
 
     /** {@hide} */
     final String internalGetCallId() {
-        return mTelecommCallId;
+        return mTelecomCallId;
     }
 
     /** {@hide} */
diff --git a/telecomm/java/android/telecomm/CallProperties.java b/telecomm/java/android/telecom/CallProperties.java
similarity index 96%
rename from telecomm/java/android/telecomm/CallProperties.java
rename to telecomm/java/android/telecom/CallProperties.java
index 90eb0cb..b1b82e2 100644
--- a/telecomm/java/android/telecomm/CallProperties.java
+++ b/telecomm/java/android/telecom/CallProperties.java
@@ -14,7 +14,7 @@
  * limitations under the License
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * Defines properties of a phone call which may be affected by changes to the call.
diff --git a/telecomm/java/android/telecomm/CallState.java b/telecomm/java/android/telecom/CallState.java
similarity index 97%
rename from telecomm/java/android/telecomm/CallState.java
rename to telecomm/java/android/telecom/CallState.java
index 0770e26..7690847 100644
--- a/telecomm/java/android/telecomm/CallState.java
+++ b/telecomm/java/android/telecom/CallState.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.annotation.SystemApi;
 
@@ -33,7 +33,7 @@
 
     /**
      * 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
+     * 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.
      */
diff --git a/telecomm/java/android/telecomm/CameraCapabilities.aidl b/telecomm/java/android/telecom/CameraCapabilities.aidl
similarity index 96%
rename from telecomm/java/android/telecomm/CameraCapabilities.aidl
rename to telecomm/java/android/telecom/CameraCapabilities.aidl
index 08e6f43..c8e0c5e 100644
--- a/telecomm/java/android/telecomm/CameraCapabilities.aidl
+++ b/telecomm/java/android/telecom/CameraCapabilities.aidl
@@ -14,7 +14,7 @@
  * limitations under the License
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/CameraCapabilities.java b/telecomm/java/android/telecom/CameraCapabilities.java
similarity index 99%
rename from telecomm/java/android/telecomm/CameraCapabilities.java
rename to telecomm/java/android/telecom/CameraCapabilities.java
index 5f860db..f968c13 100644
--- a/telecomm/java/android/telecomm/CameraCapabilities.java
+++ b/telecomm/java/android/telecom/CameraCapabilities.java
@@ -14,7 +14,7 @@
  * limitations under the License
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.os.Parcel;
 import android.os.Parcelable;
diff --git a/telecomm/java/android/telecomm/Conference.java b/telecomm/java/android/telecom/Conference.java
similarity index 99%
rename from telecomm/java/android/telecomm/Conference.java
rename to telecomm/java/android/telecom/Conference.java
index a4f9c2c..ca85446 100644
--- a/telecomm/java/android/telecomm/Conference.java
+++ b/telecomm/java/android/telecom/Conference.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.telephony.DisconnectCause;
 
diff --git a/telecomm/java/android/telecomm/Connection.java b/telecomm/java/android/telecom/Connection.java
similarity index 98%
rename from telecomm/java/android/telecomm/Connection.java
rename to telecomm/java/android/telecom/Connection.java
index 2f25dcf..5f63af3 100644
--- a/telecomm/java/android/telecomm/Connection.java
+++ b/telecomm/java/android/telecom/Connection.java
@@ -14,12 +14,11 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
-import com.android.internal.telecomm.IVideoCallback;
-import com.android.internal.telecomm.IVideoProvider;
+import com.android.internal.telecom.IVideoCallback;
+import com.android.internal.telecom.IVideoProvider;
 
-import android.app.PendingIntent;
 import android.net.Uri;
 import android.os.Handler;
 import android.os.IBinder;
@@ -493,7 +492,7 @@
 
     /**
      * @return The presentation requirements for the address.
-     *         See {@link TelecommManager} for valid values.
+     *         See {@link TelecomManager} for valid values.
      */
     public final int getAddressPresentation() {
         return mAddressPresentation;
@@ -508,7 +507,7 @@
 
     /**
      * @return The presentation requirements for the handle.
-     *         See {@link TelecommManager} for valid values.
+     *         See {@link TelecomManager} for valid values.
      */
     public final int getCallerDisplayNamePresentation() {
         return mCallerDisplayNamePresentation;
@@ -666,7 +665,7 @@
      *
      * @param address The new address.
      * @param presentation The presentation requirements for the address.
-     *        See {@link TelecommManager} for valid values.
+     *        See {@link TelecomManager} for valid values.
      */
     public final void setAddress(Uri address, int presentation) {
         Log.d(this, "setAddress %s", address);
@@ -682,7 +681,7 @@
      *
      * @param callerDisplayName The new display name.
      * @param presentation The presentation requirements for the handle.
-     *        See {@link TelecommManager} for valid values.
+     *        See {@link TelecomManager} for valid values.
      */
     public final void setCallerDisplayName(String callerDisplayName, int presentation) {
         Log.d(this, "setCallerDisplayName %s", callerDisplayName);
diff --git a/telecomm/java/android/telecomm/ConnectionRequest.aidl b/telecomm/java/android/telecom/ConnectionRequest.aidl
similarity index 96%
rename from telecomm/java/android/telecomm/ConnectionRequest.aidl
rename to telecomm/java/android/telecom/ConnectionRequest.aidl
index 6081c22..de39c67 100644
--- a/telecomm/java/android/telecomm/ConnectionRequest.aidl
+++ b/telecomm/java/android/telecom/ConnectionRequest.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/ConnectionRequest.java b/telecomm/java/android/telecom/ConnectionRequest.java
similarity index 99%
rename from telecomm/java/android/telecomm/ConnectionRequest.java
rename to telecomm/java/android/telecom/ConnectionRequest.java
index d5a6aa5..71b481b 100644
--- a/telecomm/java/android/telecomm/ConnectionRequest.java
+++ b/telecomm/java/android/telecom/ConnectionRequest.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.net.Uri;
 import android.os.Bundle;
diff --git a/telecomm/java/android/telecomm/ConnectionService.java b/telecomm/java/android/telecom/ConnectionService.java
similarity index 98%
rename from telecomm/java/android/telecomm/ConnectionService.java
rename to telecomm/java/android/telecom/ConnectionService.java
index 05ddc27..cc80e22 100644
--- a/telecomm/java/android/telecomm/ConnectionService.java
+++ b/telecomm/java/android/telecom/ConnectionService.java
@@ -14,10 +14,9 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.annotation.SdkConstant;
-import android.app.PendingIntent;
 import android.app.Service;
 import android.content.ComponentName;
 import android.content.Intent;
@@ -29,9 +28,9 @@
 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 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;
@@ -50,7 +49,7 @@
      * 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";
+    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);
@@ -391,7 +390,7 @@
                     mAdapter.setOnHold(id);
                     break;
                 case Connection.STATE_NEW:
-                    // Nothing to tell Telecomm
+                    // Nothing to tell Telecom
                     break;
                 case Connection.STATE_RINGING:
                     mAdapter.setRinging(id);
@@ -506,8 +505,8 @@
     }
 
     /**
-     * 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
+     * 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(
diff --git a/telecomm/java/android/telecomm/ConnectionServiceAdapter.java b/telecomm/java/android/telecom/ConnectionServiceAdapter.java
similarity index 96%
rename from telecomm/java/android/telecomm/ConnectionServiceAdapter.java
rename to telecomm/java/android/telecom/ConnectionServiceAdapter.java
index 19f42d6..f6bcdc6 100644
--- a/telecomm/java/android/telecomm/ConnectionServiceAdapter.java
+++ b/telecomm/java/android/telecom/ConnectionServiceAdapter.java
@@ -14,15 +14,14 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
-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 com.android.internal.telecom.IConnectionServiceAdapter;
+import com.android.internal.telecom.RemoteServiceCallback;
 
 import java.util.Collections;
 import java.util.Iterator;
@@ -163,10 +162,10 @@
     }
 
     /**
-     * Asks Telecomm to start or stop a ringback tone for a call.
+     * 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 Telecomm should start playing a ringback tone.
+     * @param ringback Whether Telecom should start playing a ringback tone.
      */
     void setRingbackRequested(String callId, boolean ringback) {
         for (IConnectionServiceAdapter adapter : mAdapters) {
diff --git a/telecomm/java/android/telecomm/ConnectionServiceAdapterServant.java b/telecomm/java/android/telecom/ConnectionServiceAdapterServant.java
similarity index 98%
rename from telecomm/java/android/telecomm/ConnectionServiceAdapterServant.java
rename to telecomm/java/android/telecom/ConnectionServiceAdapterServant.java
index 2aac7fc..ffbbc8a 100644
--- a/telecomm/java/android/telecomm/ConnectionServiceAdapterServant.java
+++ b/telecomm/java/android/telecom/ConnectionServiceAdapterServant.java
@@ -14,18 +14,17 @@
  R* limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
-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 com.android.internal.telecom.IConnectionServiceAdapter;
+import com.android.internal.telecom.IVideoProvider;
+import com.android.internal.telecom.RemoteServiceCallback;
 
 import java.util.List;
 
diff --git a/telecomm/java/android/telecomm/GatewayInfo.aidl b/telecomm/java/android/telecom/GatewayInfo.aidl
similarity index 95%
rename from telecomm/java/android/telecomm/GatewayInfo.aidl
rename to telecomm/java/android/telecom/GatewayInfo.aidl
index bd81014..ad9858c 100644
--- a/telecomm/java/android/telecomm/GatewayInfo.aidl
+++ b/telecomm/java/android/telecom/GatewayInfo.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/GatewayInfo.java b/telecomm/java/android/telecom/GatewayInfo.java
similarity index 98%
rename from telecomm/java/android/telecomm/GatewayInfo.java
rename to telecomm/java/android/telecom/GatewayInfo.java
index a720284..583c3e2 100644
--- a/telecomm/java/android/telecomm/GatewayInfo.java
+++ b/telecomm/java/android/telecom/GatewayInfo.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.annotation.SystemApi;
 import android.net.Uri;
diff --git a/telecomm/java/android/telecomm/InCallAdapter.java b/telecomm/java/android/telecom/InCallAdapter.java
similarity index 82%
rename from telecomm/java/android/telecomm/InCallAdapter.java
rename to telecomm/java/android/telecom/InCallAdapter.java
index 899f35e..fd3cf2e 100644
--- a/telecomm/java/android/telecomm/InCallAdapter.java
+++ b/telecomm/java/android/telecom/InCallAdapter.java
@@ -14,15 +14,15 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.os.RemoteException;
 
-import com.android.internal.telecomm.IInCallAdapter;
+import com.android.internal.telecom.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
+ * 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
@@ -44,7 +44,7 @@
     }
 
     /**
-     * Instructs Telecomm to answer the specified call.
+     * 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.
@@ -57,7 +57,7 @@
     }
 
     /**
-     * Instructs Telecomm to reject the specified call.
+     * 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.
@@ -71,7 +71,7 @@
     }
 
     /**
-     * Instructs Telecomm to disconnect the specified call.
+     * Instructs Telecom to disconnect the specified call.
      *
      * @param callId The identifier of the call to disconnect.
      */
@@ -83,7 +83,7 @@
     }
 
     /**
-     * Instructs Telecomm to put the specified call on hold.
+     * Instructs Telecom to put the specified call on hold.
      *
      * @param callId The identifier of the call to put on hold.
      */
@@ -95,7 +95,7 @@
     }
 
     /**
-     * Instructs Telecomm to release the specified call from hold.
+     * Instructs Telecom to release the specified call from hold.
      *
      * @param callId The identifier of the call to release from hold.
      */
@@ -131,7 +131,7 @@
     }
 
     /**
-     * Instructs Telecomm to play a dual-tone multi-frequency signaling (DTMF) tone in a call.
+     * 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.
      *
@@ -147,7 +147,7 @@
     }
 
     /**
-     * Instructs Telecomm to stop any dual-tone multi-frequency signaling (DTMF) tone currently
+     * 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
@@ -163,17 +163,17 @@
     }
 
     /**
-     * Instructs Telecomm to continue playing a post-dial DTMF string.
+     * 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, Telecomm will notify the {@link InCallService} that the call
+     * 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 TelecommManager#DTMF_CHARACTER_PAUSE} symbol, Telecomm
+     * 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 TelecommManager#DTMF_CHARACTER_WAIT} symbol, Telecomm
+     * 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.
@@ -189,7 +189,7 @@
     }
 
     /**
-     * Instructs Telecomm to add a PhoneAccountHandle to the specified call
+     * 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
@@ -202,7 +202,7 @@
     }
 
     /**
-     * Instructs Telecomm to conference the specified call.
+     * Instructs Telecom to conference the specified call.
      *
      * @param callId The unique ID of the call.
      * @hide
@@ -215,7 +215,7 @@
     }
 
     /**
-     * Instructs Telecomm to split the specified call from any conference call with which it may be
+     * 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.
@@ -229,7 +229,7 @@
     }
 
     /**
-     * Instructs Telecomm to merge child calls of the specified conference call.
+     * Instructs Telecom to merge child calls of the specified conference call.
      */
     public void mergeConference(String callId) {
         try {
@@ -239,7 +239,7 @@
     }
 
     /**
-     * Instructs Telecomm to swap the child calls of the specified conference call.
+     * Instructs Telecom to swap the child calls of the specified conference call.
      */
     public void swapConference(String callId) {
         try {
@@ -249,7 +249,7 @@
     }
 
     /**
-     * Instructs Telecomm to turn the proximity sensor on.
+     * Instructs Telecom to turn the proximity sensor on.
      */
     public void turnProximitySensorOn() {
         try {
@@ -259,7 +259,7 @@
     }
 
     /**
-     * Instructs Telecomm to turn the proximity sensor off.
+     * 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
diff --git a/telecomm/java/android/telecomm/InCallService.java b/telecomm/java/android/telecom/InCallService.java
similarity index 97%
rename from telecomm/java/android/telecomm/InCallService.java
rename to telecomm/java/android/telecom/InCallService.java
index 51cd537..fa12756 100644
--- a/telecomm/java/android/telecomm/InCallService.java
+++ b/telecomm/java/android/telecom/InCallService.java
@@ -14,11 +14,10 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.annotation.SystemApi;
 import android.annotation.SdkConstant;
-import android.app.PendingIntent;
 import android.app.Service;
 import android.content.Intent;
 import android.os.Handler;
@@ -28,14 +27,14 @@
 import android.view.Surface;
 
 import com.android.internal.os.SomeArgs;
-import com.android.internal.telecomm.IInCallAdapter;
-import com.android.internal.telecomm.IInCallService;
+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. Telecomm binds to this service while there exists a live (active or incoming) call,
+ * 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}
@@ -47,7 +46,7 @@
      * 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.InCallService";
+    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;
diff --git a/telecomm/java/android/telecomm/Log.java b/telecomm/java/android/telecom/Log.java
similarity index 97%
rename from telecomm/java/android/telecomm/Log.java
rename to telecomm/java/android/telecom/Log.java
index 446ae75..73cc4a5 100644
--- a/telecomm/java/android/telecomm/Log.java
+++ b/telecomm/java/android/telecom/Log.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import java.security.MessageDigest;
 import java.security.NoSuchAlgorithmException;
@@ -28,8 +28,8 @@
  */
 final public class Log {
 
-    // Generic tag for all Telecomm Framework logging
-    private static final String TAG = "TelecommFramework";
+    // 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);
diff --git a/telecomm/java/android/telecomm/ParcelableCall.aidl b/telecomm/java/android/telecom/ParcelableCall.aidl
similarity index 96%
rename from telecomm/java/android/telecomm/ParcelableCall.aidl
rename to telecomm/java/android/telecom/ParcelableCall.aidl
index 18691d2..480e82f 100644
--- a/telecomm/java/android/telecomm/ParcelableCall.aidl
+++ b/telecomm/java/android/telecom/ParcelableCall.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/ParcelableCall.java b/telecomm/java/android/telecom/ParcelableCall.java
similarity index 98%
rename from telecomm/java/android/telecomm/ParcelableCall.java
rename to telecomm/java/android/telecom/ParcelableCall.java
index f7fc125..838c7cf 100644
--- a/telecomm/java/android/telecomm/ParcelableCall.java
+++ b/telecomm/java/android/telecom/ParcelableCall.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.net.Uri;
 import android.os.Bundle;
@@ -27,10 +27,10 @@
 import java.util.Collections;
 import java.util.List;
 
-import com.android.internal.telecomm.IVideoProvider;
+import com.android.internal.telecom.IVideoProvider;
 
 /**
- * Information about a call that is used between InCallService and Telecomm.
+ * Information about a call that is used between InCallService and Telecom.
  * @hide
  */
 public final class ParcelableCall implements Parcelable {
@@ -154,7 +154,7 @@
     }
 
     /**
-     * The presentation requirements for the handle. See {@link TelecommManager} for valid values.
+     * The presentation requirements for the handle. See {@link TelecomManager} for valid values.
      */
     public int getHandlePresentation() {
         return mHandlePresentation;
@@ -167,7 +167,7 @@
 
     /**
      * The presentation requirements for the caller display name.
-     * See {@link TelecommManager} for valid values.
+     * See {@link TelecomManager} for valid values.
      */
     public int getCallerDisplayNamePresentation() {
         return mCallerDisplayNamePresentation;
diff --git a/telecomm/java/android/telecomm/ParcelableConference.aidl b/telecomm/java/android/telecom/ParcelableConference.aidl
similarity index 95%
rename from telecomm/java/android/telecomm/ParcelableConference.aidl
rename to telecomm/java/android/telecom/ParcelableConference.aidl
index a260085..155ba94 100644
--- a/telecomm/java/android/telecomm/ParcelableConference.aidl
+++ b/telecomm/java/android/telecom/ParcelableConference.aidl
@@ -14,6 +14,6 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 parcelable ParcelableConference;
diff --git a/telecomm/java/android/telecomm/ParcelableConference.java b/telecomm/java/android/telecom/ParcelableConference.java
similarity index 98%
rename from telecomm/java/android/telecomm/ParcelableConference.java
rename to telecomm/java/android/telecom/ParcelableConference.java
index b279861..97c709c 100644
--- a/telecomm/java/android/telecomm/ParcelableConference.java
+++ b/telecomm/java/android/telecom/ParcelableConference.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.os.Parcel;
 import android.os.Parcelable;
diff --git a/telecomm/java/android/telecomm/ParcelableConnection.aidl b/telecomm/java/android/telecom/ParcelableConnection.aidl
similarity index 96%
rename from telecomm/java/android/telecomm/ParcelableConnection.aidl
rename to telecomm/java/android/telecom/ParcelableConnection.aidl
index 143c5a6..e91ebc3 100644
--- a/telecomm/java/android/telecomm/ParcelableConnection.aidl
+++ b/telecomm/java/android/telecom/ParcelableConnection.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/ParcelableConnection.java b/telecomm/java/android/telecom/ParcelableConnection.java
similarity index 97%
rename from telecomm/java/android/telecomm/ParcelableConnection.java
rename to telecomm/java/android/telecom/ParcelableConnection.java
index cadcd85..63393b2 100644
--- a/telecomm/java/android/telecomm/ParcelableConnection.java
+++ b/telecomm/java/android/telecom/ParcelableConnection.java
@@ -14,20 +14,20 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.net.Uri;
 import android.os.Parcel;
 import android.os.Parcelable;
 
-import com.android.internal.telecomm.IVideoProvider;
+import com.android.internal.telecom.IVideoProvider;
 
 import java.util.ArrayList;
 import java.util.List;
 
 /**
- * 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
+ * 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
  */
diff --git a/telecomm/java/android/telecomm/Phone.java b/telecomm/java/android/telecom/Phone.java
similarity index 89%
rename from telecomm/java/android/telecomm/Phone.java
rename to telecomm/java/android/telecom/Phone.java
index 8831f8f..5131790 100644
--- a/telecomm/java/android/telecomm/Phone.java
+++ b/telecomm/java/android/telecom/Phone.java
@@ -14,10 +14,9 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.annotation.SystemApi;
-import android.app.PendingIntent;
 import android.util.ArrayMap;
 
 import java.util.Collections;
@@ -77,8 +76,8 @@
         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 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
@@ -101,32 +100,32 @@
     /** {@hide} */
     final void internalAddCall(ParcelableCall parcelableCall) {
         Call call = new Call(this, parcelableCall.getId(), mInCallAdapter);
-        mCallByTelecommCallId.put(parcelableCall.getId(), call);
+        mCallByTelecomCallId.put(parcelableCall.getId(), call);
         mCalls.add(call);
         checkCallTree(parcelableCall);
-        call.internalUpdate(parcelableCall, mCallByTelecommCallId);
+        call.internalUpdate(parcelableCall, mCallByTelecomCallId);
         fireCallAdded(call);
      }
 
     /** {@hide} */
     final void internalRemoveCall(Call call) {
-        mCallByTelecommCallId.remove(call.internalGetCallId());
+        mCallByTelecomCallId.remove(call.internalGetCallId());
         mCalls.remove(call);
         fireCallRemoved(call);
     }
 
     /** {@hide} */
     final void internalUpdateCall(ParcelableCall parcelableCall) {
-         Call call = mCallByTelecommCallId.get(parcelableCall.getId());
+         Call call = mCallByTelecomCallId.get(parcelableCall.getId());
          if (call != null) {
              checkCallTree(parcelableCall);
-             call.internalUpdate(parcelableCall, mCallByTelecommCallId);
+             call.internalUpdate(parcelableCall, mCallByTelecomCallId);
          }
      }
 
     /** {@hide} */
-    final void internalSetPostDialWait(String telecommId, String remaining) {
-        Call call = mCallByTelecommCallId.get(telecommId);
+    final void internalSetPostDialWait(String telecomId, String remaining) {
+        Call call = mCallByTelecomCallId.get(telecomId);
         if (call != null) {
             call.internalSetPostDialWait(remaining);
         }
@@ -141,8 +140,8 @@
     }
 
     /** {@hide} */
-    final Call internalGetCallByTelecommId(String telecommId) {
-        return mCallByTelecommCallId.get(telecommId);
+    final Call internalGetCallByTelecomId(String telecomId) {
+        return mCallByTelecomCallId.get(telecomId);
     }
 
     /** {@hide} */
@@ -269,13 +268,13 @@
 
     private void checkCallTree(ParcelableCall parcelableCall) {
         if (parcelableCall.getParentCallId() != null &&
-                !mCallByTelecommCallId.containsKey(parcelableCall.getParentCallId())) {
+                !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 (!mCallByTelecommCallId.containsKey(parcelableCall.getChildCallIds().get(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/telecomm/PhoneAccount.aidl b/telecomm/java/android/telecom/PhoneAccount.aidl
similarity index 96%
rename from telecomm/java/android/telecomm/PhoneAccount.aidl
rename to telecomm/java/android/telecom/PhoneAccount.aidl
index 15377df..d5e6058 100644
--- a/telecomm/java/android/telecomm/PhoneAccount.aidl
+++ b/telecomm/java/android/telecom/PhoneAccount.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/PhoneAccount.java b/telecomm/java/android/telecom/PhoneAccount.java
similarity index 99%
rename from telecomm/java/android/telecomm/PhoneAccount.java
rename to telecomm/java/android/telecom/PhoneAccount.java
index b37c144..0c233eb 100644
--- a/telecomm/java/android/telecomm/PhoneAccount.java
+++ b/telecomm/java/android/telecom/PhoneAccount.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.content.Context;
 import android.content.pm.PackageManager;
diff --git a/telecomm/java/android/telecomm/PhoneAccountHandle.aidl b/telecomm/java/android/telecom/PhoneAccountHandle.aidl
similarity index 96%
rename from telecomm/java/android/telecomm/PhoneAccountHandle.aidl
rename to telecomm/java/android/telecom/PhoneAccountHandle.aidl
index 3be5a2e..f8f9656 100644
--- a/telecomm/java/android/telecomm/PhoneAccountHandle.aidl
+++ b/telecomm/java/android/telecom/PhoneAccountHandle.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/PhoneAccountHandle.java b/telecomm/java/android/telecom/PhoneAccountHandle.java
similarity index 96%
rename from telecomm/java/android/telecomm/PhoneAccountHandle.java
rename to telecomm/java/android/telecom/PhoneAccountHandle.java
index 04cd2b0..e13df76 100644
--- a/telecomm/java/android/telecomm/PhoneAccountHandle.java
+++ b/telecomm/java/android/telecom/PhoneAccountHandle.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.content.ComponentName;
 import android.os.Parcel;
@@ -37,7 +37,7 @@
     }
 
     /**
-     * The {@code ComponentName} of the {@link android.telecomm.ConnectionService} which is
+     * 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}.
diff --git a/telecomm/java/android/telecomm/PhoneCapabilities.java b/telecomm/java/android/telecom/PhoneCapabilities.java
similarity index 99%
rename from telecomm/java/android/telecomm/PhoneCapabilities.java
rename to telecomm/java/android/telecom/PhoneCapabilities.java
index ec11376..e73dfe2 100644
--- a/telecomm/java/android/telecomm/PhoneCapabilities.java
+++ b/telecomm/java/android/telecom/PhoneCapabilities.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * Defines capabilities a phone call can support, such as conference calling and video telephony.
diff --git a/telecomm/java/android/telecomm/RemoteConference.java b/telecomm/java/android/telecom/RemoteConference.java
similarity index 98%
rename from telecomm/java/android/telecomm/RemoteConference.java
rename to telecomm/java/android/telecom/RemoteConference.java
index dbff079..996e091 100644
--- a/telecomm/java/android/telecomm/RemoteConference.java
+++ b/telecomm/java/android/telecom/RemoteConference.java
@@ -14,9 +14,9 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
-import com.android.internal.telecomm.IConnectionService;
+import com.android.internal.telecom.IConnectionService;
 
 import android.os.RemoteException;
 import android.telephony.DisconnectCause;
diff --git a/telecomm/java/android/telecomm/RemoteConnection.java b/telecomm/java/android/telecom/RemoteConnection.java
similarity index 97%
rename from telecomm/java/android/telecomm/RemoteConnection.java
rename to telecomm/java/android/telecom/RemoteConnection.java
index f3a6085..bf699b3 100644
--- a/telecomm/java/android/telecomm/RemoteConnection.java
+++ b/telecomm/java/android/telecom/RemoteConnection.java
@@ -14,13 +14,12 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
-import com.android.internal.telecomm.IConnectionService;
-import com.android.internal.telecomm.IVideoCallback;
-import com.android.internal.telecomm.IVideoProvider;
+import com.android.internal.telecom.IConnectionService;
+import com.android.internal.telecom.IVideoCallback;
+import com.android.internal.telecom.IVideoProvider;
 
-import android.app.PendingIntent;
 import android.net.Uri;
 import android.os.IBinder;
 import android.os.RemoteException;
@@ -120,7 +119,7 @@
          * @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 TelecommManager} for valid values.
+         *        See {@link TelecomManager} for valid values.
          */
         public void onAddressChanged(RemoteConnection connection, Uri address, int presentation) {}
 
@@ -131,7 +130,7 @@
          * @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 TelecommManager} for valid values.
+         *        See {@link TelecomManager} for valid values.
          */
         public void onCallerDisplayNameChanged(
                 RemoteConnection connection, String callerDisplayName, int presentation) {}
@@ -508,7 +507,7 @@
     }
 
     /**
-     * @return The presentation requirements for the address. See {@link TelecommManager} for valid
+     * @return The presentation requirements for the address. See {@link TelecomManager} for valid
      * values.
      */
     public int getAddressPresentation() {
@@ -524,7 +523,7 @@
 
     /**
      * @return The presentation requirements for the caller display name. See
-     * {@link TelecommManager} for valid values.
+     * {@link TelecomManager} for valid values.
      */
     public int getCallerDisplayNamePresentation() {
         return mCallerDisplayNamePresentation;
@@ -694,15 +693,15 @@
      * 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}.
+     * {@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 TelecommManager#DTMF_CHARACTER_PAUSE} symbol, this
+     * 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 TelecommManager#DTMF_CHARACTER_WAIT} symbol, this
+     * 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
diff --git a/telecomm/java/android/telecomm/RemoteConnectionManager.java b/telecomm/java/android/telecom/RemoteConnectionManager.java
similarity index 97%
rename from telecomm/java/android/telecomm/RemoteConnectionManager.java
rename to telecomm/java/android/telecom/RemoteConnectionManager.java
index 83502c5..0366509 100644
--- a/telecomm/java/android/telecomm/RemoteConnectionManager.java
+++ b/telecomm/java/android/telecom/RemoteConnectionManager.java
@@ -14,12 +14,12 @@
  R* limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.content.ComponentName;
 import android.os.RemoteException;
 
-import com.android.internal.telecomm.IConnectionService;
+import com.android.internal.telecom.IConnectionService;
 
 import java.util.HashMap;
 import java.util.Map;
diff --git a/telecomm/java/android/telecomm/RemoteConnectionService.java b/telecomm/java/android/telecom/RemoteConnectionService.java
similarity index 97%
rename from telecomm/java/android/telecomm/RemoteConnectionService.java
rename to telecomm/java/android/telecom/RemoteConnectionService.java
index d4dd9af..bfd7c51 100644
--- a/telecomm/java/android/telecomm/RemoteConnectionService.java
+++ b/telecomm/java/android/telecom/RemoteConnectionService.java
@@ -14,19 +14,18 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
-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 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;
diff --git a/telecomm/java/android/telecomm/Response.java b/telecomm/java/android/telecom/Response.java
similarity index 97%
rename from telecomm/java/android/telecomm/Response.java
rename to telecomm/java/android/telecom/Response.java
index ad78ebd..ce7a761 100644
--- a/telecomm/java/android/telecomm/Response.java
+++ b/telecomm/java/android/telecom/Response.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * @hide
diff --git a/telecomm/java/android/telecomm/StatusHints.aidl b/telecomm/java/android/telecom/StatusHints.aidl
similarity index 96%
rename from telecomm/java/android/telecomm/StatusHints.aidl
rename to telecomm/java/android/telecom/StatusHints.aidl
index 22da293..ae7df2e 100644
--- a/telecomm/java/android/telecomm/StatusHints.aidl
+++ b/telecomm/java/android/telecom/StatusHints.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/StatusHints.java b/telecomm/java/android/telecom/StatusHints.java
similarity index 99%
rename from telecomm/java/android/telecomm/StatusHints.java
rename to telecomm/java/android/telecom/StatusHints.java
index ff96a5b..a32eae7 100644
--- a/telecomm/java/android/telecomm/StatusHints.java
+++ b/telecomm/java/android/telecom/StatusHints.java
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.content.ComponentName;
 import android.content.Context;
diff --git a/telecomm/java/android/telecomm/TelecommManager.java b/telecomm/java/android/telecom/TelecomManager.java
similarity index 76%
rename from telecomm/java/android/telecomm/TelecommManager.java
rename to telecomm/java/android/telecom/TelecomManager.java
index e2c98cd..c69a17c 100644
--- a/telecomm/java/android/telecomm/TelecommManager.java
+++ b/telecomm/java/android/telecom/TelecomManager.java
@@ -12,7 +12,7 @@
  * the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.annotation.SystemApi;
 import android.content.ComponentName;
@@ -20,59 +20,60 @@
 import android.os.Bundle;
 import android.os.RemoteException;
 import android.os.ServiceManager;
+import android.telephony.TelephonyManager;
 import android.util.Log;
 
-import com.android.internal.telecomm.ITelecommService;
+import com.android.internal.telecom.ITelecomService;
 
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
 
 /**
- * Provides access to Telecomm-related functionality.
+ * Provides access to Telecom-related functionality.
  * TODO: Move this all into PhoneManager.
  */
-public class TelecommManager {
+public class TelecomManager {
 
     /**
      * 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
+     * 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.telecomm.ConnectionService} that Telecomm should bind to. Telecomm will then
+     * {@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.telecomm.action.INCOMING_CALL";
+    public static final String ACTION_INCOMING_CALL = "android.telecom.action.INCOMING_CALL";
 
     /**
      * The {@link android.content.Intent} action used to configure a
-     * {@link android.telecomm.ConnectionService}.
+     * {@link android.telecom.ConnectionService}.
      */
     public static final String ACTION_CONNECTION_SERVICE_CONFIGURE =
-            "android.telecomm.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.telecomm.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.telecomm.action.CHANGE_PHONE_ACCOUNTS";
+            "android.telecom.action.CHANGE_PHONE_ACCOUNTS";
 
     /**
      * The {@link android.content.Intent} action used to inform a
-     * {@link android.telecomm.ConnectionService} that one of its {@link PhoneAccount}s has been
-     * enabled.  The {@link TelecommManager#EXTRA_PHONE_ACCOUNT_HANDLE} extra is used to indicate
+     * {@link android.telecom.ConnectionService} that one of its {@link PhoneAccount}s has been
+     * enabled.  The {@link TelecomManager#EXTRA_PHONE_ACCOUNT_HANDLE} extra is used to indicate
      * which {@link PhoneAccount} has been enabled.
      */
     public static final String ACTION_PHONE_ACCOUNT_ENABLED =
@@ -80,8 +81,8 @@
 
     /**
      * The {@link android.content.Intent} action used to inform a
-     * {@link android.telecomm.ConnectionService} that one of its {@link PhoneAccount}s has been
-     * disabled.  The {@link TelecommManager#EXTRA_PHONE_ACCOUNT_HANDLE} extra is used to indicate
+     * {@link android.telecom.ConnectionService} that one of its {@link PhoneAccount}s has been
+     * disabled.  The {@link TelecomManager#EXTRA_PHONE_ACCOUNT_HANDLE} extra is used to indicate
      * which {@link PhoneAccount} has been disabled.
      */
     public static final String ACTION_PHONE_ACCOUNT_DISABLED =
@@ -92,7 +93,7 @@
      * determines whether the speakerphone should be automatically turned on for an outgoing call.
      */
     public static final String EXTRA_START_CALL_WITH_SPEAKERPHONE =
-            "android.telecomm.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
@@ -105,7 +106,7 @@
      * @hide
      */
     public static final String EXTRA_START_CALL_WITH_VIDEO_STATE =
-            "android.telecomm.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
@@ -115,7 +116,7 @@
      * Retrieve with {@link android.content.Intent#getParcelableExtra(String)}.
      */
     public static final String EXTRA_PHONE_ACCOUNT_HANDLE =
-            "android.telecomm.extra.PHONE_ACCOUNT_HANDLE";
+            "android.telecom.extra.PHONE_ACCOUNT_HANDLE";
 
     /**
      * Optional extra for {@link #ACTION_INCOMING_CALL} containing a {@link Bundle} which contains
@@ -125,7 +126,7 @@
      * @hide
      */
     public static final String EXTRA_INCOMING_CALL_EXTRAS =
-            "android.telecomm.extra.INCOMING_CALL_EXTRAS";
+            "android.telecom.extra.INCOMING_CALL_EXTRAS";
 
     /**
      * Optional extra for {@link android.content.Intent#ACTION_CALL} and
@@ -136,28 +137,28 @@
      * @hide
      */
     public static final String EXTRA_OUTGOING_CALL_EXTRAS =
-            "android.telecomm.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.telecomm.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.telecomm.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.telecomm.extra.CONNECTION_SERVICE";
+            "android.telecom.extra.CONNECTION_SERVICE";
 
     /**
      * An optional {@link android.content.Intent#ACTION_CALL} intent extra denoting the
@@ -170,7 +171,7 @@
      * the user. This alternative address is referred to as the gateway address.
      */
     public static final String GATEWAY_PROVIDER_PACKAGE =
-            "android.telecomm.extra.GATEWAY_PROVIDER_PACKAGE";
+            "android.telecom.extra.GATEWAY_PROVIDER_PACKAGE";
 
     /**
      * An optional {@link android.content.Intent#ACTION_CALL} intent extra corresponding to the
@@ -181,7 +182,7 @@
      * (See {@link #GATEWAY_PROVIDER_PACKAGE} for details)
      */
     public static final String GATEWAY_ORIGINAL_ADDRESS =
-            "android.telecomm.extra.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
@@ -191,7 +192,7 @@
      * 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";
+    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
@@ -246,7 +247,7 @@
      * @hide
      */
     public static final String ACTION_CURRENT_TTY_MODE_CHANGED =
-            "android.telecomm.action.CURRENT_TTY_MODE_CHANGED";
+            "android.telecom.action.CURRENT_TTY_MODE_CHANGED";
 
     /**
      * The lookup key for an int that indicates the current TTY mode.
@@ -259,7 +260,7 @@
      * @hide
      */
     public static final String EXTRA_CURRENT_TTY_MODE =
-            "android.telecomm.intent.extra.CURRENT_TTY_MODE";
+            "android.telecom.intent.extra.CURRENT_TTY_MODE";
 
     /**
      * Broadcast intent action indicating that the TTY preferred operating mode has changed. An
@@ -269,7 +270,7 @@
      * @hide
      */
     public static final String ACTION_TTY_PREFERRED_MODE_CHANGED =
-            "android.telecomm.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: -
@@ -279,7 +280,7 @@
      * @hide
      */
     public static final String EXTRA_TTY_PREFERRED_MODE =
-            "android.telecomm.intent.extra.TTY_PREFERRED";
+            "android.telecom.intent.extra.TTY_PREFERRED";
 
     /**
      * The following 4 constants define how properties such as phone numbers and names are
@@ -298,23 +299,21 @@
     /** Property should be displayed as a pay phone. */
     public static final int PRESENTATION_PAYPHONE = 4;
 
-    private static final String TAG = "TelecommManager";
-
-    private static final String TELECOMM_SERVICE_NAME = "telecomm";
+    private static final String TAG = "TelecomManager";
 
     private final Context mContext;
 
     /**
      * @hide
      */
-    public static TelecommManager from(Context context) {
-        return (TelecommManager) context.getSystemService(Context.TELECOMM_SERVICE);
+    public static TelecomManager from(Context context) {
+        return (TelecomManager) context.getSystemService(Context.TELECOM_SERVICE);
     }
 
     /**
      * @hide
      */
-    public TelecommManager(Context context) {
+    public TelecomManager(Context context) {
         Context appContext = context.getApplicationContext();
         if (appContext != null) {
             mContext = appContext;
@@ -332,11 +331,11 @@
      * 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
+     * {@link TelecomManager#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
+     * {@code Intent} with no {@link TelecomManager#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}.
      *
@@ -345,10 +344,10 @@
     public PhoneAccountHandle getDefaultOutgoingPhoneAccount(String uriScheme) {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getDefaultOutgoingPhoneAccount(uriScheme);
+                return getTelecomService().getDefaultOutgoingPhoneAccount(uriScheme);
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getDefaultOutgoingPhoneAccount", e);
+            Log.e(TAG, "Error calling ITelecomService#getDefaultOutgoingPhoneAccount", e);
         }
         return null;
     }
@@ -367,10 +366,10 @@
     public PhoneAccountHandle getUserSelectedOutgoingPhoneAccount() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getUserSelectedOutgoingPhoneAccount();
+                return getTelecomService().getUserSelectedOutgoingPhoneAccount();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getUserSelectedOutgoingPhoneAccount", e);
+            Log.e(TAG, "Error calling ITelecomService#getUserSelectedOutgoingPhoneAccount", e);
         }
         return null;
     }
@@ -382,10 +381,10 @@
     public void setUserSelectedOutgoingPhoneAccount(PhoneAccountHandle accountHandle) {
         try {
             if (isServiceConnected()) {
-                getTelecommService().setUserSelectedOutgoingPhoneAccount(accountHandle);
+                getTelecomService().setUserSelectedOutgoingPhoneAccount(accountHandle);
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#setUserSelectedOutgoingPhoneAccount");
+            Log.e(TAG, "Error calling ITelecomService#setUserSelectedOutgoingPhoneAccount");
         }
     }
 
@@ -399,10 +398,10 @@
     public List<PhoneAccountHandle> getEnabledPhoneAccounts() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getEnabledPhoneAccounts();
+                return getTelecomService().getEnabledPhoneAccounts();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getEnabledPhoneAccounts", e);
+            Log.e(TAG, "Error calling ITelecomService#getEnabledPhoneAccounts", e);
         }
         return new ArrayList<>();
     }
@@ -417,10 +416,10 @@
     public PhoneAccountHandle getSimCallManager() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getSimCallManager();
+                return getTelecomService().getSimCallManager();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getSimCallManager");
+            Log.e(TAG, "Error calling ITelecomService#getSimCallManager");
         }
         return null;
     }
@@ -433,10 +432,10 @@
     public void setSimCallManager(PhoneAccountHandle accountHandle) {
         try {
             if (isServiceConnected()) {
-                getTelecommService().setSimCallManager(accountHandle);
+                getTelecomService().setSimCallManager(accountHandle);
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#setSimCallManager");
+            Log.e(TAG, "Error calling ITelecomService#setSimCallManager");
         }
     }
 
@@ -448,10 +447,10 @@
     public List<PhoneAccountHandle> getSimCallManagers() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getSimCallManagers();
+                return getTelecomService().getSimCallManagers();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getSimCallManagers");
+            Log.e(TAG, "Error calling ITelecomService#getSimCallManagers");
         }
         return new ArrayList<>();
     }
@@ -482,10 +481,10 @@
     public List<PhoneAccountHandle> getPhoneAccountsSupportingScheme(String uriScheme) {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getPhoneAccountsSupportingScheme(uriScheme);
+                return getTelecomService().getPhoneAccountsSupportingScheme(uriScheme);
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getPhoneAccountsSupportingScheme", e);
+            Log.e(TAG, "Error calling ITelecomService#getPhoneAccountsSupportingScheme", e);
         }
         return new ArrayList<>();
     }
@@ -510,10 +509,10 @@
     public PhoneAccount getPhoneAccount(PhoneAccountHandle account) {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getPhoneAccount(account);
+                return getTelecomService().getPhoneAccount(account);
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getPhoneAccount", e);
+            Log.e(TAG, "Error calling ITelecomService#getPhoneAccount", e);
         }
         return null;
     }
@@ -528,10 +527,10 @@
     public int getAllPhoneAccountsCount() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getAllPhoneAccountsCount();
+                return getTelecomService().getAllPhoneAccountsCount();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getAllPhoneAccountsCount", e);
+            Log.e(TAG, "Error calling ITelecomService#getAllPhoneAccountsCount", e);
         }
         return 0;
     }
@@ -546,10 +545,10 @@
     public List<PhoneAccount> getAllPhoneAccounts() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getAllPhoneAccounts();
+                return getTelecomService().getAllPhoneAccounts();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getAllPhoneAccounts", e);
+            Log.e(TAG, "Error calling ITelecomService#getAllPhoneAccounts", e);
         }
         return Collections.EMPTY_LIST;
     }
@@ -564,10 +563,10 @@
     public List<PhoneAccountHandle> getAllPhoneAccountHandles() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getAllPhoneAccountHandles();
+                return getTelecomService().getAllPhoneAccountHandles();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#getAllPhoneAccountHandles", e);
+            Log.e(TAG, "Error calling ITelecomService#getAllPhoneAccountHandles", e);
         }
         return Collections.EMPTY_LIST;
     }
@@ -583,10 +582,10 @@
     public void setPhoneAccountEnabled(PhoneAccountHandle account, boolean isEnabled) {
         try {
             if (isServiceConnected()) {
-                getTelecommService().setPhoneAccountEnabled(account, isEnabled);
+                getTelecomService().setPhoneAccountEnabled(account, isEnabled);
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#setPhoneAccountEnabled", e);
+            Log.e(TAG, "Error calling ITelecomService#setPhoneAccountEnabled", e);
         }
     }
 
@@ -598,10 +597,10 @@
     public void registerPhoneAccount(PhoneAccount account) {
         try {
             if (isServiceConnected()) {
-                getTelecommService().registerPhoneAccount(account);
+                getTelecomService().registerPhoneAccount(account);
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#registerPhoneAccount", e);
+            Log.e(TAG, "Error calling ITelecomService#registerPhoneAccount", e);
         }
     }
 
@@ -613,10 +612,10 @@
     public void unregisterPhoneAccount(PhoneAccountHandle accountHandle) {
         try {
             if (isServiceConnected()) {
-                getTelecommService().unregisterPhoneAccount(accountHandle);
+                getTelecomService().unregisterPhoneAccount(accountHandle);
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#unregisterPhoneAccount", e);
+            Log.e(TAG, "Error calling ITelecomService#unregisterPhoneAccount", e);
         }
     }
 
@@ -627,10 +626,10 @@
     public void clearAccounts() {
         try {
             if (isServiceConnected()) {
-                getTelecommService().clearAccounts(mContext.getPackageName());
+                getTelecomService().clearAccounts(mContext.getPackageName());
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#clearAccounts", e);
+            Log.e(TAG, "Error calling ITelecomService#clearAccounts", e);
         }
     }
 
@@ -641,7 +640,7 @@
     public ComponentName getDefaultPhoneApp() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().getDefaultPhoneApp();
+                return getTelecomService().getDefaultPhoneApp();
             }
         } catch (RemoteException e) {
             Log.e(TAG, "RemoteException attempting to get the default phone app.", e);
@@ -660,15 +659,39 @@
     public boolean isInCall() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().isInCall();
+                return getTelecomService().isInCall();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "RemoteException attempting to get default phone app.", 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}
+     *
+     * <p>
+     * Requires permission: {@link android.Manifest.permission#READ_PHONE_STATE}
+     * </p>
+     * @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
@@ -677,7 +700,7 @@
     public boolean isRinging() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().isRinging();
+                return getTelecomService().isRinging();
             }
         } catch (RemoteException e) {
             Log.e(TAG, "RemoteException attempting to get ringing state of phone app.", e);
@@ -687,7 +710,7 @@
 
     /**
      * Ends an ongoing call.
-     * TODO: L-release - need to convert all invocations of ITelecommService#endCall to use this
+     * TODO: L-release - need to convert all invocations of ITelecomService#endCall to use this
      * method (clockwork & gearhead).
      * @hide
      */
@@ -695,17 +718,17 @@
     public boolean endCall() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().endCall();
+                return getTelecomService().endCall();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#endCall", 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 ITelecommService#answerRingingCall to use
+     * TODO: L-release - need to convert all invocation of ITelecmmService#answerRingingCall to use
      * this method (clockwork & gearhead).
      *
      * @hide
@@ -714,10 +737,10 @@
     public void acceptRingingCall() {
         try {
             if (isServiceConnected()) {
-                getTelecommService().acceptRingingCall();
+                getTelecomService().acceptRingingCall();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#acceptRingingCall", e);
+            Log.e(TAG, "Error calling ITelecomService#acceptRingingCall", e);
         }
     }
 
@@ -730,10 +753,10 @@
     public void silenceRinger() {
         try {
             if (isServiceConnected()) {
-                getTelecommService().silenceRinger();
+                getTelecomService().silenceRinger();
             }
         } catch (RemoteException e) {
-            Log.e(TAG, "Error calling ITelecommService#silenceRinger", e);
+            Log.e(TAG, "Error calling ITelecomService#silenceRinger", e);
         }
     }
 
@@ -746,7 +769,7 @@
     public boolean isTtySupported() {
         try {
             if (isServiceConnected()) {
-                return getTelecommService().isTtySupported();
+                return getTelecomService().isTtySupported();
             }
         } catch (RemoteException e) {
             Log.e(TAG, "RemoteException attempting to get TTY supported state.", e);
@@ -758,16 +781,16 @@
      * 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}
+     * - {@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 getTelecommService().getCurrentTtyMode();
+                return getTelecomService().getCurrentTtyMode();
             }
         } catch (RemoteException e) {
             Log.e(TAG, "RemoteException attempting to get the current TTY mode.", e);
@@ -792,7 +815,7 @@
     public void addNewIncomingCall(PhoneAccountHandle phoneAccount, Bundle extras) {
         try {
             if (isServiceConnected()) {
-                getTelecommService().addNewIncomingCall(
+                getTelecomService().addNewIncomingCall(
                         phoneAccount, extras == null ? new Bundle() : extras);
             }
         } catch (RemoteException e) {
@@ -812,12 +835,12 @@
      * @return True if the digits were processed as an MMI code, false otherwise.
      */
     public boolean handleMmi(String dialString) {
-        ITelecommService service = getTelecommService();
+        ITelecomService service = getTelecomService();
         if (service != null) {
             try {
                 return service.handlePinMmi(dialString);
             } catch (RemoteException e) {
-                Log.e(TAG, "Error calling ITelecommService#handlePinMmi", e);
+                Log.e(TAG, "Error calling ITelecomService#handlePinMmi", e);
             }
         }
         return false;
@@ -830,12 +853,12 @@
      * </p>
      */
     public void cancelMissedCallsNotification() {
-        ITelecommService service = getTelecommService();
+        ITelecomService service = getTelecomService();
         if (service != null) {
             try {
                 service.cancelMissedCallsNotification();
             } catch (RemoteException e) {
-                Log.e(TAG, "Error calling ITelecommService#cancelMissedCallsNotification", e);
+                Log.e(TAG, "Error calling ITelecomService#cancelMissedCallsNotification", e);
             }
         }
     }
@@ -851,24 +874,24 @@
      * @param showDialpad Brings up the in-call dialpad as part of showing the in-call screen.
      */
     public void showInCallScreen(boolean showDialpad) {
-        ITelecommService service = getTelecommService();
+        ITelecomService service = getTelecomService();
         if (service != null) {
             try {
                 service.showInCallScreen(showDialpad);
             } catch (RemoteException e) {
-                Log.e(TAG, "Error calling ITelecommService#showCallScreen", e);
+                Log.e(TAG, "Error calling ITelecomService#showCallScreen", e);
             }
         }
     }
 
-    private ITelecommService getTelecommService() {
-        return ITelecommService.Stub.asInterface(ServiceManager.getService(TELECOMM_SERVICE_NAME));
+    private ITelecomService getTelecomService() {
+        return ITelecomService.Stub.asInterface(ServiceManager.getService(Context.TELECOM_SERVICE));
     }
 
     private boolean isServiceConnected() {
-        boolean isConnected = getTelecommService() != null;
+        boolean isConnected = getTelecomService() != null;
         if (!isConnected) {
-            Log.w(TAG, "Telecomm Service not found.");
+            Log.w(TAG, "Telecom Service not found.");
         }
         return isConnected;
     }
diff --git a/telecomm/java/android/telecomm/VideoCallImpl.java b/telecomm/java/android/telecom/VideoCallImpl.java
similarity index 97%
rename from telecomm/java/android/telecomm/VideoCallImpl.java
rename to telecomm/java/android/telecom/VideoCallImpl.java
index d33a351..925058e 100644
--- a/telecomm/java/android/telecomm/VideoCallImpl.java
+++ b/telecomm/java/android/telecom/VideoCallImpl.java
@@ -14,19 +14,19 @@
  * limitations under the License
  */
 
-package android.telecomm;
+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.telecomm.InCallService.VideoCall;
+import android.telecom.InCallService.VideoCall;
 import android.view.Surface;
 
 import com.android.internal.os.SomeArgs;
-import com.android.internal.telecomm.IVideoCallback;
-import com.android.internal.telecomm.IVideoProvider;
+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
diff --git a/telecomm/java/android/telecomm/VideoCallbackServant.java b/telecomm/java/android/telecom/VideoCallbackServant.java
similarity index 98%
rename from telecomm/java/android/telecomm/VideoCallbackServant.java
rename to telecomm/java/android/telecom/VideoCallbackServant.java
index 060b8a9..d0e3f22 100644
--- a/telecomm/java/android/telecomm/VideoCallbackServant.java
+++ b/telecomm/java/android/telecom/VideoCallbackServant.java
@@ -14,10 +14,10 @@
  R* limitations under the License.
  */
 
-package android.telecomm;
+package android.telecom;
 
 import com.android.internal.os.SomeArgs;
-import com.android.internal.telecomm.IVideoCallback;
+import com.android.internal.telecom.IVideoCallback;
 
 import android.os.Handler;
 import android.os.Message;
diff --git a/telecomm/java/android/telecomm/VideoProfile.aidl b/telecomm/java/android/telecom/VideoProfile.aidl
similarity index 96%
rename from telecomm/java/android/telecomm/VideoProfile.aidl
rename to telecomm/java/android/telecom/VideoProfile.aidl
index e756fa7..091b569 100644
--- a/telecomm/java/android/telecomm/VideoProfile.aidl
+++ b/telecomm/java/android/telecom/VideoProfile.aidl
@@ -15,7 +15,7 @@
  */
 
 
-package android.telecomm;
+package android.telecom;
 
 /**
  * {@hide}
diff --git a/telecomm/java/android/telecomm/VideoProfile.java b/telecomm/java/android/telecom/VideoProfile.java
similarity index 99%
rename from telecomm/java/android/telecomm/VideoProfile.java
rename to telecomm/java/android/telecom/VideoProfile.java
index 028d24e..f5cb054 100644
--- a/telecomm/java/android/telecomm/VideoProfile.java
+++ b/telecomm/java/android/telecom/VideoProfile.java
@@ -14,7 +14,7 @@
  * limitations under the License
  */
 
-package android.telecomm;
+package android.telecom;
 
 import android.os.Parcel;
 import android.os.Parcelable;
diff --git a/telecomm/java/com/android/internal/telecomm/IConnectionService.aidl b/telecomm/java/com/android/internal/telecom/IConnectionService.aidl
similarity index 86%
rename from telecomm/java/com/android/internal/telecomm/IConnectionService.aidl
rename to telecomm/java/com/android/internal/telecom/IConnectionService.aidl
index 3af4ed3..1059da37 100644
--- a/telecomm/java/com/android/internal/telecomm/IConnectionService.aidl
+++ b/telecomm/java/com/android/internal/telecom/IConnectionService.aidl
@@ -14,19 +14,19 @@
  * limitations under the License.
  */
 
-package com.android.internal.telecomm;
+package com.android.internal.telecom;
 
 import android.os.Bundle;
-import android.telecomm.AudioState;
-import android.telecomm.ConnectionRequest;
-import android.telecomm.PhoneAccountHandle;
+import android.telecom.AudioState;
+import android.telecom.ConnectionRequest;
+import android.telecom.PhoneAccountHandle;
 
-import com.android.internal.telecomm.IConnectionServiceAdapter;
+import com.android.internal.telecom.IConnectionServiceAdapter;
 
 /**
  * Internal remote interface for connection services.
  *
- * @see android.telecomm.ConnectionService
+ * @see android.telecom.ConnectionService
  *
  * @hide
  */
diff --git a/telecomm/java/com/android/internal/telecomm/IConnectionServiceAdapter.aidl b/telecomm/java/com/android/internal/telecom/IConnectionServiceAdapter.aidl
similarity index 85%
rename from telecomm/java/com/android/internal/telecomm/IConnectionServiceAdapter.aidl
rename to telecomm/java/com/android/internal/telecom/IConnectionServiceAdapter.aidl
index 4b636d1..8f3506d 100644
--- a/telecomm/java/com/android/internal/telecomm/IConnectionServiceAdapter.aidl
+++ b/telecomm/java/com/android/internal/telecom/IConnectionServiceAdapter.aidl
@@ -14,22 +14,22 @@
  * limitations under the License.
  */
 
-package com.android.internal.telecomm;
+package com.android.internal.telecom;
 
 import android.app.PendingIntent;
 import android.net.Uri;
-import android.telecomm.ConnectionRequest;
-import android.telecomm.ParcelableConnection;
-import android.telecomm.ParcelableConference;
-import android.telecomm.StatusHints;
+import android.telecom.ConnectionRequest;
+import android.telecom.ParcelableConnection;
+import android.telecom.ParcelableConference;
+import android.telecom.StatusHints;
 
-import com.android.internal.telecomm.IVideoProvider;
-import com.android.internal.telecomm.RemoteServiceCallback;
+import com.android.internal.telecom.IVideoProvider;
+import com.android.internal.telecom.RemoteServiceCallback;
 
 /**
  * Internal remote callback interface for connection services.
  *
- * @see android.telecomm.ConnectionServiceAdapter
+ * @see android.telecom.ConnectionServiceAdapter
  *
  * {@hide}
  */
diff --git a/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl b/telecomm/java/com/android/internal/telecom/IInCallAdapter.aidl
similarity index 92%
rename from telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl
rename to telecomm/java/com/android/internal/telecom/IInCallAdapter.aidl
index 808a410..138a877 100644
--- a/telecomm/java/com/android/internal/telecomm/IInCallAdapter.aidl
+++ b/telecomm/java/com/android/internal/telecom/IInCallAdapter.aidl
@@ -14,14 +14,14 @@
  * limitations under the License.
  */
 
-package com.android.internal.telecomm;
+package com.android.internal.telecom;
 
-import android.telecomm.PhoneAccountHandle;
+import android.telecom.PhoneAccountHandle;
 
 /**
  * Internal remote callback interface for in-call services.
  *
- * @see android.telecomm.InCallAdapter
+ * @see android.telecom.InCallAdapter
  *
  * {@hide}
  */
diff --git a/telecomm/java/com/android/internal/telecomm/IInCallService.aidl b/telecomm/java/com/android/internal/telecom/IInCallService.aidl
similarity index 84%
rename from telecomm/java/com/android/internal/telecomm/IInCallService.aidl
rename to telecomm/java/com/android/internal/telecom/IInCallService.aidl
index 23dbaf4..35f6f65 100644
--- a/telecomm/java/com/android/internal/telecomm/IInCallService.aidl
+++ b/telecomm/java/com/android/internal/telecom/IInCallService.aidl
@@ -14,18 +14,18 @@
  * limitations under the License.
  */
 
-package com.android.internal.telecomm;
+package com.android.internal.telecom;
 
 import android.app.PendingIntent;
-import android.telecomm.AudioState;
-import android.telecomm.ParcelableCall;
+import android.telecom.AudioState;
+import android.telecom.ParcelableCall;
 
-import com.android.internal.telecomm.IInCallAdapter;
+import com.android.internal.telecom.IInCallAdapter;
 
 /**
  * Internal remote interface for in-call services.
  *
- * @see android.telecomm.InCallService
+ * @see android.telecom.InCallService
  *
  * {@hide}
  */
diff --git a/telecomm/java/com/android/internal/telecomm/ITelecommService.aidl b/telecomm/java/com/android/internal/telecom/ITelecomService.aidl
similarity index 62%
rename from telecomm/java/com/android/internal/telecomm/ITelecommService.aidl
rename to telecomm/java/com/android/internal/telecom/ITelecomService.aidl
index 30f2801..4875cc3 100644
--- a/telecomm/java/com/android/internal/telecomm/ITelecommService.aidl
+++ b/telecomm/java/com/android/internal/telecom/ITelecomService.aidl
@@ -14,19 +14,19 @@
  * limitations under the License.
  */
 
-package com.android.internal.telecomm;
+package com.android.internal.telecom;
 
 import android.content.ComponentName;
-import android.telecomm.PhoneAccountHandle;
+import android.telecom.PhoneAccountHandle;
 import android.os.Bundle;
-import android.telecomm.PhoneAccount;
+import android.telecom.PhoneAccount;
 
 /**
- * Interface used to interact with Telecomm. Mostly this is used by TelephonyManager for passing
+ * Interface used to interact with Telecom. Mostly this is used by TelephonyManager for passing
  * commands that were previously handled by ITelephony.
  * {@hide}
  */
-interface ITelecommService {
+interface ITelecomService {
     /**
      * Brings the in-call screen to the foreground if there is an active call.
      *
@@ -35,87 +35,87 @@
     void showInCallScreen(boolean showDialpad);
 
     /**
-     * @see TelecommServiceImpl#getDefaultOutgoingPhoneAccount
+     * @see TelecomServiceImpl#getDefaultOutgoingPhoneAccount
      */
     PhoneAccountHandle getDefaultOutgoingPhoneAccount(in String uriScheme);
 
     /**
-     * @see TelecommServiceImpl#getUserSelectedOutgoingPhoneAccount
+     * @see TelecomServiceImpl#getUserSelectedOutgoingPhoneAccount
      */
     PhoneAccountHandle getUserSelectedOutgoingPhoneAccount();
 
     /**
-     * @see TelecommServiceImpl#setUserSelectedOutgoingPhoneAccount
+     * @see TelecomServiceImpl#setUserSelectedOutgoingPhoneAccount
      */
     void setUserSelectedOutgoingPhoneAccount(in PhoneAccountHandle account);
 
     /**
-     * @see TelecommServiceImpl#getEnabledPhoneAccounts
+     * @see TelecomServiceImpl#getEnabledPhoneAccounts
      */
     List<PhoneAccountHandle> getEnabledPhoneAccounts();
 
     /**
-     * @see TelecommManager#getPhoneAccountsSupportingScheme
+     * @see TelecomManager#getPhoneAccountsSupportingScheme
      */
     List<PhoneAccountHandle> getPhoneAccountsSupportingScheme(in String uriScheme);
 
     /**
-     * @see TelecommManager#getPhoneAccount
+     * @see TelecomManager#getPhoneAccount
      */
     PhoneAccount getPhoneAccount(in PhoneAccountHandle account);
 
     /**
-     * @see TelecommManager#getAllPhoneAccountsCount
+     * @see TelecomManager#getAllPhoneAccountsCount
      */
     int getAllPhoneAccountsCount();
 
     /**
-     * @see TelecommManager#getAllPhoneAccounts
+     * @see TelecomManager#getAllPhoneAccounts
      */
     List<PhoneAccount> getAllPhoneAccounts();
 
     /**
-     * @see TelecommManager#getAllPhoneAccountHandles
+     * @see TelecomManager#getAllPhoneAccountHandles
      */
     List<PhoneAccountHandle> getAllPhoneAccountHandles();
 
     /**
-     * @see TelecommServiceImpl#getSimCallManager
+     * @see TelecomServiceImpl#getSimCallManager
      */
     PhoneAccountHandle getSimCallManager();
 
     /**
-     * @see TelecommServiceImpl#setSimCallManager
+     * @see TelecomServiceImpl#setSimCallManager
      */
     void setSimCallManager(in PhoneAccountHandle account);
 
     /**
-     * @see TelecommServiceImpl#getSimCallManagers
+     * @see TelecomServiceImpl#getSimCallManagers
      */
     List<PhoneAccountHandle> getSimCallManagers();
 
     /**
-     * @see TelecommServiceImpl#setPhoneAccountEnabled
+     * @see TelecomServiceImpl#setPhoneAccountEnabled
      */
     void setPhoneAccountEnabled(in PhoneAccountHandle account, in boolean isEnabled);
 
     /**
-     * @see TelecommServiceImpl#registerPhoneAccount
+     * @see TelecomServiceImpl#registerPhoneAccount
      */
     void registerPhoneAccount(in PhoneAccount metadata);
 
     /**
-     * @see TelecommServiceImpl#unregisterPhoneAccount
+     * @see TelecomServiceImpl#unregisterPhoneAccount
      */
     void unregisterPhoneAccount(in PhoneAccountHandle account);
 
     /**
-     * @see TelecommServiceImpl#clearAccounts
+     * @see TelecomServiceImpl#clearAccounts
      */
     void clearAccounts(String packageName);
 
     /**
-     * @see TelecommServiceImpl#getDefaultPhoneApp
+     * @see TelecomServiceImpl#getDefaultPhoneApp
      */
     ComponentName getDefaultPhoneApp();
 
@@ -124,52 +124,57 @@
     //
 
     /**
-     * @see TelecommServiceImpl#silenceRinger
+     * @see TelecomServiceImpl#silenceRinger
      */
     void silenceRinger();
 
     /**
-     * @see TelecommServiceImpl#isInCall
+     * @see TelecomServiceImpl#isInCall
      */
     boolean isInCall();
 
     /**
-     * @see TelecommServiceImpl#isRinging
+     * @see TelecomServiceImpl#isRinging
      */
     boolean isRinging();
 
     /**
-     * @see TelecommServiceImpl#endCall
+     * @see TelecomServiceImpl#getCallState
+     */
+    int getCallState();
+
+    /**
+     * @see TelecomServiceImpl#endCall
      */
     boolean endCall();
 
     /**
-     * @see TelecommServiceImpl#acceptRingingCall
+     * @see TelecomServiceImpl#acceptRingingCall
      */
     void acceptRingingCall();
 
     /**
-     * @see TelecommServiceImpl#cancelMissedCallsNotification
+     * @see TelecomServiceImpl#cancelMissedCallsNotification
      */
     void cancelMissedCallsNotification();
 
     /**
-     * @see TelecommServiceImpl#handleMmi
+     * @see TelecomServiceImpl#handleMmi
      */
     boolean handlePinMmi(String dialString);
 
     /**
-     * @see TelecommServiceImpl#isTtySupported
+     * @see TelecomServiceImpl#isTtySupported
      */
     boolean isTtySupported();
 
     /**
-     * @see TelecommServiceImpl#getCurrentTtyMode
+     * @see TelecomServiceImpl#getCurrentTtyMode
      */
     int getCurrentTtyMode();
 
     /**
-     * @see TelecommServiceImpl#addNewIncomingCall
+     * @see TelecomServiceImpl#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/telecom/IVideoCallback.aidl
similarity index 87%
rename from telecomm/java/com/android/internal/telecomm/IVideoCallback.aidl
rename to telecomm/java/com/android/internal/telecom/IVideoCallback.aidl
index 186f083..f758b60 100644
--- a/telecomm/java/com/android/internal/telecomm/IVideoCallback.aidl
+++ b/telecomm/java/com/android/internal/telecom/IVideoCallback.aidl
@@ -14,16 +14,16 @@
  * limitations under the License.
  */
 
-package com.android.internal.telecomm;
+package com.android.internal.telecom;
 
-import android.telecomm.CameraCapabilities;
-import android.telecomm.VideoProfile;
+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.telecomm.InCallService.VideoCall.Listener
+  * @see android.telecom.InCallService.VideoCall.Listener
   *
   * {@hide}
   */
diff --git a/telecomm/java/com/android/internal/telecomm/IVideoProvider.aidl b/telecomm/java/com/android/internal/telecom/IVideoProvider.aidl
similarity index 91%
rename from telecomm/java/com/android/internal/telecomm/IVideoProvider.aidl
rename to telecomm/java/com/android/internal/telecom/IVideoProvider.aidl
index b0aa988..e96d9d3 100644
--- a/telecomm/java/com/android/internal/telecomm/IVideoProvider.aidl
+++ b/telecomm/java/com/android/internal/telecom/IVideoProvider.aidl
@@ -14,14 +14,14 @@
  * limitations under the License.
  */
 
-package com.android.internal.telecomm;
+package com.android.internal.telecom;
 
 import android.view.Surface;
-import android.telecomm.VideoProfile;
+import android.telecom.VideoProfile;
 
 /**
  * Internal remote interface for a video call provider.
- * @see android.telecomm.VideoProvider
+ * @see android.telecom.VideoProvider
  * @hide
  */
 oneway interface IVideoProvider {
diff --git a/telecomm/java/com/android/internal/telecomm/RemoteServiceCallback.aidl b/telecomm/java/com/android/internal/telecom/RemoteServiceCallback.aidl
similarity index 95%
rename from telecomm/java/com/android/internal/telecomm/RemoteServiceCallback.aidl
rename to telecomm/java/com/android/internal/telecom/RemoteServiceCallback.aidl
index 0ab7564..441704d 100644
--- a/telecomm/java/com/android/internal/telecomm/RemoteServiceCallback.aidl
+++ b/telecomm/java/com/android/internal/telecom/RemoteServiceCallback.aidl
@@ -14,7 +14,7 @@
  * limitations under the License.
  */
 
-package com.android.internal.telecomm;
+package com.android.internal.telecom;
 
 import android.content.ComponentName;
 
diff --git a/telephony/java/android/telephony/DisconnectCause.java b/telephony/java/android/telephony/DisconnectCause.java
index aa6c47c..6366c91 100644
--- a/telephony/java/android/telephony/DisconnectCause.java
+++ b/telephony/java/android/telephony/DisconnectCause.java
@@ -155,7 +155,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;
 
diff --git a/telephony/java/android/telephony/TelephonyManager.java b/telephony/java/android/telephony/TelephonyManager.java
index 9f94040..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;
 
     /**
@@ -2048,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;
+        }
     }
 
     /**
@@ -2145,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));
     }
 
     //
@@ -3135,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);
         }
     }
 
diff --git a/telephony/java/com/android/ims/ImsCallProfile.java b/telephony/java/com/android/ims/ImsCallProfile.java
index 767ecf9..8b7901c 100644
--- a/telephony/java/com/android/ims/ImsCallProfile.java
+++ b/telephony/java/com/android/ims/ImsCallProfile.java
@@ -19,7 +19,7 @@
 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;
 
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/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/wifi/java/android/net/wifi/WifiConfiguration.java b/wifi/java/android/net/wifi/WifiConfiguration.java
index 9ece434..d27c2f7 100644
--- a/wifi/java/android/net/wifi/WifiConfiguration.java
+++ b/wifi/java/android/net/wifi/WifiConfiguration.java
@@ -382,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;