summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJorge Ruesga <jorge@ruesga.com>2013-05-10 23:22:51 (GMT)
committerJorge Ruesga <jorge@ruesga.com>2013-05-11 00:29:24 (GMT)
commitd9dded5008d34d5ad059eaaa6e7796c0c1fbc1c9 (patch)
treec07be30c2bc608197a6e4e793898633ef184098b
parent3cae499900cb00ab7186a40fe69df5d64d0800f0 (diff)
downloadandroid_packages_apps_Trebuchet-d9dded5008d34d5ad059eaaa6e7796c0c1fbc1c9.zip
android_packages_apps_Trebuchet-d9dded5008d34d5ad059eaaa6e7796c0c1fbc1c9.tar.gz
android_packages_apps_Trebuchet-d9dded5008d34d5ad059eaaa6e7796c0c1fbc1c9.tar.bz2
Trebuchet: Centers horizontally the drawer on vertical orientationcm-10.1.0-RC2
The drawer (AppsCustomizePagedView) disable the use of centers horizontally && vertical every page. There is no problem with that on device with fixed grid, and on devices with isLargeScreen on horizontal orientation aligning the cellpagedview the top looks good. But when orientation is vertical, the cellpagedview is aligned to the left. In this case, this change forces the cellpagedview to center horizontally, which give to the cellpagedview the same good look than horizontal orientation. [before] https://sharecloud.ruesga.com/public.php?service=files&t=5fee1bd3e68fd28eafcaff13357956db [after] https://sharecloud.ruesga.com/public.php?service=files&t=0beb9a41d6ad86fef089fb9f643ff51c Change-Id: Ib5c123ce4e978500fc30cc039a62c590d75b09f7 Signed-off-by: Jorge Ruesga <jorge@ruesga.com>
-rw-r--r--src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java b/src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java
index a38d826..1b87c4f 100644
--- a/src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java
+++ b/src/com/cyanogenmod/trebuchet/AppsCustomizePagedView.java
@@ -383,7 +383,6 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen
// Preferences
mJoinWidgetsApps = PreferencesProvider.Interface.Drawer.getJoinWidgetsApps();
- mVertical = PreferencesProvider.Interface.Drawer.getVertical();
mTransitionEffect = PreferencesProvider.Interface.Drawer.Scrolling.getTransitionEffect(
resources.getString(R.string.config_drawerDefaultTransitionEffect));
mFadeInAdjacentScreens = PreferencesProvider.Interface.Drawer.Scrolling.getFadeInAdjacentScreens();
@@ -427,7 +426,8 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen
@Override
protected void init() {
super.init();
- mCenterPages = false;
+ mVertical = PreferencesProvider.Interface.Drawer.getVertical();
+ mCenterPages = LauncherApplication.isScreenLarge() && mVertical;
Context context = getContext();
Resources r = context.getResources();