summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/ShortcutAndWidgetContainer.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/com/android/launcher3/ShortcutAndWidgetContainer.java')
-rw-r--r--src/com/android/launcher3/ShortcutAndWidgetContainer.java19
1 files changed, 14 insertions, 5 deletions
diff --git a/src/com/android/launcher3/ShortcutAndWidgetContainer.java b/src/com/android/launcher3/ShortcutAndWidgetContainer.java
index 18b9399d1..64a87ef07 100644
--- a/src/com/android/launcher3/ShortcutAndWidgetContainer.java
+++ b/src/com/android/launcher3/ShortcutAndWidgetContainer.java
@@ -92,13 +92,15 @@ public class ShortcutAndWidgetContainer extends ViewGroup {
@Override
protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
int count = getChildCount();
+
+ int widthSpecSize = MeasureSpec.getSize(widthMeasureSpec);
+ int heightSpecSize = MeasureSpec.getSize(heightMeasureSpec);
+ setMeasuredDimension(widthSpecSize, heightSpecSize);
+
for (int i = 0; i < count; i++) {
View child = getChildAt(i);
measureChild(child);
}
- int widthSpecSize = MeasureSpec.getSize(widthMeasureSpec);
- int heightSpecSize = MeasureSpec.getSize(heightMeasureSpec);
- setMeasuredDimension(widthSpecSize, heightSpecSize);
}
public void setupLp(CellLayout.LayoutParams lp) {
@@ -115,8 +117,15 @@ public class ShortcutAndWidgetContainer extends ViewGroup {
final int cellWidth = mCellWidth;
final int cellHeight = mCellHeight;
CellLayout.LayoutParams lp = (CellLayout.LayoutParams) child.getLayoutParams();
-
- lp.setup(cellWidth, cellHeight, mWidthGap, mHeightGap, invertLayoutHorizontally(), mCountX);
+ if (!lp.isFullscreen) {
+ lp.setup(cellWidth, cellHeight, mWidthGap, mHeightGap, invertLayoutHorizontally(),
+ mCountX);
+ } else {
+ lp.x = 0;
+ lp.y = 0;
+ lp.width = getMeasuredWidth();
+ lp.height = getMeasuredHeight();
+ }
int childWidthMeasureSpec = MeasureSpec.makeMeasureSpec(lp.width, MeasureSpec.EXACTLY);
int childheightMeasureSpec = MeasureSpec.makeMeasureSpec(lp.height,
MeasureSpec.EXACTLY);