Merge "Making some constants accessible" into ub-launcher3-dorval-polish
diff --git a/res/color-v24/all_apps_bg_hand_fill.xml b/res/color-v24/all_apps_bg_hand_fill.xml
new file mode 100644
index 0000000..1b0b538
--- /dev/null
+++ b/res/color-v24/all_apps_bg_hand_fill.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2017 The Android Open Source Project
+
+     Licensed under the Apache License, Version 2.0 (the "License");
+     you may not use this file except in compliance with the License.
+     You may obtain a copy of the License at
+
+          http://www.apache.org/licenses/LICENSE-2.0
+
+     Unless required by applicable law or agreed to in writing, software
+     distributed under the License is distributed on an "AS IS" BASIS,
+     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+     See the License for the specific language governing permissions and
+     limitations under the License.
+-->
+<gradient
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    android:startX="158.5"
+    android:startY="141.5"
+    android:endX="196.0"
+    android:endY="206.5"
+    android:type="linear" >
+    <item android:offset="0" android:color="#E1E1E1" />
+    <item android:offset="0.3317" android:color="#E1E1E1" />
+    <item android:offset="0.493" android:color="#C1E5E5E5" />
+    <item android:offset="1" android:color="#00EEEEEE" />
+</gradient>
\ No newline at end of file
diff --git a/res/drawable-hdpi/ic_all_apps_bg_hand.png b/res/drawable-hdpi/ic_all_apps_bg_hand.png
deleted file mode 100644
index 437fd37..0000000
--- a/res/drawable-hdpi/ic_all_apps_bg_hand.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-mdpi/ic_all_apps_bg_hand.png b/res/drawable-mdpi/ic_all_apps_bg_hand.png
deleted file mode 100644
index 0a00241..0000000
--- a/res/drawable-mdpi/ic_all_apps_bg_hand.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-xhdpi/ic_all_apps_bg_hand.png b/res/drawable-xhdpi/ic_all_apps_bg_hand.png
deleted file mode 100644
index 1acb378..0000000
--- a/res/drawable-xhdpi/ic_all_apps_bg_hand.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-xxhdpi/ic_all_apps_bg_hand.png b/res/drawable-xxhdpi/ic_all_apps_bg_hand.png
deleted file mode 100644
index 09c6c8d..0000000
--- a/res/drawable-xxhdpi/ic_all_apps_bg_hand.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable-xxxhdpi/ic_all_apps_bg_hand.png b/res/drawable-xxxhdpi/ic_all_apps_bg_hand.png
deleted file mode 100644
index 49c004d..0000000
--- a/res/drawable-xxxhdpi/ic_all_apps_bg_hand.png
+++ /dev/null
Binary files differ
diff --git a/res/drawable/ic_all_apps_bg_hand.xml b/res/drawable/ic_all_apps_bg_hand.xml
new file mode 100644
index 0000000..94af008
--- /dev/null
+++ b/res/drawable/ic_all_apps_bg_hand.xml
@@ -0,0 +1,100 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2017 The Android Open Source Project
+
+     Licensed under the Apache License, Version 2.0 (the "License");
+     you may not use this file except in compliance with the License.
+     You may obtain a copy of the License at
+
+          http://www.apache.org/licenses/LICENSE-2.0
+
+     Unless required by applicable law or agreed to in writing, software
+     distributed under the License is distributed on an "AS IS" BASIS,
+     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+     See the License for the specific language governing permissions and
+     limitations under the License.
+-->
+
+<vector
+    xmlns:android="http://schemas.android.com/apk/res/android"
+    android:width="208dp"
+    android:height="212dp"
+    android:viewportWidth="208.0"
+    android:viewportHeight="212.0">
+    <path
+        android:fillColor="#1A000000"
+        android:pathData="M89.4,61.8H85l-1.6-1.5c5.5-6.4,8.8-14.7,8.8-23.7C92.2,16.6,76,0.3,55.9,0.3
+        S19.5,16.6,19.5,36.6S35.8,73,55.9,73c9,0,17.3-3.3,23.7-8.8l1.5,1.6v4.4l40.5,40.4l8.3-8.3L89.4,61.8z M54,66.6
+        c-13.9,0-28.8-16-28.8-30S41.5,8.9,55.4,8.9S81,22.7,81,36.6S67.9,66.6,54,66.6z"/>
+    <path
+        android:fillColor="#1A000000"
+        android:pathData="M33.4,29.2l-0.3-1.8l-4.2-3.1L18.1,26l-3.1,4.2l0.3,1.8L4.5,33.7L9,62.5
+        c0.2,1.5,1.6,2.5,3.1,2.3l34.2-5.3c1.5-0.2,2.5-1.6,2.3-3.1l-4.4-28.8L33.4,29.2z"/>
+    <path
+        android:fillColor="#3367D6"
+        android:pathData="M30.2,27.9l-0.3-1.8l-4.1-3L15,24.7l-3,4.1l0.3,1.8L1.6,32.3L6,60.9
+        c0.2,1.5,1.6,2.5,3.1,2.3L43,57.9c1.5-0.2,2.5-1.6,2.3-3.1l-4.4-28.6L30.2,27.9z M26.6,28.4l-10.7,1.6l-0.3-1.8l10.7-1.6L26.6,28.4z"/>
+    <group>
+        <clip-path
+            android:pathData="M25.1,37.7a28.9,28.9 0 1,0 57.8,0a28.9,28.9 0 1,0 -57.8,0"/>
+        <path
+            android:fillColor="#4285F4"
+            android:pathData="M41.7,23l-0.3-2.1l-4.9-3.6l-12.6,1.9l-3.6,4.9l0.3,2.1L8.1,28.1l5.2,33.7
+                c0.3,1.7,1.9,2.9,3.6,2.7l40-6.1c1.7-0.3,2.9-1.9,2.7-3.6L54.4,21L41.7,23z M37.5,23.6l-12.6,1.9l-0.3-2.1l12.6-1.9L37.5,23.6z"/>
+    </group>
+    <path
+        android:fillColor="#BDBDBD"
+        android:pathData="M87.5,62.9h-4.4l-1.6-1.5c5.5-6.4,8.8-14.7,8.8-23.7C90.3,17.7,74,1.4,54,1.4
+        S17.6,17.7,17.6,37.7S33.9,74.1,54,74.1c9,0,17.3-3.3,23.7-8.8l1.5,1.6v4.4l40.5,40.4l8.3-8.3L87.5,62.9z M54,64.2
+        c-14.7,0-26.5-11.8-26.5-26.5S39.3,11.2,54,11.2s26.5,11.8,26.5,26.5S68.6,64.2,54,64.2z"/>
+    <path
+        android:fillColor="#1A000000"
+        android:pathData="M153.4,112.9c-14.9-17.2-38.6-9.1-38.6-9.1l-10.2-11.3c0,0-4.8-5.9-9-3.7
+        c-7,3.6-0.6,10.7-0.6,10.7s12.3,15.1,15.4,20.1c2.1,3.4,8.4,4.5,10.1,4.9l17.1,3.7l-0.9-0.7l-1-0.7L153.4,112.9z"/>
+    <path
+        android:fillColor="#FFDBA6"
+        android:pathData="M152.1,113.9c-14.9-17.2-37.6-8-37.6-8l-11.1-12.3c0,0-4.8-5.9-9-3.7
+        c-7,3.6-0.6,10.7-0.6,10.7s12.3,15.1,15.4,20.1c2.1,3.4,8.4,4.5,10.1,4.9l19,4.1"/>
+    <path
+        android:fillColor="#1A000000"
+        android:pathData="M148.6,77.9c0.6,0.7,2,2.5,2.1,2.6c1.1,1.7,6.2,13.6,11.8,35.1c0,0.1,1.9,3,1.9,3.1
+        c0,0,0.1,0.1,0.1,0.2c0,0,0,0,0-0.1c0.9,1.3,4.4,6.6,8.9,13.7c0.1,0.2,0.3,0.5,0.4,0.7c0,0.1,0.1,0.1,0.1,0.2
+        c0.2,0.3,0.4,0.6,0.6,0.9c0.1-0.1,0.2-0.2,0.3-0.3c0.2-0.3,0.6-0.3,0.8,0c2.9,4.8,21.2,35,26.7,49c2.1,5.3,3.2,8.4,3.6,11.6
+        c0.3,2.3,0,4.4-1.2,6c1.5-1.9,3.5-6.8-1.5-19c-1.2-2.9-2.8-6.5-4.8-10.5c-7.5-15.2-20-35.6-22.4-39.6c-0.2-0.3-0.6-0.3-0.8,0
+        c-0.2,0.2-0.3,0.4-0.5,0.6c-4.5-7.1-8.2-12.6-8.8-13.5c-0.1-0.1-1.9-3-1.9-3.1c-5.7-21.6-10.7-33.4-11.8-35.1
+        c-0.1-0.1-1.5-1.9-2.1-2.6l-6.5-8.3c-1.9-2.3-4.2-4.1-6.7-2.3c-2.5,1.8-1.6,4.5-0.1,7.1l3.3,5.2l7-2
+        C147.7,77.4,148.1,77.3,148.6,77.9z"/>
+    <path
+        android:fillColor="#FFDBA6"
+        android:pathData="M148.6,77.9l-6.5-8.3c-1.9-2.3-4.2-4.1-6.7-2.3l0,0l0,0c-2.5,1.8-1.6,4.5-0.1,7.1l3.8,6L148.6,77.9C148.6,77.9,148.6,77.9,148.6,77.9z"/>
+    <path
+        android:fillColor="#1A000000"
+        android:pathData="M151.1,92.5l-19.7-25.3c-1.9-2.3-4.2-4.1-6.7-2.3l0,0l0,0c-2.5,1.8-1.6,4.5-0.1,7.1l17.1,27.2L151.1,92.5z"/>
+    <path
+        android:fillColor="#FFDBA6"
+        android:pathData="M149.7,92.9l-19.7-25.3c-1.9-2.3-4.2-4.1-6.7-2.3l0,0l0,0c-2.5,1.8-1.6,4.5-0.1,7.1l17.1,27.2L149.7,92.9z"/>
+    <path
+        android:fillColor="#1A000000"
+        android:pathData="M141.6,94.6l-20.8-26.7c-2.1-2.5-4.4-4.3-7.1-2.5l0,0l0,0c-2.6,1.9-1.7,4.7-0.1,7.5l18,28.6L141.6,94.6z"/>
+    <path
+        android:fillColor="#FFDBA6"
+        android:pathData="M140.1,95l-20.8-26.7c-2.1-2.5-4.4-4.3-7.1-2.5l0,0h0c-2.6,1.9-1.7,4.7-0.1,7.5l18,28.6L140.1,95z"/>
+    <path
+        android:fillColor="#1A000000"
+        android:pathData="M140.4,99.1c-0.5-0.6-2.1-7.5-2.8-7.3l-15.9-6.9c-0.3,0-0.5-0.1-0.7-0.3l-2.3-3.5
+        l-0.4-0.6L100,54.5c-1.5-2-3.3-4-5.3-4.3c-0.7-0.1-1.3-0.2-2,0.2v0c-1,0.6-1.2,1.5-1.3,2.4c-0.2,1.8,0.6,3.9,1.6,5.9L108.5,87
+        l0.2,0.4l6.6,11.7l0,0c2.5,4.5,4.4,10.5,4.4,10.7L140.4,99.1"/>
+    <path
+        android:fillColor="#FFDBA6"
+        android:pathData="M129.7,125.1c3,0.7,8.1,4,11.8,9.1c2.7,3.7,5.5,8.3,8.2,13
+        c7.6-2.3,19.9-6.8,24.9-12.9c-0.2-0.3-0.4-0.6-0.6-0.9c0-0.1-0.1-0.1-0.1-0.2c-0.1-0.2-0.3-0.5-0.4-0.7c-4.5-7.1-8-12.4-8.9-13.7
+        c0,0,0,0,0,0.1c0-0.1-0.1-0.1-0.1-0.2c-0.1-0.1-1.9-3-1.9-3.1c-5.7-21.5-10.7-33.4-11.8-35.1c-0.1-0.1-1.5-1.9-2.1-2.6
+        c-0.5-0.6-0.9-0.5-1.6-0.3l-26.8,7.7c-0.3,0-0.5-0.1-0.7-0.3l-2.3-3.5l-0.4-0.6L98.5,54.8c-1.5-2-3.3-4-5.3-4.3
+        c-0.7-0.1-1.3-0.2-2,0.2c-1,0.6-1.2,1.5-1.3,2.4c-0.2,1.8,0.6,3.9,1.6,5.9L107,87.3l0.2,0.4l6.6,11.7l0,0
+        c2.5,4.5,4.4,10.5,4.4,10.7L129.7,125.1"/>
+    <path
+        android:fillColor="@color/all_apps_bg_hand_fill"
+        android:pathData="M202.3,183.1c-5.4-14.1-23.8-44.3-26.7-49c-0.2-0.3-0.6-0.3-0.8,0
+        c-5.1,6.6-19,11.4-26.5,13.6c-0.3,0.1-1,0.1-1.2,0.6c-0.2,0.4,0.1,1,0.2,1.1c7.8,12.9,14.7,27.9,15.3,29.3c0,0.1,0.1,0.1,0.1,0.2
+        l9.6,22.9c0,0,0,0,0,0l1.7,4.1c1.4,2.7,3,4.3,5.3,5.1c1.5,0.5,2.1,0.6,3.2,0.6c4.8,0.1,15.2-6.1,20.5-9.4c2.7-1.7,3.3-4.4,2.9-7.6
+        C205.5,191.5,204.4,188.4,202.3,183.1z"/>
+</vector>
\ No newline at end of file
diff --git a/res/layout/app_widget_resize_frame.xml b/res/layout/app_widget_resize_frame.xml
index 91a1e45..874fecc 100644
--- a/res/layout/app_widget_resize_frame.xml
+++ b/res/layout/app_widget_resize_frame.xml
@@ -20,38 +20,43 @@
     android:layout_height="match_parent"
     android:background="@drawable/widget_resize_shadow"
     android:foreground="@drawable/widget_resize_frame"
+    android:foregroundTint="?attr/workspaceTextColor"
     android:padding="0dp" >
 
     <!-- Left -->
     <ImageView
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:src="@drawable/ic_widget_resize_handle"
         android:layout_gravity="left|center_vertical"
-        android:layout_marginLeft="@dimen/widget_handle_margin" />
+        android:layout_marginLeft="@dimen/widget_handle_margin"
+        android:src="@drawable/ic_widget_resize_handle"
+        android:tint="?attr/workspaceTextColor" />
 
     <!-- Top -->
     <ImageView
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:src="@drawable/ic_widget_resize_handle"
         android:layout_gravity="top|center_horizontal"
-        android:layout_marginTop="@dimen/widget_handle_margin" />
+        android:layout_marginTop="@dimen/widget_handle_margin"
+        android:src="@drawable/ic_widget_resize_handle"
+        android:tint="?attr/workspaceTextColor" />
 
     <!-- Right -->
     <ImageView
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:src="@drawable/ic_widget_resize_handle"
         android:layout_gravity="right|center_vertical"
-        android:layout_marginRight="@dimen/widget_handle_margin" />
+        android:layout_marginRight="@dimen/widget_handle_margin"
+        android:src="@drawable/ic_widget_resize_handle"
+        android:tint="?attr/workspaceTextColor" />
 
     <!-- Bottom -->
     <ImageView
         android:layout_width="wrap_content"
         android:layout_height="wrap_content"
-        android:src="@drawable/ic_widget_resize_handle"
         android:layout_gravity="bottom|center_horizontal"
-        android:layout_marginBottom="@dimen/widget_handle_margin" />
+        android:layout_marginBottom="@dimen/widget_handle_margin"
+        android:src="@drawable/ic_widget_resize_handle"
+        android:tint="?attr/workspaceTextColor" />
 
 </com.android.launcher3.AppWidgetResizeFrame>
\ No newline at end of file
diff --git a/res/layout/widgets_bottom_sheet.xml b/res/layout/widgets_bottom_sheet.xml
index c2270d2..f1370f0 100644
--- a/res/layout/widgets_bottom_sheet.xml
+++ b/res/layout/widgets_bottom_sheet.xml
@@ -25,11 +25,11 @@
     android:layout_gravity="bottom">
 
     <TextView
+        style="@style/TextTitle"
         android:id="@+id/title"
         android:layout_width="match_parent"
         android:layout_height="wrap_content"
         android:gravity="center_horizontal"
-        android:fontFamily="sans-serif"
         android:textColor="?android:attr/textColorPrimary"
         android:textSize="24sp"/>
 
diff --git a/res/values-sw720dp/styles.xml b/res/values-sw720dp/styles.xml
index 5cfe84f..bb0dbc2 100644
--- a/res/values-sw720dp/styles.xml
+++ b/res/values-sw720dp/styles.xml
@@ -27,22 +27,12 @@
         <item name="android:windowActionModeOverlay">true</item>
         <item name="android:colorEdgeEffect">?android:attr/textColorSecondary</item>
         <item name="android:keyboardLayout">@layout/all_apps_search_container</item>
-        <item name="allAppsScrimColor">#DDFFFFFF</item>
-        <item name="popupColorPrimary">#FFF</item>
-        <item name="popupColorSecondary">#F5F5F5</item> <!-- Gray 100 -->
-        <item name="popupColorTertiary">#E0E0E0</item> <!-- Gray 300 -->
-        <item name="isMainColorDark">false</item>
-        <item name="isWorkspaceDarkText">false</item>
-        <item name="workspaceTextColor">?android:textColorPrimary</item>
-        <item name="workspaceAmbientShadowColor">#22000000</item>
-        <item name="workspaceKeyShadowColor">#44000000</item>
     </style>
 
     <!-- Workspace -->
     <style name="DropTargetButton" parent="DropTargetButtonBase">
         <item name="android:paddingLeft">60dp</item>
         <item name="android:paddingRight">60dp</item>
-        <item name="android:shadowColor">?attr/workspaceShadowColor</item>
         <item name="android:shadowDx">0.0</item>
         <item name="android:shadowDy">0.0</item>
         <item name="android:shadowRadius">2.0</item>
diff --git a/res/values-v19/styles.xml b/res/values-v19/styles.xml
index cfc7c0f..36c0971 100644
--- a/res/values-v19/styles.xml
+++ b/res/values-v19/styles.xml
@@ -18,7 +18,7 @@
 -->
 <resources>
 
-    <style name="LauncherTheme" parent="@style/BaseLauncherTheme">
+    <style name="LauncherTheme" parent="@style/BaseLauncherThemeWithCustomAttrs">
         <item name="android:windowTranslucentStatus">true</item>
         <item name="android:windowTranslucentNavigation">true</item>
     </style>
diff --git a/res/values-v21/styles.xml b/res/values-v21/styles.xml
index 8d3de01..927719c 100644
--- a/res/values-v21/styles.xml
+++ b/res/values-v21/styles.xml
@@ -18,7 +18,7 @@
 -->
 <resources>
 
-    <style name="LauncherTheme" parent="@style/BaseLauncherTheme">
+    <style name="LauncherTheme" parent="@style/BaseLauncherThemeWithCustomAttrs">
         <item name="android:windowTranslucentStatus">false</item>
         <item name="android:windowTranslucentNavigation">false</item>
         <item name="android:windowDrawsSystemBarBackgrounds">true</item>
diff --git a/res/values/colors.xml b/res/values/colors.xml
index 52c61e7..4f7c1a7 100644
--- a/res/values/colors.xml
+++ b/res/values/colors.xml
@@ -37,4 +37,6 @@
 
     <color name="icon_background">#E0E0E0</color> <!-- Gray 300 -->
     <color name="legacy_icon_background">#FFFFFF</color>
+
+    <color name="all_apps_bg_hand_fill">#E5E5E5</color>
 </resources>
diff --git a/res/values/styles.xml b/res/values/styles.xml
index 70f65ca..8af6968 100644
--- a/res/values/styles.xml
+++ b/res/values/styles.xml
@@ -26,20 +26,23 @@
         <item name="android:windowNoTitle">true</item>
         <item name="android:colorEdgeEffect">#FF757575</item>
         <item name="android:keyboardLayout">@layout/all_apps_search_container</item>
+    </style>
+
+    <style name="BaseLauncherThemeWithCustomAttrs" parent="@style/BaseLauncherTheme">
         <item name="allAppsScrimColor">#DDFFFFFF</item>
         <item name="popupColorPrimary">#FFF</item>
         <item name="popupColorSecondary">#F5F5F5</item> <!-- Gray 100 -->
         <item name="popupColorTertiary">#E0E0E0</item> <!-- Gray 300 -->
         <item name="isMainColorDark">false</item>
         <item name="isWorkspaceDarkText">false</item>
-        <item name="workspaceTextColor">?android:textColorPrimary</item>
+        <item name="workspaceTextColor">@android:color/white</item>
         <item name="workspaceShadowColor">#B0000000</item>
-        <item name="workspaceAmbientShadowColor">#22000000</item>
+        <item name="workspaceAmbientShadowColor">#33000000</item>
         <item name="workspaceKeyShadowColor">#44000000</item>
         <item name="workspaceStatusBarScrim">@drawable/workspace_bg</item>
     </style>
 
-    <style name="LauncherTheme" parent="@style/BaseLauncherTheme"></style>
+    <style name="LauncherTheme" parent="@style/BaseLauncherThemeWithCustomAttrs"></style>
 
     <style name="LauncherThemeDarkText" parent="@style/LauncherTheme">
         <item name="workspaceTextColor">#FF212121</item>
@@ -66,13 +69,13 @@
 
     <!--
     Theme overrides to element on homescreen, i.e., which are drawn on top on wallpaper.
-    Various foreground colors are overridden to be white so that they are properly visible on
-    various wallpapers
+    Various foreground colors are overridden to be workspaceTextColor so that they are properly
+    visible on various wallpapers.
     -->
     <style name="HomeScreenElementTheme">
-        <item name="android:colorEdgeEffect">@android:color/white</item>
-        <item name="android:textColorPrimary">@android:color/white</item>
-        <item name="android:textColorSecondary">@android:color/white</item>
+        <item name="android:colorEdgeEffect">?attr/workspaceTextColor</item>
+        <item name="android:textColorPrimary">?attr/workspaceTextColor</item>
+        <item name="android:textColorSecondary">?attr/workspaceTextColor</item>
     </style>
 
     <!-- Theme for the widget container. Overridden on API 26. -->
@@ -123,8 +126,7 @@
     <style name="BaseIcon.Workspace">
         <item name="customShadows">true</item>
         <item name="android:shadowRadius">2.0</item>
-        <item name="android:shadowColor">#B0000000</item>
-        <item name="android:textColor">?attr/workspaceTextColor</item>
+        <item name="android:shadowColor">?attr/workspaceShadowColor</item>
         <item name="keyShadowColor">?attr/workspaceKeyShadowColor</item>
         <item name="ambientShadowColor">?attr/workspaceAmbientShadowColor</item>
     </style>
@@ -150,4 +152,8 @@
     </style>
 
     <style name="DropTargetButton" parent="DropTargetButtonBase" />
+
+    <style name="TextTitle">
+        <item name="android:fontFamily">sans-serif</item>
+    </style>
 </resources>
diff --git a/src/com/android/launcher3/BubbleTextView.java b/src/com/android/launcher3/BubbleTextView.java
index b0e8b1e..27e190e 100644
--- a/src/com/android/launcher3/BubbleTextView.java
+++ b/src/com/android/launcher3/BubbleTextView.java
@@ -51,7 +51,6 @@
 import com.android.launcher3.graphics.IconPalette;
 import com.android.launcher3.graphics.PreloadIconDrawable;
 import com.android.launcher3.model.PackageItemInfo;
-import com.android.launcher3.util.Themes;
 
 import java.text.NumberFormat;
 
diff --git a/src/com/android/launcher3/anim/AnimationLayerSet.java b/src/com/android/launcher3/anim/AnimationLayerSet.java
index 14bcd17..f0b3458 100644
--- a/src/com/android/launcher3/anim/AnimationLayerSet.java
+++ b/src/com/android/launcher3/anim/AnimationLayerSet.java
@@ -18,9 +18,8 @@
 
 import android.animation.Animator;
 import android.animation.AnimatorListenerAdapter;
+import android.util.ArrayMap;
 import android.view.View;
-
-import java.util.HashMap;
 import java.util.Iterator;
 import java.util.Map;
 
@@ -29,14 +28,14 @@
  */
 public class AnimationLayerSet extends AnimatorListenerAdapter {
 
-    private final HashMap<View, Integer> mViewsToLayerTypeMap;
+    private final ArrayMap<View, Integer> mViewsToLayerTypeMap;
 
     public AnimationLayerSet() {
-        mViewsToLayerTypeMap = new HashMap<>();
+        mViewsToLayerTypeMap = new ArrayMap<>();
     }
 
     public AnimationLayerSet(View v) {
-        mViewsToLayerTypeMap = new HashMap<>(1);
+        mViewsToLayerTypeMap = new ArrayMap<>(1);
         addView(v);
     }