diff options
author | Winson Chung <winsonc@google.com> | 2013-08-26 22:08:09 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2013-08-26 22:08:09 +0000 |
commit | 6c15a644cb72df32edb62489f272c4aefe711e8a (patch) | |
tree | e3b7b40300ff757ad23c1b2f621d06d191b4414a /src/com/android/launcher3/Workspace.java | |
parent | cc07e7a9c6e383f35a8de717be71201f666b01a8 (diff) | |
parent | 892c74d460ad98c6306420e1127c9aa3e505ba25 (diff) | |
download | android_packages_apps_Trebuchet-6c15a644cb72df32edb62489f272c4aefe711e8a.tar.gz android_packages_apps_Trebuchet-6c15a644cb72df32edb62489f272c4aefe711e8a.tar.bz2 android_packages_apps_Trebuchet-6c15a644cb72df32edb62489f272c4aefe711e8a.zip |
Merge "Fixing folders to always show in view, removing old assets and references to LauncherModel count." into jb-ub-gel-agar
Diffstat (limited to 'src/com/android/launcher3/Workspace.java')
-rw-r--r-- | src/com/android/launcher3/Workspace.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/com/android/launcher3/Workspace.java b/src/com/android/launcher3/Workspace.java index 3aaee178c..2218023b4 100644 --- a/src/com/android/launcher3/Workspace.java +++ b/src/com/android/launcher3/Workspace.java @@ -2532,6 +2532,8 @@ public class Workspace extends SmoothPagedView Point smallestSize = new Point(); Point largestSize = new Point(); display.getCurrentSizeRange(smallestSize, largestSize); + int countX = (int) grid.numColumns; + int countY = (int) grid.numRows; if (orientation == CellLayout.LANDSCAPE) { if (mLandscapeCellLayoutMetrics == null) { Rect padding = grid.getWorkspacePadding(CellLayout.LANDSCAPE); @@ -2539,7 +2541,7 @@ public class Workspace extends SmoothPagedView int height = smallestSize.y - padding.top - padding.bottom; mLandscapeCellLayoutMetrics = new Rect(); CellLayout.getMetrics(mLandscapeCellLayoutMetrics, width, height, - LauncherModel.getCellCountX(), LauncherModel.getCellCountY()); + countX, countY); } return mLandscapeCellLayoutMetrics; } else if (orientation == CellLayout.PORTRAIT) { @@ -2549,7 +2551,7 @@ public class Workspace extends SmoothPagedView int height = largestSize.y - padding.top - padding.bottom; mPortraitCellLayoutMetrics = new Rect(); CellLayout.getMetrics(mPortraitCellLayoutMetrics, width, height, - LauncherModel.getCellCountX(), LauncherModel.getCellCountY()); + countX, countY); } return mPortraitCellLayoutMetrics; } |