summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorWinson Chung <winsonc@google.com>2011-07-29 14:19:47 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-07-29 14:19:47 -0700
commitfda77c1d268a7cdc73fe77de63212d4c3a0b13c8 (patch)
tree6ff133a383465da28439fa928de6bd7f3a2739c5 /src
parent4afe9b31f51022538b30646fe83780e83bf22490 (diff)
parent72d8b393b03f9decba05b0797608ccdc751fecef (diff)
downloadandroid_packages_apps_Trebuchet-fda77c1d268a7cdc73fe77de63212d4c3a0b13c8.tar.gz
android_packages_apps_Trebuchet-fda77c1d268a7cdc73fe77de63212d4c3a0b13c8.tar.bz2
android_packages_apps_Trebuchet-fda77c1d268a7cdc73fe77de63212d4c3a0b13c8.zip
Merge "Removing use of deprecated constants in GridLayout."
Diffstat (limited to 'src')
-rw-r--r--src/com/android/launcher2/AppsCustomizePagedView.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/com/android/launcher2/AppsCustomizePagedView.java b/src/com/android/launcher2/AppsCustomizePagedView.java
index d07b321df..cb60034ac 100644
--- a/src/com/android/launcher2/AppsCustomizePagedView.java
+++ b/src/com/android/launcher2/AppsCustomizePagedView.java
@@ -39,6 +39,7 @@ import android.os.AsyncTask;
import android.os.Process;
import android.util.AttributeSet;
import android.util.Log;
+import android.view.Gravity;
import android.view.LayoutInflater;
import android.view.MotionEvent;
import android.view.View;
@@ -943,10 +944,11 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen
int ix = i % cellCountX;
int iy = i / cellCountX;
GridLayout.LayoutParams lp = new GridLayout.LayoutParams(
- GridLayout.spec(iy, GridLayout.LEFT, GridLayout.CAN_STRETCH),
- GridLayout.spec(ix, GridLayout.TOP, GridLayout.CAN_STRETCH));
+ GridLayout.spec(iy, GridLayout.LEFT),
+ GridLayout.spec(ix, GridLayout.TOP));
lp.width = cellWidth;
lp.height = cellHeight;
+ lp.setGravity(Gravity.TOP | Gravity.LEFT);
if (ix > 0) lp.leftMargin = mWidgetWidthGap;
if (iy > 0) lp.topMargin = mWidgetHeightGap;
layout.addView(widget, lp);