summaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2016-05-25 18:56:41 -0700
committerSunny Goyal <sunnygoyal@google.com>2016-06-06 16:15:46 -0700
commit47328fd53f43fd0c2ed14ad925dd04483f9229a0 (patch)
tree68584a0a8662f18241748b22f061c564acae790b /res
parent63741779e564ea9c6814800199b994f7464906db (diff)
downloadandroid_packages_apps_Trebuchet-47328fd53f43fd0c2ed14ad925dd04483f9229a0.tar.gz
android_packages_apps_Trebuchet-47328fd53f43fd0c2ed14ad925dd04483f9229a0.tar.bz2
android_packages_apps_Trebuchet-47328fd53f43fd0c2ed14ad925dd04483f9229a0.zip
Removing the SearchDropTarget bar as it no longer contains the QSB
> Renaming it to simply DropTargetBar > Moving AppInfo to the top bar as well > The workspace pages will extend to the top edge (minus some padding). Since the QSB is no longer displayed on top of every page, there is no reason to reserve the space. > In spring-loaded mode, the workspace cell layout will scale enough to make room for the drop target bar at the top Change-Id: I2baf607310335dd576c9d9fcbb75ab708f47ac03
Diffstat (limited to 'res')
-rw-r--r--res/layout-land/launcher.xml8
-rw-r--r--res/layout-port/launcher.xml10
-rw-r--r--res/layout-sw720dp/launcher.xml10
-rw-r--r--res/layout/drop_target_bar_horz.xml79
-rw-r--r--res/layout/drop_target_bar_horz_info.xml39
-rw-r--r--res/layout/drop_target_bar_horz_search.xml69
-rw-r--r--res/layout/drop_target_bar_vert.xml63
-rw-r--r--res/layout/drop_target_bar_vert_info.xml39
-rw-r--r--res/layout/drop_target_bar_vert_search.xml56
-rw-r--r--res/values/dimens.xml23
10 files changed, 160 insertions, 236 deletions
diff --git a/res/layout-land/launcher.xml b/res/layout-land/launcher.xml
index 3a361e28d..1147326f7 100644
--- a/res/layout-land/launcher.xml
+++ b/res/layout-land/launcher.xml
@@ -51,12 +51,8 @@
android:layout_gravity="right" />
<include
- android:id="@+id/app_info_drop_target_bar"
- layout="@layout/drop_target_bar_vert_info" />
-
- <include
- android:id="@+id/search_drop_target_bar"
- layout="@layout/drop_target_bar_vert_search" />
+ android:id="@+id/drop_target_bar"
+ layout="@layout/drop_target_bar_vert" />
<include layout="@layout/overview_panel"
android:id="@+id/overview_panel"
diff --git a/res/layout-port/launcher.xml b/res/layout-port/launcher.xml
index 4576e4d06..fed99f331 100644
--- a/res/layout-port/launcher.xml
+++ b/res/layout-port/launcher.xml
@@ -60,15 +60,11 @@
<com.android.launcher3.pageindicators.PageIndicatorLine
android:id="@+id/page_indicator"
android:layout_width="match_parent"
- android:layout_height="1dp" />
+ android:layout_height="@dimen/dynamic_grid_page_indicator_height" />
<include
- android:id="@+id/app_info_drop_target_bar"
- layout="@layout/drop_target_bar_horz_info" />
-
- <include
- android:id="@+id/search_drop_target_bar"
- layout="@layout/drop_target_bar_horz_search" />
+ android:id="@+id/drop_target_bar"
+ layout="@layout/drop_target_bar_horz" />
<include layout="@layout/widgets_view"
android:id="@+id/widgets_view"
diff --git a/res/layout-sw720dp/launcher.xml b/res/layout-sw720dp/launcher.xml
index 0f755d8e1..23e673cbf 100644
--- a/res/layout-sw720dp/launcher.xml
+++ b/res/layout-sw720dp/launcher.xml
@@ -51,12 +51,8 @@
android:layout_height="match_parent" />
<include
- android:id="@+id/app_info_drop_target_bar"
- layout="@layout/drop_target_bar_horz_info" />
-
- <include
- android:id="@+id/search_drop_target_bar"
- layout="@layout/drop_target_bar_horz_search" />
+ android:id="@+id/drop_target_bar"
+ layout="@layout/drop_target_bar_horz" />
<include layout="@layout/overview_panel"
android:id="@+id/overview_panel"
@@ -67,7 +63,7 @@
<com.android.launcher3.pageindicators.PageIndicatorLine
android:id="@+id/page_indicator"
android:layout_width="match_parent"
- android:layout_height="1dp" />
+ android:layout_height="@dimen/dynamic_grid_page_indicator_height" />
<include layout="@layout/widgets_view"
android:id="@+id/widgets_view"
diff --git a/res/layout/drop_target_bar_horz.xml b/res/layout/drop_target_bar_horz.xml
new file mode 100644
index 000000000..ee22d1e74
--- /dev/null
+++ b/res/layout/drop_target_bar_horz.xml
@@ -0,0 +1,79 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright (C) 2015 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<com.android.launcher3.DropTargetBar
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ xmlns:launcher="http://schemas.android.com/apk/res-auto"
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/dynamic_grid_drop_target_size"
+ android:layout_gravity="center_horizontal|top"
+ android:focusable="false">
+
+ <FrameLayout
+ android:layout_width="0dp"
+ android:layout_height="match_parent"
+ android:layout_weight="1" >
+
+ <!-- Delete target -->
+
+ <com.android.launcher3.DeleteDropTarget
+ launcher:hideParentOnDisable="true"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:layout_gravity="center"
+ android:gravity="center"
+ android:id="@+id/delete_target_text"
+ style="@style/DropTargetButton"
+ android:text="@string/remove_drop_target_label" />
+ </FrameLayout>
+
+ <FrameLayout
+ android:layout_width="0dp"
+ android:layout_height="match_parent"
+ android:layout_weight="1" >
+
+ <!-- App Info -->
+
+ <com.android.launcher3.InfoDropTarget
+ launcher:hideParentOnDisable="true"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:layout_gravity="center"
+ android:gravity="center"
+ android:id="@+id/info_target_text"
+ style="@style/DropTargetButton"
+ android:text="@string/app_info_drop_target_label" />
+ </FrameLayout>
+
+ <FrameLayout
+ android:layout_width="0dp"
+ android:layout_height="match_parent"
+ android:layout_weight="1" >
+
+ <!-- Uninstall target -->
+
+ <com.android.launcher3.UninstallDropTarget
+ launcher:hideParentOnDisable="true"
+ android:layout_width="wrap_content"
+ android:layout_height="match_parent"
+ android:layout_gravity="center"
+ android:gravity="center"
+ android:id="@+id/uninstall_target_text"
+ style="@style/DropTargetButton"
+ android:text="@string/uninstall_drop_target_label" />
+ </FrameLayout>
+
+</com.android.launcher3.DropTargetBar> \ No newline at end of file
diff --git a/res/layout/drop_target_bar_horz_info.xml b/res/layout/drop_target_bar_horz_info.xml
deleted file mode 100644
index 92a9b2286..000000000
--- a/res/layout/drop_target_bar_horz_info.xml
+++ /dev/null
@@ -1,39 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- Copyright (C) 2016 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<com.android.launcher3.AppInfoDropTargetBar xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="match_parent"
- android:layout_height="48dp"
- android:layout_gravity="center_horizontal|bottom"
- android:focusable="false" >
-
- <FrameLayout
- android:id="@+id/drag_target_bar"
- android:layout_width="match_parent"
- android:layout_height="match_parent">
-
- <!-- Info target -->
-
- <com.android.launcher3.InfoDropTarget
- android:layout_width="wrap_content"
- android:layout_height="match_parent"
- android:layout_gravity="center"
- android:gravity="center"
- android:id="@+id/info_target_text"
- style="@style/DropTargetButton"
- android:text="@string/app_info_drop_target_label" />
- </FrameLayout>
-</com.android.launcher3.AppInfoDropTargetBar> \ No newline at end of file
diff --git a/res/layout/drop_target_bar_horz_search.xml b/res/layout/drop_target_bar_horz_search.xml
deleted file mode 100644
index 7997801b4..000000000
--- a/res/layout/drop_target_bar_horz_search.xml
+++ /dev/null
@@ -1,69 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- Copyright (C) 2015 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<com.android.launcher3.SearchDropTargetBar xmlns:android="http://schemas.android.com/apk/res/android"
- xmlns:launcher="http://schemas.android.com/apk/res-auto"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:layout_gravity="center_horizontal|top"
- android:focusable="false">
-
- <!-- Drag specific targets container -->
-
- <LinearLayout
- android:id="@+id/drag_target_bar"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:layout_gravity="center" >
-
- <FrameLayout
- android:layout_width="0dp"
- android:layout_height="match_parent"
- android:layout_weight="1" >
-
- <!-- Delete target -->
-
- <com.android.launcher3.DeleteDropTarget
- launcher:hideParentOnDisable="true"
- android:layout_width="wrap_content"
- android:layout_height="match_parent"
- android:layout_gravity="center"
- android:gravity="center"
- android:id="@+id/delete_target_text"
- style="@style/DropTargetButton"
- android:text="@string/remove_drop_target_label" />
- </FrameLayout>
-
- <FrameLayout
- android:layout_width="0dp"
- android:layout_height="match_parent"
- android:layout_weight="1" >
-
- <!-- Uninstall target -->
-
- <com.android.launcher3.UninstallDropTarget
- launcher:hideParentOnDisable="true"
- android:layout_width="wrap_content"
- android:layout_height="match_parent"
- android:layout_gravity="center"
- android:gravity="center"
- android:id="@+id/uninstall_target_text"
- style="@style/DropTargetButton"
- android:text="@string/uninstall_drop_target_label" />
- </FrameLayout>
- </LinearLayout>
-
-</com.android.launcher3.SearchDropTargetBar> \ No newline at end of file
diff --git a/res/layout/drop_target_bar_vert.xml b/res/layout/drop_target_bar_vert.xml
new file mode 100644
index 000000000..10b1d7cc8
--- /dev/null
+++ b/res/layout/drop_target_bar_vert.xml
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+ Copyright (C) 2016 The Android Open Source Project
+
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<com.android.launcher3.DropTargetBar
+ xmlns:android="http://schemas.android.com/apk/res/android"
+ android:layout_width="@dimen/dynamic_grid_drop_target_size"
+ android:orientation="vertical"
+ android:layout_height="match_parent"
+ android:layout_gravity="left"
+ android:focusable="false"
+ android:paddingTop="@dimen/vert_drop_target_vertical_gap" >
+
+ <!-- Delete target -->
+ <com.android.launcher3.DeleteDropTarget
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/dynamic_grid_drop_target_size"
+ android:gravity="center"
+ android:paddingLeft="@dimen/vert_drop_target_horizontal_gap"
+ android:paddingRight="@dimen/vert_drop_target_horizontal_gap"
+ android:id="@+id/delete_target_text"
+ android:textColor="@android:color/white" />
+
+ <!-- Uninstall target -->
+ <com.android.launcher3.UninstallDropTarget
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/dynamic_grid_drop_target_size"
+ android:gravity="center"
+ android:paddingLeft="@dimen/vert_drop_target_horizontal_gap"
+ android:paddingRight="@dimen/vert_drop_target_horizontal_gap"
+ android:id="@+id/uninstall_target_text"
+ android:textColor="@android:color/white"
+ android:layout_marginTop="@dimen/vert_drop_target_vertical_gap"/>
+
+ <Space
+ android:layout_width="match_parent"
+ android:layout_height="0dp"
+ android:layout_weight="1" />
+
+ <!-- App Info -->
+ <com.android.launcher3.InfoDropTarget
+ android:layout_width="match_parent"
+ android:layout_height="@dimen/dynamic_grid_drop_target_size"
+ android:gravity="center"
+ android:paddingLeft="@dimen/vert_drop_target_horizontal_gap"
+ android:paddingRight="@dimen/vert_drop_target_horizontal_gap"
+ android:id="@+id/info_target_text"
+ android:textColor="@android:color/white"
+ android:layout_marginBottom="64dp"/>
+
+</com.android.launcher3.DropTargetBar> \ No newline at end of file
diff --git a/res/layout/drop_target_bar_vert_info.xml b/res/layout/drop_target_bar_vert_info.xml
deleted file mode 100644
index da33d1a9c..000000000
--- a/res/layout/drop_target_bar_vert_info.xml
+++ /dev/null
@@ -1,39 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- Copyright (C) 2016 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<com.android.launcher3.AppInfoDropTargetBar xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="48dp"
- android:layout_height="match_parent"
- android:focusable="false" >
-
- <FrameLayout
- android:id="@+id/drag_target_bar"
- android:layout_width="match_parent"
- android:layout_height="match_parent">
-
- <!-- Info target -->
- <com.android.launcher3.InfoDropTarget
- android:layout_width="48dp"
- android:layout_height="48dp"
- android:layout_gravity="center_horizontal|bottom"
- android:gravity="center"
- android:paddingLeft="14dp"
- android:paddingRight="14dp"
- android:textColor="@android:color/white"
- android:id="@+id/info_target_text" />
- </FrameLayout>
-
-</com.android.launcher3.AppInfoDropTargetBar> \ No newline at end of file
diff --git a/res/layout/drop_target_bar_vert_search.xml b/res/layout/drop_target_bar_vert_search.xml
deleted file mode 100644
index d5e41df39..000000000
--- a/res/layout/drop_target_bar_vert_search.xml
+++ /dev/null
@@ -1,56 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
- Copyright (C) 2015 The Android Open Source Project
-
- Licensed under the Apache License, Version 2.0 (the "License");
- you may not use this file except in compliance with the License.
- You may obtain a copy of the License at
-
- http://www.apache.org/licenses/LICENSE-2.0
-
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
--->
-<com.android.launcher3.SearchDropTargetBar xmlns:android="http://schemas.android.com/apk/res/android"
- android:layout_width="48dp"
- android:layout_height="match_parent"
- android:focusable="false">
-
- <!-- Drag specific targets container -->
-
- <LinearLayout
- android:id="@+id/drag_target_bar"
- android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:orientation="vertical"
- android:layout_gravity="center"
- android:paddingTop="20dp">
-
- <!-- Delete target -->
- <com.android.launcher3.DeleteDropTarget
- android:layout_width="48dp"
- android:layout_height="48dp"
- android:gravity="center"
- android:paddingLeft="14dp"
- android:paddingRight="14dp"
- android:id="@+id/delete_target_text"
- android:textColor="@android:color/white"
- android:layout_marginBottom="10dp" />
-
- <!-- Uninstall target -->
- <com.android.launcher3.UninstallDropTarget
- android:layout_width="48dp"
- android:layout_height="48dp"
- android:layout_gravity="center"
- android:gravity="center"
- android:paddingLeft="14dp"
- android:paddingRight="14dp"
- android:id="@+id/uninstall_target_text"
- android:textColor="@android:color/white"
- android:layout_marginTop="10dp"/>
- </LinearLayout>
-
-</com.android.launcher3.SearchDropTargetBar> \ No newline at end of file
diff --git a/res/values/dimens.xml b/res/values/dimens.xml
index 7510fafd5..35ee58e69 100644
--- a/res/values/dimens.xml
+++ b/res/values/dimens.xml
@@ -17,19 +17,7 @@
<resources>
<!-- Dynamic Grid -->
<dimen name="dynamic_grid_edge_margin">6dp</dimen>
- <dimen name="dynamic_grid_search_bar_height">48dp</dimen>
- <!-- We want 46dp extra for the tall search bar. -->
- <dimen name="dynamic_grid_search_bar_height_tall">94dp</dimen>
- <dimen name="qsb_internal_padding_top">8dp</dimen>
- <dimen name="qsb_internal_padding_bottom">8dp</dimen>
- <dimen name="dynamic_grid_search_bar_extra_top_padding">0dp</dimen>
- <!-- Reduce the space between the status bar and the search bar when the search bar is tall -->
- <dimen name="dynamic_grid_search_bar_negative_top_padding_short">-4dp</dimen>
- <dimen name="dynamic_grid_search_bar_bottom_padding">4dp</dimen>
- <!-- Reduce the padding between the search bar and workspace when the search bar is tall -->
- <dimen name="dynamic_grid_search_bar_bottom_negative_padding_short">-6dp</dimen>
- <dimen name="dynamic_grid_search_bar_bottom_padding_tablet">16dp</dimen>
- <dimen name="dynamic_grid_page_indicator_height">20dp</dimen>
+ <dimen name="dynamic_grid_page_indicator_height">1dp</dimen>
<dimen name="dynamic_grid_icon_drawable_padding">4dp</dimen>
<dimen name="dynamic_grid_workspace_page_spacing">8dp</dimen>
<dimen name="dynamic_grid_overview_min_icon_zone_height">80dp</dimen>
@@ -37,6 +25,15 @@
<dimen name="dynamic_grid_overview_bar_item_width">80dp</dimen>
<dimen name="dynamic_grid_overview_bar_spacer_width">20dp</dimen>
+ <dimen name="dynamic_grid_workspace_top_padding">12dp</dimen>
+ <!-- Minimum space between workspace and hotseat in spring loaded mode -->
+ <dimen name="dynamic_grid_min_spring_loaded_space">8dp</dimen>
+
+<!-- Drop target bar -->
+ <dimen name="dynamic_grid_drop_target_size">48dp</dimen>
+ <dimen name="vert_drop_target_vertical_gap">20dp</dimen>
+ <dimen name="vert_drop_target_horizontal_gap">14dp</dimen>
+
<!-- App Widget resize frame -->
<dimen name="default_widget_padding">8dp</dimen>
<dimen name="widget_handle_margin">13dp</dimen>