Loading quickstep/src/com/android/launcher3/WidgetPickerActivity.java +7 −2 Original line number Diff line number Diff line Loading @@ -194,6 +194,11 @@ public class WidgetPickerActivity extends BaseActivity { return false; } View dragView = widgetCell.getDragAndDropView(); if (dragView == null) { return false; } ClipData clipData = new ClipData( new ClipDescription( /* label= */ "", // not displayed anywhere; so, set to empty. Loading @@ -209,9 +214,9 @@ public class WidgetPickerActivity extends BaseActivity { .putExtra(EXTRA_IS_PENDING_WIDGET_DRAG, true)); // DRAG_FLAG_GLOBAL permits dragging data beyond app window. return view.startDragAndDrop( return dragView.startDragAndDrop( clipData, new View.DragShadowBuilder(view), new View.DragShadowBuilder(dragView), /* myLocalState= */ null, View.DRAG_FLAG_GLOBAL ); Loading src/com/android/launcher3/widget/WidgetCell.java +7 −0 Original line number Diff line number Diff line Loading @@ -372,6 +372,13 @@ public class WidgetCell extends LinearLayout { } } /** * Returns a view (holding the previews) that can be dragged and dropped. */ public View getDragAndDropView() { return mWidgetImageContainer; } public WidgetImageView getWidgetView() { return mWidgetImage; } Loading Loading
quickstep/src/com/android/launcher3/WidgetPickerActivity.java +7 −2 Original line number Diff line number Diff line Loading @@ -194,6 +194,11 @@ public class WidgetPickerActivity extends BaseActivity { return false; } View dragView = widgetCell.getDragAndDropView(); if (dragView == null) { return false; } ClipData clipData = new ClipData( new ClipDescription( /* label= */ "", // not displayed anywhere; so, set to empty. Loading @@ -209,9 +214,9 @@ public class WidgetPickerActivity extends BaseActivity { .putExtra(EXTRA_IS_PENDING_WIDGET_DRAG, true)); // DRAG_FLAG_GLOBAL permits dragging data beyond app window. return view.startDragAndDrop( return dragView.startDragAndDrop( clipData, new View.DragShadowBuilder(view), new View.DragShadowBuilder(dragView), /* myLocalState= */ null, View.DRAG_FLAG_GLOBAL ); Loading
src/com/android/launcher3/widget/WidgetCell.java +7 −0 Original line number Diff line number Diff line Loading @@ -372,6 +372,13 @@ public class WidgetCell extends LinearLayout { } } /** * Returns a view (holding the previews) that can be dragged and dropped. */ public View getDragAndDropView() { return mWidgetImageContainer; } public WidgetImageView getWidgetView() { return mWidgetImage; } Loading