Converting widget panel into a floating view
> The widget panel is only inflated when needed
> Using the swipe up/down interaction for widgets tray
> Removing additional view wrappers from all-apps
> Widget tray is preserved across activity recreation
> Launcher no longer has WIDGET state, the actual code around
the states will be removed in a follow-up cl
Bug: 67678570
Bug: 67585158
Change-Id: Ia29a7c33ec81e6c53cc24e2906b7022b6f41755b
diff --git a/res/layout/all_apps.xml b/res/layout/all_apps.xml
index 39df2b1..6f837ae 100644
--- a/res/layout/all_apps.xml
+++ b/res/layout/all_apps.xml
@@ -18,60 +18,39 @@
will bake the left/right padding into that view's background itself. -->
<com.android.launcher3.allapps.AllAppsContainerView
xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:launcher="http://schemas.android.com/apk/res-auto"
android:id="@+id/apps_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:orientation="vertical"
- launcher:revealBackground="@drawable/round_rect_primary">
+ android:clipChildren="true"
+ android:clipToPadding="false"
+ android:focusable="true"
+ android:focusableInTouchMode="true"
+ android:saveEnabled="false" >
- <View
- android:id="@+id/reveal_view"
+ <!-- DO NOT CHANGE THE ID -->
+ <com.android.launcher3.allapps.AllAppsRecyclerView
+ android:id="@+id/apps_list_view"
android:layout_width="match_parent"
android:layout_height="match_parent"
- android:layout_gravity="center"
- android:focusable="false"
- android:visibility="invisible" />
-
-
- <com.android.launcher3.allapps.AllAppsRecyclerViewContainerView
- android:id="@+id/main_content"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:layout_gravity="center"
- android:focusable="true"
+ android:layout_below="@id/search_container_all_apps"
+ android:layout_gravity="center_horizontal|top"
android:clipToPadding="false"
- android:clipChildren="true"
- android:focusableInTouchMode="true"
- android:saveEnabled="false"
- android:visibility="gone">
+ android:descendantFocusability="afterDescendants"
+ android:focusable="true"
+ android:overScrollMode="never" />
- <!-- DO NOT CHANGE THE ID -->
- <com.android.launcher3.allapps.AllAppsRecyclerView
- android:id="@+id/apps_list_view"
- android:layout_below="@id/search_container_all_apps"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:layout_gravity="center_horizontal|top"
- android:clipToPadding="false"
- android:overScrollMode="never"
- android:descendantFocusability="afterDescendants"
- android:focusable="true" />
+ <!-- Note: we are reusing/repurposing a system attribute for search layout, because of a
+ platform bug, which prevents using custom attributes in <include> tag -->
+ <include
+ android:id="@id/search_container_all_apps"
+ layout="?android:attr/keyboardLayout" />
- <!-- Note: we are reusing/repurposing a system attribute for search layout, because of a
- platform bug, which prevents using custom attributes in <include> tag -->
- <include
- layout="?android:attr/keyboardLayout"
- android:id="@id/search_container_all_apps" />
+ <include layout="@layout/all_apps_fast_scroller" />
- <include layout="@layout/all_apps_fast_scroller" />
-
- </com.android.launcher3.allapps.AllAppsRecyclerViewContainerView>
<View
android:id="@+id/nav_bar_bg"
- android:background="?attr/allAppsNavBarScrimColor"
android:layout_width="match_parent"
android:layout_height="0dp"
- android:layout_gravity="bottom"
- android:focusable="false" />
+ android:layout_alignParentBottom="true"
+ android:background="?attr/allAppsNavBarScrimColor" />
</com.android.launcher3.allapps.AllAppsContainerView>
\ No newline at end of file