diff options
author | vadimt <vadimt@google.com> | 2019-07-16 16:19:58 -0700 |
---|---|---|
committer | vadimt <vadimt@google.com> | 2019-07-16 16:46:53 -0700 |
commit | 6a75e52f85c751b4b2832c312abd09e7812611e2 (patch) | |
tree | ad5808d385c03302b3b04534542aa8ccd9dc8ef2 /quickstep/src/com/android/launcher3/uioverrides/touchcontrollers | |
parent | d3bff6043aca5d7fc97e947805ca7c17178fbc68 (diff) | |
download | android_packages_apps_Trebuchet-6a75e52f85c751b4b2832c312abd09e7812611e2.tar.gz android_packages_apps_Trebuchet-6a75e52f85c751b4b2832c312abd09e7812611e2.tar.bz2 android_packages_apps_Trebuchet-6a75e52f85c751b4b2832c312abd09e7812611e2.zip |
Getting starting point of swipe from overview to all apps via protocol
Change-Id: Idf04579b67011dac45b081a81367cde2d1274117
Diffstat (limited to 'quickstep/src/com/android/launcher3/uioverrides/touchcontrollers')
-rw-r--r-- | quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/PortraitStatesTouchController.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/PortraitStatesTouchController.java b/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/PortraitStatesTouchController.java index 6030cea93..109d751c4 100644 --- a/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/PortraitStatesTouchController.java +++ b/quickstep/src/com/android/launcher3/uioverrides/touchcontrollers/PortraitStatesTouchController.java @@ -51,7 +51,6 @@ import com.android.quickstep.OverviewInteractionState; import com.android.quickstep.RecentsModel; import com.android.quickstep.TouchInteractionService; import com.android.quickstep.util.LayoutUtils; -import com.android.systemui.shared.system.QuickStepContract; /** * Touch controller for handling various state transitions in portrait UI. @@ -296,9 +295,13 @@ public class PortraitStatesTouchController extends AbstractStateChangeTouchContr * @return true if the event is over the hotseat */ static boolean isTouchOverHotseat(Launcher launcher, MotionEvent ev) { + return (ev.getY() >= getHotseatTop(launcher)); + } + + public static int getHotseatTop(Launcher launcher) { DeviceProfile dp = launcher.getDeviceProfile(); int hotseatHeight = dp.hotseatBarSizePx + dp.getInsets().bottom; - return (ev.getY() >= (launcher.getDragLayer().getHeight() - hotseatHeight)); + return launcher.getDragLayer().getHeight() - hotseatHeight; } private static class InterpolatorWrapper implements Interpolator { |