summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/widget
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2017-10-06 13:29:57 -0700
committerSunny Goyal <sunnygoyal@google.com>2017-10-16 13:06:52 -0700
commit1797af41d162413dc98c33fab8ba19f96b63874b (patch)
treea9003b1952e98db0ec53dab673e00499e46bb6f7 /src/com/android/launcher3/widget
parentcbdfc598fae13f5aa7f7263351872d160004fbe7 (diff)
downloadandroid_packages_apps_Trebuchet-1797af41d162413dc98c33fab8ba19f96b63874b.tar.gz
android_packages_apps_Trebuchet-1797af41d162413dc98c33fab8ba19f96b63874b.tar.bz2
android_packages_apps_Trebuchet-1797af41d162413dc98c33fab8ba19f96b63874b.zip
Cleaning up drag state management.
When the drag is started, the UI automatically goes into spring loaded mode. On a successful drop, it is the responsibility of the {@link DropTarget} to exit out of the spring loaded mode. If the drop was cancelled for some reason, the UI will automatically exit out of this mode. Bug: 34692289 Change-Id: Ic611739a43bb8d9279b587aaee3039326c143e8b
Diffstat (limited to 'src/com/android/launcher3/widget')
-rw-r--r--src/com/android/launcher3/widget/BaseWidgetSheet.java16
1 files changed, 1 insertions, 15 deletions
diff --git a/src/com/android/launcher3/widget/BaseWidgetSheet.java b/src/com/android/launcher3/widget/BaseWidgetSheet.java
index ee5dd66bd..b6b3089b0 100644
--- a/src/com/android/launcher3/widget/BaseWidgetSheet.java
+++ b/src/com/android/launcher3/widget/BaseWidgetSheet.java
@@ -159,21 +159,7 @@ abstract class BaseWidgetSheet extends AbstractFloatingView
//
@Override
- public void onDropCompleted(View target, DragObject d, boolean isFlingToDelete,
- boolean success) {
- if (isFlingToDelete || !success || (target != mLauncher.getWorkspace() &&
- !(target instanceof DeleteDropTarget) && !(target instanceof Folder))) {
- // Exit spring loaded mode if we have not successfully dropped or have not handled the
- // drop in Workspace
- mLauncher.exitSpringLoadedDragModeDelayed(true,
- Launcher.EXIT_SPRINGLOADED_MODE_SHORT_TIMEOUT, null);
- }
- mLauncher.unlockScreenOrientation(false);
-
- if (!success) {
- d.deferDragViewCleanupPostAnimation = false;
- }
- }
+ public void onDropCompleted(View target, DragObject d, boolean success) { }
@Override