Fixing issue with cancelled drag blocking cell spaces (Issue 5386523)

Change-Id: I9cfc728edeeee2237c21935517107e7a2af49646
This commit is contained in:
Adam Cohen
2011-09-29 17:33:15 -07:00
parent 57e1beecac
commit 36cc09b07b
3 changed files with 7 additions and 0 deletions
@@ -361,6 +361,7 @@ public class DragController {
if (mLastDropTarget != null) {
mLastDropTarget.onDragExit(mDragObject);
}
mDragObject.cancelled = true;
mDragObject.dragComplete = true;
mDragObject.dragSource.onDropCompleted(null, mDragObject, false);
}
@@ -52,6 +52,9 @@ public interface DropTarget {
/** Post drag animation runnable */
public Runnable postAnimationRunnable = null;
/** Indicates that the drag operation was cancelled */
public boolean cancelled = false;
public DragObject() {
}
}
+3
View File
@@ -3051,6 +3051,9 @@ public class Workspace extends SmoothPagedView
}
cellLayout.onDropChild(mDragInfo.cell);
}
if (d.cancelled && mDragInfo.cell != null) {
mDragInfo.cell.setVisibility(VISIBLE);
}
mDragOutline = null;
mDragInfo = null;
}