Commit Graph

1335 Commits

Author SHA1 Message Date
Sunny Goyal
dedda05568 Using a proxy activity for startActivityForResult
This ensures that the home task is never blocked by a different task

Bug: 74500048
Change-Id: I01fd26f1d6242e39b2d8fabac5e064b748aebe62
2019-05-15 16:33:06 -07:00
Jon Miranda
ffaca2e162 Fix landscape app open/close animations.
Bug: 123900446
Bug: 124510042
Change-Id: I3db80d6f8064ce26f97cdede63c0d25499416e98
2019-05-15 10:46:33 -07:00
Winson Chung
3658d9fa0c Merge "Preemptively clear the thumbnail cache as tasks are removed" into ub-launcher3-qt-dev 2019-05-14 20:48:47 +00:00
Hyunyoung Song
e751d90c44 Implement 3 shades of folder icon/container fill color
Bug: 130451254

Change-Id: I36d885a2b0247f1bb84cb98073459853ae723331
2019-05-14 10:15:11 -07:00
Winson Chung
cb554473c7 Preemptively clear the thumbnail cache as tasks are removed
- Also reset the task thumbnail as the task views are recycled

Bug: 132309376

Change-Id: Ic2cc846e451b6b59ae76326930cb4b85627e95c4
2019-05-13 16:22:10 -07:00
Tony
8312866779 Use device profile width instead of drag layer width for overview translation
This fixes the issue where overview doesn't come in from offscreen
the first time you enter overview from home.

Test:
- Force stop launcher, quick switch from home
- Force stop launcher, swipe up and hold

Change-Id: Ia4dbd36267008bc199cff088833979606238d3eb
2019-05-13 14:11:51 -05:00
Jonathan Miranda
57730ed095 Merge "Initial app open/close polish using tuned values." into ub-launcher3-qt-dev 2019-05-10 17:30:46 +00:00
Jon Miranda
2da1da3076 Initial app open/close polish using tuned values.
* Rect and radius now match the app window size.

Bug: 124510042
Bug: 122843905
Change-Id: Ibc85bfe1d75d01cefe00b6bf32557e04a0ee4716
2019-05-10 10:11:35 -07:00
Tony
918863083b Add ScreenPinnedInputConsumer
When screen pinning is active, swipe up and hold to stop it.

Bug: 130828539
Change-Id: I343050d2a224ac723143cd3be4f78bc321f1a026
2019-05-09 18:10:10 -05:00
Kevin
141ab952e7 Ensure Recents Go layout finishes before remote anim begins
We would like to assume a correct up-to-date layout for Go recents
before the remote animation begins to ensure correctness of the app to
overview transition and allow for animating all the newly laid out task
views in sync.

We do this by checking if recents is the remote target we are animating
to and if so, checking if the view is ready.  If it is not, then we
delay the remote animation until the layout is finished and everything
is attached.

Bug: 132112131
Fix: 132108983
Test: Run Recents Go, have no tasks in recents, open app, press
overview to go to recents
Test: Test on AOSP and NexusLauncher that animations to Launcher work as
before (both to recents and to home)
Change-Id: Id74d90cffc9fe5db1dbb5fe63b8819c7436fef21
2019-05-07 15:05:39 -07:00
Sunny Goyal
ae6e318711 Initial changes to creating a fake landscape Launcher UI
Workspace and hotseat are drawn in rotated UI giving the impression that the
device is in Portrait, even though it is in landscape

Bug: 131360075
Change-Id: I29c4068af25fd4dcf7039b9a45886e864a137977
2019-05-02 10:59:28 -07:00
vadimt
8649cf29e4 Remove tracing for fixed bugs
Bug: 129434166
Bug: 131170582
Change-Id: Ia9b356594001d96c69ffbb7f8b767b2f54ed5feb
2019-05-01 16:10:56 -07:00
Jon Miranda
063211f620 Fix app open animation in landscape.
Bug: 130828765
Change-Id: Ic447d05a8fe2097a6afd0bfec73039a62bbf5a4b
2019-04-30 12:03:39 -07:00
Sunny Goyal
0382dd76e8 Releasing SurfaceControl when they are no longer needed
Bug: 123874711
Change-Id: I9c06723a3e5d4a23b8a6c60352806bb12daba598
2019-04-29 12:04:11 -07:00
Matthew Ng
06e0d80d15 Added back code removed earlier from OverviewInterationState
Change: ag/7199900

Test: manual
Fixes: 129497226
Change-Id: Ibf0b1d4ade8ef5a2f0ceb545df505e9de419ec50
(cherry picked from commit cad531248e)
2019-04-26 18:00:12 +00:00
Tony Wickham
0cc53e7f6a Merge "Decouple recents view from window while swiping up" into ub-launcher3-qt-dev 2019-04-26 00:10:34 +00:00
Matthew Ng
b60dce7268 Remove interaction flag code replaced by QuickStepContract (1/2)
Test: manual
Bug: 112934365
Fixes: 129497226
Change-Id: Id128eee4eaa620f0b9c461ef5adf0a16e9ea9a2c
2019-04-25 23:01:12 +00:00
Hyunyoung Song
efe8475093 Merge "Add important dump logging Bug: 130851537 Bug: 119992316" into ub-launcher3-qt-dev 2019-04-25 22:33:31 +00:00
Hyunyoung Song
a310a80c7b Add important dump logging
Bug: 130851537
Bug: 119992316

Change-Id: I3de7c1d910d1aecd80b47a85284565c79fe0e2cc
2019-04-25 15:14:44 -07:00
Tony Wickham
4f24370f72 Pass correct value to updatePaused() in setDisallowPause()
Change-Id: Iabc3a3aac85bcf426ab18437e006cc95fa89fbc0
2019-04-24 18:20:23 -07:00
Tony
5c13972e11 Decouple recents view from window while swiping up
Add setRecentsAttachedToWindow(boolean attached, boolean animate) with
the following conditions:

Conditions for attached
- Motion is paused and shelf is peeking
- xDisplacement > yDisplacement (to ensure seamless quick switch)
- We are continuing the previous quick switch gesture
- Gesture has ended and endTarget is RECENTS or NEW_TASK

Conditions for animate
- Recents is visible. Since the running task is invisible, this is
  true if either an adjacent TaskView is visible, or if we’re
  continuing the previous gesture

Currently the attach/detatch animation is just fading recents in/out.

Test:
- Swipe up to go home does not show the recents list at all. Instead,
  all the visuals/motion focus on the app window animating into the
  home screen.
- Recents appears when swiping and holding, to indicate that letting
  go will land in recents. The shelf also appears with haptic feedback
  in this case to reinforce this.
- The next task is immediately visible when quick switching (swiping
  left to right on the nav bar).

Bug: 129985827
Change-Id: Ib0c16f583bfd5b02d2f9f68c9688edc980a39d75
2019-04-24 17:36:42 -07:00
Tony Wickham
d0d39f1769 Merge "Move logic that overrides MotionPauseDetector to callers" into ub-launcher3-qt-dev 2019-04-25 00:34:47 +00:00
Hyunyoung Song
bf44bc342f Fix NPE / add downX,Y location for all swipes/ add extra debugging info
Bug: 122700646
Bug: 127840207

Change-Id: I5862c8950565df172a933114e1fb2f9c4575593e
2019-04-24 16:16:51 -07:00
Tony
bbea105be0 Move logic that overrides MotionPauseDetector to callers
There are 2 conditions that we force the MotionPauseDetector to treat
the motion as not paused:
1. If we haven't passed a small displacement (48dp before, 36dp now)
2. If we have moved mostly orthogonally

These existed soley for the OtherActivityInputConsumer case, because
1. We only need the displacement requirement to make room for the
   peeking shelf, which doesn't exist in other cases (it's already there on
   home for example)
2. We can only move orthogonally for quick switch, which again doesn't
   exist for other users of MotionPauseDetector.

So now instead of checking min displacement and orthogonal distance
inside MotionPauseDetector, we let callers setDisallowPause()
before adding positions to their MotionPauseDetector.

The only user visible change is that you no longer have to swipe up 48dp
before we allow pause to overview from home. This also paves the way to
using the same logic that determines to disallowPause to also detach
recents from the window while swiping up from an app.

Bug: 129985827
Change-Id: Ie690aa314da3260aff2209341a29638604f9501c
2019-04-24 16:10:40 -07:00
TreeHugger Robot
b31b38c942 Merge "Adding support for showing predicted apps as a floating row in all-apps and overview" into ub-launcher3-qt-dev 2019-04-23 21:47:38 +00:00
Sunny Goyal
77b3419ad5 Adding support for showing predicted apps as a floating row in all-apps
and overview

Bug: 130053407
Change-Id: Idb93a0ba6cfea8406f75ab86d9e0acde2fc04b3a
2019-04-23 14:26:44 -07:00
Tony Wickham
12e8a34ef6 Move system gesture exclusion rect to LauncherRootView
We translate DragLayer when going to -1, so the exclusion rect was off
screen when you went back from there.

Bug: 129297464
Change-Id: Ie079b2dadaca07886408ee9c1d130d7ac351a61d
2019-04-23 11:52:50 -07:00
Sunny Goyal
8b0cb4113f Listening only for "android" package for overlay changes
Bug: 130917995
Change-Id: I37160a886a0afdc02dca8f7da6e8aa54c795882d
2019-04-22 09:02:08 -07:00
Miranda Kephart
6b31012350 Merge "Don't shrink overview bitmap for chips" into ub-launcher3-qt-dev 2019-04-19 18:10:40 +00:00
vadimt
7d90c653d6 More diagnostics for dragging failures in the lab, now for OOP tests
Bug: 129434166
Change-Id: I38b62ef74c0307f12ee85bbc05940400e9ba2302
2019-04-15 12:10:50 -07:00
Miranda Kephart
73a4740f7f Don't shrink overview bitmap for chips
Chips in overview will be shown on top of the bitmap, not in
between the bitmap and the QSB, so we no longer need to shrink
the bitmap to make room for chips. This means that the appearance
of the recents view will be consistent between chips being
enabled/disabled.

Change-Id: I1856ccb8babd388ef6c8e6a1a5defcbdd0278a60
2019-04-12 11:09:59 -04:00
Tony Wickham
8e5c13f360 Track window for 2 button nav as well as 0 button
This allows us to revert the change that fades in the shelf during swipe
up in 2 button mode, since the shelf doesn't show up until the window is
out of the way anyway.

Bug: 129746879
Change-Id: I929d8095989f9eae32d71b5bc3f67997e9df4ba0
2019-04-10 15:36:07 -07:00
Tony Wickham
5dc60a0543 Add some egregious back exclusion rects
- Don't allow back gesture at all whenever we hid back button before
- Exclude RecyclerViewFastScroller thumb rect

Bug: 129297464
Change-Id: I40a33697592b02619218c18d1b3def7c3c203f56
2019-04-09 18:28:43 -07:00
Tony Wickham
e2e953304f Allow swipe up to all apps anywhere on workspace
Bug: 129033091
Change-Id: Ib0066c59f86b3137aedad8d18393b5a622e0cd80
2019-04-09 12:23:01 -07:00
Hyunyoung Song
2aec9c42f5 Change task view / all apps/ widgets / folder radius to dialogCornerRadius
Bug: 123985787
Change-Id: Iaa8088beb51d37dba90d57ad065f9eac0dd46270
2019-04-09 00:27:07 +00:00
Sunny Goyal
c7cc3dc2c5 Removing unnecessary corner size caching in RecentsModel
Change-Id: I1be87dc15a3b9ec8225dccce701bff19785658d6
2019-04-05 15:11:42 -07:00
Sunny Goyal
9e84e0c1c1 Removing SWIPE_HOME flag and using sysUI mode instead
Bug: 129873705
Change-Id: Ieaa7d7928427daed98538c616bdf58b28d295829
2019-04-03 17:02:36 -07:00
Sunny Goyal
65f2396ecd Merge "Adds the ability for Launcher3 to respond to QSB alpha change requests." into ub-launcher3-master 2019-04-03 20:20:12 +00:00
TreeHugger Robot
7da5bbeb71 Merge "Add logging for assistant gesture" into ub-launcher3-master 2019-04-03 19:54:20 +00:00
TreeHugger Robot
01ec89a2ac Merge "Use motion event time instead of system time when detecting motion pause" into ub-launcher3-master 2019-04-03 19:43:27 +00:00
Hyunyoung Song
ebc5f82ac5 Add logging for assistant gesture
Bug: 129867977
Change-Id: I6254bf06b7352f6076af229a581d4ebdd584a4a1
2019-04-03 12:31:42 -07:00
Tony
1274c7a3dc Use motion event time instead of system time when detecting motion pause
Bug: 129337684
Change-Id: Ie6e54658bf86094fbd9b6a8098e5ff147aafbfa7
2019-04-03 12:28:55 -07:00
Govinda Wasserman
24e489e5a3 Adds the ability for Launcher3 to respond to QSB alpha change requests.
Test: Tested locally
BUG:124063782
Change-Id: I8c4bfaa62d9608fcfffff5e30b2913f3a6fb2f75
(cherry picked from commit 827f0807d3)
2019-04-03 17:33:55 +00:00
Jon Miranda
bba6451b5f Refactor app open animation so that FloatingIconView tracks window.
Before, the window used to track the FloatingIconView. With this refactor,
both app open and app close use the same update method.

With the refactor, we can now use adaptive icons to morph the icon into the
size of the window.

Movement/interpolators are still the same as the original except for the
alpha and the clip animation. To ensure a perfect tradeoff, we wait for the
icon to match the size and shape of the window before crossfading.
Currently it is set up so that the tradeoff happens when the animation is
15% done, but this can be tuned later.

Bug: 122843905

Change-Id: I7d3edbefffb15fe26958a62ab33cf23dc1203908
2019-04-01 13:19:28 -07:00
Hyunyoung Song
1ac6c84bda Add the config constant to SysUINavigationMode class
Bug: 128348746

Change-Id: I369e70bbd038ff0f75def83cadd98efce3f39385
2019-03-29 14:33:29 -07:00
TreeHugger Robot
7f5083b7af Merge "Making navigation mode listener a singleton so that the change is dispatched everywhere synchronously." into ub-launcher3-master 2019-03-29 18:05:24 +00:00
TreeHugger Robot
5996842fa3 Merge "Removing unused instant apps methods" into ub-launcher3-master 2019-03-29 17:25:10 +00:00
Sunny Goyal
5743f8635b Making navigation mode listener a singleton so that the change is dispatched
everywhere synchronously.

Change-Id: Iee8c5957d78dfad3fb03e814de0367adcaa0c98b
2019-03-29 09:36:45 -07:00
Tony
e4c2e2b86c Add QuickSwitchTouchController on home
- Added QuickSwitchState, which we animate to when swiping right
  on the nav bar from NORMAL state
- Task launches when the state transition to QuickSwitchState ends

Bug: 126596417
Change-Id: Id66650401d817703fc6d044fb26a25cccbc07e11
2019-03-28 15:09:25 -05:00
Tony
101807d8e7 Fix SwipeDetector positive vs negative for HORIZONTAL direction
Previously left was considered positive and right considered negative.
Now left and down are negative, and right and up are positive.

For RTL, left is positive and right is negative.

Change-Id: Ia31e8c687c8c2716fc632b2fe88aa8955b934bce
2019-03-27 19:45:04 -05:00