summaryrefslogtreecommitdiffstats
path: root/src/com/android/launcher3/dragndrop
diff options
context:
space:
mode:
authorSunny Goyal <sunnygoyal@google.com>2016-09-07 14:39:41 -0700
committerSunny Goyal <sunnygoyal@google.com>2016-09-07 14:40:46 -0700
commitd0d495f5083b5acf93a3de9b28e87d7dcad8f6f4 (patch)
tree4b48fd874642c5b4a2b693ede9e8ca3eb1dcc927 /src/com/android/launcher3/dragndrop
parent9b7149db401959f0c3fc5f6bcb46c5d424858955 (diff)
downloadandroid_packages_apps_Trebuchet-d0d495f5083b5acf93a3de9b28e87d7dcad8f6f4.tar.gz
android_packages_apps_Trebuchet-d0d495f5083b5acf93a3de9b28e87d7dcad8f6f4.tar.bz2
android_packages_apps_Trebuchet-d0d495f5083b5acf93a3de9b28e87d7dcad8f6f4.zip
Preventing concurrentmodification exception when dragging a icon
with shortcuts from inside a folder When dragging the icon, DeepShortcutContainer removes itself as a dragListener causing the exception Change-Id: Ifb2b4a3045caa54aa0b6a9b525055ffdcfaa04a6
Diffstat (limited to 'src/com/android/launcher3/dragndrop')
-rw-r--r--src/com/android/launcher3/dragndrop/DragController.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/com/android/launcher3/dragndrop/DragController.java b/src/com/android/launcher3/dragndrop/DragController.java
index b67d3b8bc..29e33e944 100644
--- a/src/com/android/launcher3/dragndrop/DragController.java
+++ b/src/com/android/launcher3/dragndrop/DragController.java
@@ -260,7 +260,7 @@ public class DragController implements DragDriver.EventListener, TouchController
dragView.show(mMotionDownX, mMotionDownY);
mDistanceSinceScroll = 0;
- for (DragListener listener : mListeners) {
+ for (DragListener listener : new ArrayList<>(mListeners)) {
listener.onDragStart(mDragObject, mOptions);
}