Launcher-side changes to support prediction bar.

Change-Id: Ib9974ad8888ad87137c774f9f531fae9d56b899a
This commit is contained in:
Winson Chung
2015-04-29 11:03:24 -07:00
parent d47d90224a
commit cd99cd3ed6
7 changed files with 73 additions and 49 deletions

View File

@@ -269,19 +269,8 @@ public class AppsContainerView extends FrameLayout implements DragSource, Insett
// Start the drag
mLauncher.getWorkspace().beginDragShared(v, mLastTouchPos, this, false);
// We delay entering spring-loaded mode slightly to make sure the UI
// thready is free of any work.
postDelayed(new Runnable() {
@Override
public void run() {
// We don't enter spring-loaded mode if the drag has been cancelled
if (mLauncher.getDragController().isDragging()) {
// Go into spring loaded mode (must happen before we startDrag())
mLauncher.enterSpringLoadedDragMode();
}
}
}, 150);
// Enter spring loaded mode
mLauncher.enterSpringLoadedDragMode();
return false;
}