Adding fling-to-delete.

- Also fixing issue where the drop target icon changes color slower than the text.

Change-Id: I0bfa59da5d202016342f1c3de419ebcafd81ff6f
This commit is contained in:
Winson Chung
2012-03-01 16:09:54 -08:00
parent d1eef3388a
commit 043f2af567
12 changed files with 416 additions and 44 deletions

View File

@@ -16,6 +16,7 @@
package com.android.launcher2;
import android.graphics.PointF;
import android.graphics.Rect;
/**
@@ -91,6 +92,13 @@ public interface DropTarget {
void onDragExit(DragObject dragObject);
/**
* Handle an object being dropped as a result of flinging to delete and will be called in place
* of onDrop(). (This is only called on objects that are set as the DragController's
* fling-to-delete target.
*/
void onFlingToDelete(DragObject dragObject, int x, int y, PointF vec);
/**
* Allows a DropTarget to delegate drag and drop events to another object.
*