Fixed 3066306 Widget measurement wrong in customize tray

This commit is contained in:
Michael Jurka
2010-10-08 16:58:12 -07:00
parent 4516c11039
commit 9987a5c45e
2 changed files with 8 additions and 3 deletions
@@ -624,8 +624,10 @@ public class CustomizePagedView extends PagedView
l.setOnLongClickListener(this);
final Drawable icon = getWidgetIcon(info);
final int hSpan = mWorkspaceWidgetLayout.estimateCellHSpan(info.minWidth);
final int vSpan = mWorkspaceWidgetLayout.estimateCellHSpan(info.minHeight);
int[] spans = CellLayout.rectToCell(getResources(), info.minWidth, info.minHeight, null);
final int hSpan = spans[0];
final int vSpan = spans[1];
ImageView image = (ImageView) l.findViewById(R.id.widget_preview);
image.setMaxWidth(mMaxWidgetWidth);