mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-17 01:28:21 +00:00
Merge "Reattach LauncherAppWidgetHostView to its parent after canceling drag" into sc-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
4176cb33bb
@@ -2791,6 +2791,10 @@ public class Workspace extends PagedView<WorkspacePageIndicator>
|
||||
removeWorkspaceItem(mDragInfo.cell);
|
||||
}
|
||||
} else if (mDragInfo != null) {
|
||||
// When drag is cancelled, reattach content view back to its original parent.
|
||||
if (mDragInfo.cell instanceof LauncherAppWidgetHostView) {
|
||||
d.dragView.detachContentView(/* reattachToPreviousParent= */ true);
|
||||
}
|
||||
final CellLayout cellLayout = mLauncher.getCellLayout(
|
||||
mDragInfo.container, mDragInfo.screenId);
|
||||
if (cellLayout != null) {
|
||||
|
||||
Reference in New Issue
Block a user