Revert "Clear all DragView in onSaveInstanceState"
This reverts commit 14d6771aae2037d5e9bb330f608c4a7e461786d3
to fix bootline regression.
Bug: 210383463
Test: manual
Change-Id: I5a0dadee59bfd6b5a164fd2ca3ecdd1885cb4134
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index ebc0c75..b75b610 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -1681,8 +1681,6 @@
AbstractFloatingView.closeOpenViews(this, false, TYPE_ALL & ~TYPE_REBIND_SAFE);
finishAutoCancelActionMode();
- DragView.removeAllViews(this);
-
if (mPendingRequestArgs != null) {
outState.putParcelable(RUNTIME_STATE_PENDING_REQUEST_ARGS, mPendingRequestArgs);
}
diff --git a/src/com/android/launcher3/dragndrop/DragView.java b/src/com/android/launcher3/dragndrop/DragView.java
index 4588a04..8313571 100644
--- a/src/com/android/launcher3/dragndrop/DragView.java
+++ b/src/com/android/launcher3/dragndrop/DragView.java
@@ -564,19 +564,4 @@
iv.setImageDrawable(drawable);
return iv;
}
-
- /**
- * Removes any stray DragView from the DragLayer.
- */
- public static void removeAllViews(ActivityContext activity) {
- BaseDragLayer dragLayer = activity.getDragLayer();
- // Iterate in reverse order. DragView is added later to the dragLayer,
- // and will be one of the last views.
- for (int i = dragLayer.getChildCount() - 1; i >= 0; i--) {
- View child = dragLayer.getChildAt(i);
- if (child instanceof DragView) {
- dragLayer.removeView(child);
- }
- }
- }
}