Minor fixes to stop crashing on panning/dragging on phones.

Change-Id: Ibfc0072d6db039b97876702b2c0577359a7ae567
This commit is contained in:
Winson Chung
2011-01-06 16:25:55 -08:00
parent 4b1c0ba3ac
commit 26cbf3a001
2 changed files with 3 additions and 3 deletions

View File

@@ -474,7 +474,7 @@ public class CellLayout extends ViewGroup implements Dimmable {
// When we're small, we are either drawn normally or in the "accepts drops" state (during
// a drag). However, we also drag the mini hover background *over* one of those two
// backgrounds
if (mBackgroundAlpha > 0.0f) {
if (LauncherApplication.isScreenXLarge() && mBackgroundAlpha > 0.0f) {
Drawable bg;
boolean mini = getScaleX() < 0.5f;

View File

@@ -995,9 +995,9 @@ public final class Launcher extends Activity
final View configureButton = findViewById(R.id.configure_button);
if (LauncherApplication.isScreenXLarge()) {
mDeleteZone.setOverlappingViews(new View[] { allAppsButton, divider, configureButton });
deleteZone.setOverlappingViews(new View[] { allAppsButton, divider, configureButton });
} else {
deleteZone.setOverlappingView(configureButton);
deleteZone.setOverlappingView(findViewById(R.id.all_apps_button_cluster));
}
dragController.addDragListener(deleteZone);