Merge "Updating layout of search buttons" into honeycomb
diff --git a/res/drawable/wallpaper_picker_preview.png b/res/drawable-hdpi/wallpaper_picker_preview.png
similarity index 63%
rename from res/drawable/wallpaper_picker_preview.png
rename to res/drawable-hdpi/wallpaper_picker_preview.png
index 926a99c..300ea4a 100644
--- a/res/drawable/wallpaper_picker_preview.png
+++ b/res/drawable-hdpi/wallpaper_picker_preview.png
Binary files differ
diff --git a/res/drawable/wallpaper_picker_preview.png b/res/drawable-mdpi/wallpaper_picker_preview.png
similarity index 63%
copy from res/drawable/wallpaper_picker_preview.png
copy to res/drawable-mdpi/wallpaper_picker_preview.png
index 926a99c..300ea4a 100644
--- a/res/drawable/wallpaper_picker_preview.png
+++ b/res/drawable-mdpi/wallpaper_picker_preview.png
Binary files differ
diff --git a/res/drawable-xlarge-mdpi/homescreen_large_blue_strong.9.png b/res/drawable-xlarge-mdpi/homescreen_large_blue_strong.9.png
deleted file mode 100644
index f4913e5..0000000
--- a/res/drawable-xlarge-mdpi/homescreen_large_blue_strong.9.png
+++ /dev/null
Binary files differ
diff --git a/src/com/android/launcher2/CellLayout.java b/src/com/android/launcher2/CellLayout.java
index 9c629ee..c105c36 100644
--- a/src/com/android/launcher2/CellLayout.java
+++ b/src/com/android/launcher2/CellLayout.java
@@ -84,7 +84,6 @@
private float mBackgroundAlphaMultiplier = 1.0f;
private Drawable mNormalBackground;
- private Drawable mNormalGlowBackground;
private Drawable mActiveBackground;
private Drawable mActiveGlowBackground;
private Drawable mNormalBackgroundMini;
@@ -169,7 +168,6 @@
if (LauncherApplication.isScreenXLarge()) {
mNormalBackground = res.getDrawable(R.drawable.homescreen_large_blue);
- mNormalGlowBackground = res.getDrawable(R.drawable.homescreen_large_blue_strong);
mActiveBackground = res.getDrawable(R.drawable.homescreen_large_green);
mActiveGlowBackground = res.getDrawable(R.drawable.homescreen_large_green_strong);
@@ -179,7 +177,6 @@
mActiveGlowBackgroundMini = res.getDrawable(R.drawable.homescreen_small_green_strong);
mNormalBackground.setFilterBitmap(true);
- mNormalGlowBackground.setFilterBitmap(true);
mActiveBackground.setFilterBitmap(true);
mActiveGlowBackground.setFilterBitmap(true);
mNormalBackgroundMini.setFilterBitmap(true);
@@ -308,6 +305,9 @@
if (scaleFactor != mGlowBackgroundScale) {
mGlowBackgroundScale = scaleFactor;
updateGlowRect();
+ if (getParent() != null) {
+ ((View) getParent()).invalidate();
+ }
}
}
@@ -380,8 +380,8 @@
bg = mini ? mActiveBackgroundMini : mActiveGlowBackground;
} else if (mIsDragOccuring && mAcceptsDrops) {
bg = mini ? mActiveBackgroundMini : mActiveBackground;
- } else if (mIsDragOccuring && mIsDefaultDropTarget) {
- bg = mini ? mNormalGlowBackgroundMini : mNormalGlowBackground;
+ } else if (mIsDefaultDropTarget && mini) {
+ bg = mNormalGlowBackgroundMini;
} else {
bg = mini ? mNormalBackgroundMini : mNormalBackground;
}
diff --git a/src/com/android/launcher2/Launcher.java b/src/com/android/launcher2/Launcher.java
index 59d52ef..966f2e7 100644
--- a/src/com/android/launcher2/Launcher.java
+++ b/src/com/android/launcher2/Launcher.java
@@ -1148,10 +1148,7 @@
final int[] cellXY = mTmpAddItemCellCoordinates;
final CellLayout layout = (CellLayout) mWorkspace.getChildAt(screen);
- int[] touchXY = null;
- if (mAddDropPosition != null && mAddDropPosition[0] > -1 && mAddDropPosition[1] > -1) {
- touchXY = mAddDropPosition;
- }
+ int[] touchXY = mAddDropPosition;
boolean foundCellSpan = false;
if (touchXY != null) {
// when dragging and dropping, just find the closest free spot
@@ -1196,13 +1193,7 @@
// if we are placing widgets on a "spring-loaded" screen
final int[] cellXY = mTmpAddItemCellCoordinates;
- // For now, we don't save the coordinate where we dropped the icon because we're not
- // supporting spring-loaded mini-screens; however, leaving the ability to directly place
- // a widget on the home screen in case we want to add it in the future
- int[] touchXY = null;
- if (mAddDropPosition != null && mAddDropPosition[0] > -1 && mAddDropPosition[1] > -1) {
- touchXY = mAddDropPosition;
- }
+ int[] touchXY = mAddDropPosition;
boolean foundCellSpan = false;
if (touchXY != null) {
// when dragging and dropping, just find the closest free spot
diff --git a/src/com/android/launcher2/Workspace.java b/src/com/android/launcher2/Workspace.java
index e7fb0fd..fd90b06 100644
--- a/src/com/android/launcher2/Workspace.java
+++ b/src/com/android/launcher2/Workspace.java
@@ -125,7 +125,6 @@
private int mDefaultPage;
- private boolean mPageMoving = false;
private boolean mIsDragInProcess = false;
/**
@@ -549,7 +548,6 @@
enableChildrenCache(mCurrentPage - 1, mCurrentPage + 1);
}
showOutlines();
- mPageMoving = true;
}
protected void onPageEndMoving() {
@@ -560,7 +558,6 @@
}
mOverScrollMaxBackgroundAlpha = 0.0f;
mOverScrollPageIndex = -1;
- mPageMoving = false;
}
@Override