Prevent flicker when starting a drag.
Also, animate item the view to its new position when dragging.
diff --git a/src/com/android/launcher2/DragController.java b/src/com/android/launcher2/DragController.java
index 2b566b7..a0a44a5 100644
--- a/src/com/android/launcher2/DragController.java
+++ b/src/com/android/launcher2/DragController.java
@@ -320,6 +320,13 @@
DragView dragView = mDragView = new DragView(mContext, b, registrationX, registrationY,
textureLeft, textureTop, textureWidth, textureHeight);
+ final DragSource dragSource = source;
+ dragView.setOnDrawRunnable(new Runnable() {
+ public void run() {
+ dragSource.onDragViewVisible();
+ };
+ });
+
if (dragRegion != null) {
dragView.setDragRegion(dragRegionLeft, dragRegion.top,
dragRegion.right - dragRegionLeft, dragRegion.bottom - dragRegionTop);