Swipe up on nav bar to go home from -1 and widgets

More specifically, any window (e.g. qsb search) or AbstractFloatingView.

NavBarToHomeTouchController now implements TouchController directly instead
of AbstractStateChangeTouchController, as it not only dealing with
launcher states. This makes it easier to override intercept logic to
handle cases like not having window focus, for example.

AbstractFloatingViews can createHintCloseAnim() to play an animation
hinting that it is about to be closed by swiping up. Widgets sheets use
this to pull back similar to the all apps transition to home.

Bug: 129976669
Change-Id: Ie157b978d9f1ee36d5fd32cea72ec02ce40878c0
This commit is contained in:
Tony Wickham
2019-04-09 10:53:24 -07:00
parent 2a059c7802
commit 9791bd1555
9 changed files with 230 additions and 70 deletions
@@ -162,11 +162,16 @@ abstract class BaseWidgetSheet extends AbstractSlideInView
@Override
public final void logActionCommand(int command) {
Target target = newContainerTarget(ContainerType.WIDGETS);
Target target = newContainerTarget(getLogContainerType());
target.cardinality = getElementsRowCount();
mLauncher.getUserEventDispatcher().logActionCommand(command, target);
}
@Override
public int getLogContainerType() {
return ContainerType.WIDGETS;
}
protected abstract int getElementsRowCount();
protected SystemUiController getSystemUiController() {