summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaj Yengisetty <rajesh@cyngn.com>2014-08-11 19:46:17 (GMT)
committerAbhisek Devkota <ciwrl@cyanogenmod.com>2014-12-02 01:17:18 (GMT)
commitb238835749266144bb94a6e83172f0938d5a8c6e (patch)
tree58aad00431617ca461208d7884bee17accef2c50
parentc398b8b621f284295b8eafb9c729743a53f40ad2 (diff)
downloadandroid_packages_apps_Trebuchet-b238835749266144bb94a6e83172f0938d5a8c6e.zip
android_packages_apps_Trebuchet-b238835749266144bb94a6e83172f0938d5a8c6e.tar.gz
android_packages_apps_Trebuchet-b238835749266144bb94a6e83172f0938d5a8c6e.tar.bz2
Fix spacing issues on devices with/without nav-bar in overview settings panel
Change-Id: I329b63b780e5727307770e076bf03e3bc4d82dd0
-rwxr-xr-xres/layout/settings_pane.xml5
-rw-r--r--res/layout/settings_transitions_screen.xml1
-rw-r--r--src/com/android/launcher3/DynamicGridSizeFragment.java10
-rw-r--r--src/com/android/launcher3/TransitionEffectsFragment.java1
4 files changed, 11 insertions, 6 deletions
diff --git a/res/layout/settings_pane.xml b/res/layout/settings_pane.xml
index e12839e..43dbced 100755
--- a/res/layout/settings_pane.xml
+++ b/res/layout/settings_pane.xml
@@ -1,6 +1,7 @@
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
+ android:background="@color/settings_bg_color"
android:layout_height="match_parent" >
<LinearLayout
@@ -8,9 +9,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center_horizontal|bottom"
- android:background="@color/settings_bg_color"
- android:orientation="vertical"
- android:paddingBottom="@dimen/overview_panel_bottom_padding" >
+ android:orientation="vertical" >
<LinearLayout
android:id="@+id/settings_pane_header"
diff --git a/res/layout/settings_transitions_screen.xml b/res/layout/settings_transitions_screen.xml
index b87c1fc..fca36a8 100644
--- a/res/layout/settings_transitions_screen.xml
+++ b/res/layout/settings_transitions_screen.xml
@@ -4,7 +4,6 @@
android:layout_gravity="center_horizontal|bottom"
android:background="@color/settings_bg_color"
android:orientation="vertical"
- android:paddingBottom="@dimen/overview_panel_bottom_padding"
android:paddingTop="@dimen/overview_panel_bottom_padding"
android:clickable="true" >
diff --git a/src/com/android/launcher3/DynamicGridSizeFragment.java b/src/com/android/launcher3/DynamicGridSizeFragment.java
index 55d2bf0..5e3fcae 100644
--- a/src/com/android/launcher3/DynamicGridSizeFragment.java
+++ b/src/com/android/launcher3/DynamicGridSizeFragment.java
@@ -38,6 +38,7 @@ import android.view.View;
import android.view.ViewGroup;
import android.widget.BaseAdapter;
import android.widget.Button;
+import android.widget.FrameLayout;
import android.widget.ImageView;
import android.widget.LinearLayout;
import android.widget.ListView;
@@ -90,6 +91,14 @@ public class DynamicGridSizeFragment extends Fragment
Bundle savedInstanceState) {
View v = inflater.inflate(R.layout.dynamic_grid_size_screen, container, false);
mDynamicGrid = (GridSizeView) v.findViewById(R.id.dynamic_grid_size_image);
+ mListView = (ListView) v.findViewById(R.id.dynamic_grid_list);
+
+ Launcher launcher = (Launcher) getActivity();
+ LinearLayout.LayoutParams lp = (LinearLayout.LayoutParams)
+ mListView.getLayoutParams();
+ lp.bottomMargin = ((FrameLayout.LayoutParams) launcher.getOverviewPanel()
+ .findViewById(R.id.settings_container).getLayoutParams()).bottomMargin;
+ mListView.setLayoutParams(lp);
LinearLayout titleLayout = (LinearLayout) v.findViewById(R.id.dynamic_grid_title);
titleLayout.setOnClickListener(new View.OnClickListener() {
@@ -109,7 +118,6 @@ public class DynamicGridSizeFragment extends Fragment
updateGridMetrics();
- mListView = (ListView) v.findViewById(R.id.dynamic_grid_list);
Resources res = getResources();
int[] valueResIds = {
R.string.grid_size_comfortable,
diff --git a/src/com/android/launcher3/TransitionEffectsFragment.java b/src/com/android/launcher3/TransitionEffectsFragment.java
index f03aeab..d490a00 100644
--- a/src/com/android/launcher3/TransitionEffectsFragment.java
+++ b/src/com/android/launcher3/TransitionEffectsFragment.java
@@ -89,7 +89,6 @@ public class TransitionEffectsFragment extends Fragment {
: R.string.preferences_interface_homescreen_scrolling_transition_effect;
mTransitionIcon = (ImageView) v.findViewById(R.id.settings_transition_image);
- mListView = (ListView) v.findViewById(R.id.settings_transitions_list);
TextView title = (TextView) v.findViewById(R.id.transition_effect_title);
title.setText(getResources().getString(R.string.scroll_effect_text));
LinearLayout titleLayout = (LinearLayout) v.findViewById(R.id.transition_title);