summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichael Jurka <mikejurka@google.com>2011-06-03 14:43:36 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2011-06-03 14:43:36 -0700
commit4a78ec342d2ae2cec110bfe685459985fe4a1175 (patch)
treef75bde9b5bb2bf8ff08f037aeaac697bf34a086f /src
parentdcfc25ca5f5dd3f867e929e34605564162128b45 (diff)
parentb82cc0cc9b61eef0670dc7fddc53813455ca2f4d (diff)
downloadandroid_packages_apps_Trebuchet-4a78ec342d2ae2cec110bfe685459985fe4a1175.tar.gz
android_packages_apps_Trebuchet-4a78ec342d2ae2cec110bfe685459985fe4a1175.tar.bz2
android_packages_apps_Trebuchet-4a78ec342d2ae2cec110bfe685459985fe4a1175.zip
am b82cc0cc: am 1fd2c158: am 32271c3d: Tweak calculation for number of columns and rows
* commit 'b82cc0cc9b61eef0670dc7fddc53813455ca2f4d': Tweak calculation for number of columns and rows
Diffstat (limited to 'src')
-rw-r--r--src/com/android/launcher2/CellLayout.java11
1 files changed, 2 insertions, 9 deletions
diff --git a/src/com/android/launcher2/CellLayout.java b/src/com/android/launcher2/CellLayout.java
index f189cd58e..154b2a05f 100644
--- a/src/com/android/launcher2/CellLayout.java
+++ b/src/com/android/launcher2/CellLayout.java
@@ -271,13 +271,10 @@ public class CellLayout extends ViewGroup {
// We use this method from Workspace to figure out how many rows/columns Launcher should
// have. We ignore the left/right padding on CellLayout because it turns out in our design
// the padding extends outside the visible screen size, but it looked fine anyway.
- // However, we make sure there's at least enough space for the crosshairs at either
- // edge to be rendered (half the crosshair is sticking out on either side)
int cellWidth = r.getDimensionPixelSize(R.dimen.workspace_cell_width);
int widthGap = r.getDimensionPixelSize(R.dimen.workspace_width_gap_port);
- int crosshairsSize = r.getDrawable(R.drawable.gardening_crosshairs).getIntrinsicWidth();
- return widthGap * (numCells - 1) + cellWidth * numCells + crosshairsSize;
+ return widthGap * (numCells - 1) + cellWidth * numCells;
}
static int widthInLandscape(Resources r, int numCells) {
@@ -311,14 +308,10 @@ public class CellLayout extends ViewGroup {
// We use this method from Workspace to figure out how many rows/columns Launcher should
// have. We ignore the left/right padding on CellLayout because it turns out in our design
// the padding extends outside the visible screen size, but it looked fine anyway.
- // However, we make sure there's at least enough space for the crosshairs at the bottom
- // to be rendered (half the crosshair is sticking out); we don't worry about the top
- // crosshair since it can bleed into the action bar space
int cellHeight = r.getDimensionPixelSize(R.dimen.workspace_cell_height);
int heightGap = r.getDimensionPixelSize(R.dimen.workspace_height_gap_land);
- int crosshairsSize = r.getDrawable(R.drawable.gardening_crosshairs).getIntrinsicHeight();
- return heightGap * (numCells - 1) + cellHeight * numCells + (crosshairsSize + 1) / 2;
+ return heightGap * (numCells - 1) + cellHeight * numCells;
}
public void enableHardwareLayers() {