Commit Graph

1812 Commits

Author SHA1 Message Date
Vinit Nayak
39cc356a53 Merge "Start quickswitch on task switch instead of touch down" into ub-launcher3-rvc-dev 2020-06-01 20:32:14 +00:00
TreeHugger Robot
0e1cbf56aa Merge "Reset Overview layout after swiping to home" into ub-launcher3-rvc-dev 2020-06-01 19:24:54 +00:00
Vinit Nayak
acd2f58693 Start quickswitch on task switch instead of touch down
Previously we would enter a quickswitch session state
whenever user tapped on navbar and sent flags to
sysui to only enable edge gesture for the current rotation.
Now we only do that on a new task resulting from the gesture
or when going into recents to show nav bar in the
orientation user would expect it (only if they never
quickswitched).

Fixes: 155844780
Test: Tested swiping back from quickswitching
into apps of different orientations.
Note that back is still broken when you
quickswitch and then rotate the foreground app.

Change-Id: I935e7c66489d46e59156414d64653c846ae4c5d8
2020-06-01 12:06:47 -07:00
Hyunyoung Song
2911c56a80 Merge "Migrate launcher home settings button tap/longpress logging to WW" into ub-launcher3-rvc-dev 2020-06-01 18:08:39 +00:00
Vinit Nayak
90b006dbe5 Reset Overview layout after swiping to home
Reset overview when user does a swipe to home
gesture. Preivously we only rest when user
first when to over, and then swiped to home.

Fixes: 156053957
Change-Id: I5a157f9e2229aba4b36851bd46d704a39d647110
2020-06-01 10:40:05 -07:00
TreeHugger Robot
7149a7e0c5 Merge "Removes unused constant" into ub-launcher3-rvc-dev 2020-06-01 16:50:30 +00:00
TreeHugger Robot
8a3be8cb53 Merge "Don't defer finish, only defer disableInputProxy" into ub-launcher3-rvc-dev 2020-05-30 00:41:06 +00:00
Tony Wickham
cc558e86fb Don't defer finish, only defer disableInputProxy
We should always finish the controller when requested, to ensure
everything is cleaned up immediately. But if touch is in progress,
we should keep input proxy enabled until touch up/cancel.

Test: swipe up to launcher and interact with it during the transition
- Swipe to recents and scroll it or dismiss the current task
- Swipe to home and open another app or swipe again on the nav bar

Bug: 157771305
Change-Id: Ida53289e4ecbd5e5d16933fcc79bbebdf1f8d898
2020-05-29 19:04:48 -05:00
Hyunyoung Song
b117a9221c Migrate launcher home settings button tap/longpress logging to WW
Bug: 157777128
Change-Id: Ic88811efc9aef8f38a0e7e5ae79e3b35236c6663
2020-05-29 17:03:22 -07:00
Jonathan Miranda
02f0f82883 Merge "Fix depth jumping around during transitions." into ub-launcher3-rvc-dev 2020-05-29 22:31:54 +00:00
Andy Wickham
f8a8117676 Animates a fake TaskView in Home gesture tutorial.
The "TaskView" morphs as you drag up from the
nav bar, and transforms into a "home icon" or
final "TaskView" when you release your finger.

If you cancel the gesture (e.g. drag back down),
the view simply fades out and provides a hint
to swipe straight up.

Demo: https://drive.google.com/open?id=1NXlO1W6IhLoX0k2K6b-QZ5IXp0o7OYqO

Bug: 148542211
Change-Id: I3d5e9a45fcadc6a498941ea17813b9487720a504
2020-05-29 14:06:36 -07:00
Andy Wickham
7e78e63d50 Removes unused constant
Change-Id: Ic3d96ae3791ba75c5ce6c1c00203bf9d21469fe5
2020-05-29 13:49:09 -07:00
Jon Miranda
84f6e0182e Fix depth jumping around during transitions.
This is caused because we use mDepth for depth comparisons, but there are
cases where we set mDepth but we do not pass that value to WallpaperManager
(ie. surface is null or not valid) and that leads us into
inconsistent states.

Bug: 155780358
Change-Id: I3faf14416d5783ad472892425eb0bd37dd469a46
2020-05-29 13:06:55 -07:00
Tony Wickham
b4d75d2931 Merge "Don't run finish callback until we actually finish" into ub-launcher3-rvc-dev 2020-05-28 17:18:09 +00:00
TreeHugger Robot
938fccd3da Merge "Move content resolver call to constructor and cache" into ub-launcher3-rvc-dev 2020-05-28 05:55:42 +00:00
Tony Wickham
5cf9edc1f2 Don't run finish callback until we actually finish
This fixes the issue where the app re-appears on top if you touch
the nav bar during the animation to home.

The sequence of events leading to this behavior is pretty long,
but actually always should have happened, it was just masked
until the ag/11172732 fix went in.

Here's an abbreviated version of what was happening
on the touch down during the animation to home:
1 Set mRecentsAnimationController#mTouchInProgress = true
2 Cancel the running animation to home
3 onSettledOnEndTarget(HOME) (this is what was missing before)
4 finishCurrentTransitionToHome(), which, due to #1, doesn't
  actually finish the controller, but does run the callback
5 Invalidate the handler due to #4, leading to TIS#reset()
6 Create a new handler (still from the original touch down),
  which is mResetGestureInputConsumer
7 mResetGestureInputConsumer handles touch down to finish
  the controller the app

This change addresses #4. Instead of calling the callback
immediately, we defer it to when we actually finish the
controller, which ensures there's no longer premature
cleanup that leads to the rest of the sequence.

Bug: 157407284
Change-Id: I0b2ff57bfa77a25c2bf1aece4b0ae7f943637ce6
2020-05-27 19:26:16 -05:00
thiruram
c85095b0e9 Fixes missing WW logs for drag and drop events.
Change-Id: I31f8aa132d70b42c3b8213daf0bbd5c555cf3895
2020-05-27 16:35:14 -07:00
Hyunyoung Song
cf0e79916d Merge "use LauncherAtom.ItemInfo.getDefaultInstance inside StatsLogManager" into ub-launcher3-rvc-dev 2020-05-27 21:29:54 +00:00
Sunny Goyal
a314d5ad58 Updating swipe up on home animations
> Scaling down home activity on swipe-up from home and spring back to place on cancel
> Fading out recents on swipe-up to home, so ensure that adjecent tiles also dissapear
> Instead of controlling alpha, controlling full transform for base and home task. This allows adding custom animation for home task on swipe up.
> Removing alpha hanging for fallback activity in baseSwipeHandler. Instead controlling full transform for home activity
> Adding feature flag to use QuickstepLauncher as 3P Launcher to make development easier.

Bug: 156398988
Change-Id: I69cc59f2c9c95d15df6926ba635e7d6c251dceb6
2020-05-27 19:49:46 +00:00
Vinit Nayak
281193e996 Move content resolver call to constructor and cache
Changing fixed rotation enabled system setting flag
should be followed by a restart of launcher for it
to take effect.

Bug: 149571513
Change-Id: I84fbb654c325076571a038604fa929984d22f254
2020-05-27 12:21:40 -07:00
TreeHugger Robot
37a7d2af42 Merge "Keep recents attached to app window on continued switching" into ub-launcher3-rvc-dev 2020-05-27 18:07:11 +00:00
Hyunyoung Song
a451508818 use LauncherAtom.ItemInfo.getDefaultInstance inside StatsLogManager
Bug: 153611516
Change-Id: I8531df7ee61c336c9919f5ff137bb1e113c126ea
2020-05-27 09:59:04 -07:00
Vinit Nayak
c217c72bcc Merge "Maintain fake nav bar position in overview for landscape" into ub-launcher3-rvc-dev 2020-05-21 20:59:25 +00:00
Vinit Nayak
c609421f2a Maintain fake nav bar position in overview for landscape
NavBar defaults to display when quickswitch ends,
which is always portrait since home is now always
in portrait. We keep the same nav region that the
user used to swipe up to enter recents and reset once
they swipe to home.

Fixes: 156053957
Test: Swipe up from landscape app, then swipe up
from the same nav bar region to go home.

Change-Id: Ia4cf8172850b991aa5e145897622be3b2afa3779
2020-05-21 11:24:16 -07:00
Tony Wickham
17312c3566 Keep recents attached to app window on continued switching
- LAST_TASK now has recentsAttachedToAppWindow = true, to match
  NEW_TASK. Though this does mean there's a small chance of
  seeing recents translating in if you swipe up and back down,
  this is preferable to seeing recents translate away if you
  swipe right and back left in two consecutive gestures.
- Until passing the touch slop for a new gesture, keep recents
  attached to the app window. This avoids cases where you
  could have recents view translate away mid-gesture, such as
  in the following case: swipe from A to B, swipe from B back
  to A, touch down during the transition back to A. Before this
  change, you would see recents translate away; with this
  change, recents instead stays in place until we get another
  signal indicating it should detach, such as swiping to home.

Bug: 157153404
Change-Id: I63a3a8b988af1aac5177f101b0b75e73e56b1ceb
2020-05-21 00:55:54 -05:00
Tony Wickham
c7c883a880 Update some TouchInteractionService logs
- Move "finishRecentsAnimation" for NEW_TASK to where we actally
  finish the controller after onTaskAppeared()
- Add "setEndTarget" and "onSettledOnEndTarget" logs

Bug: 156412706
Change-Id: I0a0f81d3b601fc1eed72b372235bbb92368ec246
2020-05-20 14:30:31 -05:00
Jon Miranda
517cec5344 Add all apps education tutorial.
* Added FeatureFlag.ENABLE_ALL_APPS_EDU
* When user swipes up on nav bar three times and goes to hint state
  consecutively, we show the new All Apps education tutorial.
* For now we block interaction while the animation is playing,
  and we remove the view when the animation is done.
* Future CL will leave view up until user successfully reaches All Apps state.

Bug: 151768994
Change-Id: I903e0a3914d0558950ecb8cd714d97ddc10ca06b
2020-05-20 11:44:23 -07:00
Sunny Goyal
672d02cd39 Unifying swipe handling for fallback launcher
Previosuly we had a different swipe handler for 3P Launcher which
started either recents or Launcher based on the initial interaction
(horizontal or vertical). This was primarily because we had to wait
for recents transition to finish before starting another activity
which could delay going to home.

Now we always start recents transition to recentsActivity. This allows
us to use the same swipe handling logic as QuickstepLauncher. Home
activity can be started while recents transition is running and can be
controlled using onTaskAppeared callback.

Bug: 156924169
Bug: 156398988
Bug: 156295255
Change-Id: Ib9f02e0281e8d674bde2f4a81eca5fc8a5962144
2020-05-19 19:41:30 -07:00
TreeHugger Robot
a41f9dcbe9 Merge "More logging for swiping to Overview instead of All Apps" into ub-launcher3-rvc-dev 2020-05-19 21:04:20 +00:00
Vinit Nayak
a8f083b581 Merge "Increase overview thumbnail size for 2 button landscape." into ub-launcher3-rvc-dev 2020-05-19 20:49:08 +00:00
vadimt
f95cfce267 More logging for swiping to Overview instead of All Apps
Bug: 156095088
Change-Id: Ia4d59b43225c7652cfc0ae72c05a5477deeb842b
2020-05-19 12:49:17 -07:00
Vinit Nayak
88830c0657 Increase overview thumbnail size for 2 button landscape.
With shelf hidden in 2 button landscape, need to fill
in the extra space w/ larger thumbnail.

Fixes: 156442623
Test: Larger thumbnail shows up in 2 button landscape
Change-Id: Ie2856c8d248b28ae7c06cbe40c7417a827c2bd96
2020-05-19 12:07:37 -07:00
Vinit Nayak
4ae95beb9b Merge "Override Rect#contains() to include bottom right" into ub-launcher3-rvc-dev 2020-05-18 22:21:55 +00:00
TreeHugger Robot
d5315f8c29 Merge "Using taskView simulator for animation a task to recentsView" into ub-launcher3-rvc-dev 2020-05-18 19:02:30 +00:00
Vinit Nayak
08619f8600 Merge "Hide shelf in 2-Button Landscape" into ub-launcher3-rvc-dev 2020-05-17 23:32:00 +00:00
Vinit Nayak
23681083b2 Hide shelf in 2-Button Landscape
Disable overview rotation in 2-Button.

Fixes: 154181816
Test: Tested no button and 2 button,
overview actions worked as before.

Change-Id: Ic22c791c7a93460840d54aaf0bf32884cc110e19
2020-05-17 15:17:11 -07:00
Tony Wickham
39f2f1029b Log last appeared task id instead of target
Might be slightly more useful (e.g. if we
need to compare against last started task id)

Change-Id: I3617be270bec6841fbd943e681de78ada549ff84
2020-05-15 16:32:04 -05:00
Sunny Goyal
b9abae9f0f Using taskView simulator for animation a task to recentsView
Also applying transform params in DeviceLockedInputConsumer directly
instead of going through AppWindowAnimationHelper

Bug: 156398988
Bug: 155816922
Change-Id: I791e1a9feb07c4fb787130f8d040a4f404faf734
2020-05-15 14:07:29 -07:00
Vinit Nayak
9c62e18660 Remove debug logs, root cause found.
Bug: 146964271
Change-Id: I38ed3b4b1a90fa1ff9a3aa4bb5547300ddd92358
2020-05-15 10:04:51 -07:00
Vinit Nayak
c40352ef8c Override Rect#contains() to include bottom right
In landscape, the lowest coordinate touch registered
is the actual lowest pixel possible by the screen.
For portrait/seascape the lowest coordinate
is (lowest pixel possible - 1). The difference of the
one pixel makes Rect#contains() return false since
only top left Rect points are inclusive and bottom
right points are exclusive.

Fixes: 156333291
Test: Always able to smoothly go to overview from
landscape.

Change-Id: I6beddad99ae076a167d2a5f5e5acc6e466bff544
2020-05-14 17:26:15 -07:00
James O'Leary
4cb77a60aa Merge "Compose gesture integrated fully into Launcher" into ub-launcher3-rvc-dev 2020-05-14 20:20:13 +00:00
James O'Leary
74a2746b35 Compose gesture integrated fully into Launcher
- Support dismissing Compose via the reverse gesture from the appear
gesture
- Use Tony Wickham's ag/10204761 with some glue code to enable the
app below Compose panning in the same direction as the gesture as
Compose peeks in
- Add feature flag to use Compose hosted in a window (permits underlying
app panning)
- Use InterpolatingVelocityTracker to fix OtherActivityInputConsumer
processing swipes in the wrong direction ~20% of the time due to a bug
in VelocityTracker (see go/quirky-bubbles)

Change-Id: I3adbaee1763f21557fb628b60d03b0a03e7079ab
2020-05-14 14:18:19 -04:00
Winson Chung
034ce6fd94 Update shelf offset earlier when in gesture nav
- Provide a hint to Launcher to indicate it will be resumed when
  swiping home, which allows us to notify sysui before any potential
  pip invocation, reducing the likelyhood of two conflicting animations
  when entering pip

Bug: 156637223
Change-Id: Iae773e1aac88bbea6f74e1d1332417b448126471
2020-05-14 10:55:14 -07:00
Sunny Goyal
d9c0349c1a Merging WindowSizeStrategy with BaseActivityInterface
Also converting BaseActivityInterface to an abstract class instead of interface
so that it can hold member variables

Change-Id: I04cab934137eb1d6f470c6a7618c50a2ed2c71c1
2020-05-14 01:22:25 -07:00
thiruram
b9080c2a15 Add support to log LauncherEvent without ItemInfo.
Change-Id: I145a9500b0442c2b5d9f7f691460465b2bb13a07
2020-05-13 22:58:23 +00:00
Sunny Goyal
f190fd2d4e Build fix. Unifying task size calculation code.
Change-Id: Iaed3a28a9e74c39da8d01aa42b30c96bdb69a661
2020-05-13 14:06:07 -07:00
TreeHugger Robot
e0fef877e4 Merge "Changing RecentsView layout based on the split screen task size" into ub-launcher3-rvc-dev 2020-05-13 18:35:05 +00:00
TreeHugger Robot
d893a478a3 Merge "Adds Settings button back to Back gesture tutorial." into ub-launcher3-rvc-dev 2020-05-13 18:34:37 +00:00
Becky Qiu
dc48fc4f84 [Overview Actions] Adjust the select mode taskview UI.
It will have a 30dp horizontal paddings and vertically in the middle of the screen.

Test: local
Bug: 155444014

Change-Id: I4f3d627008b2c114cc4921bf683919c6044926e4
2020-05-13 18:23:28 +00:00
Andy Wickham
ee1203e436 Adds Settings button back to Back gesture tutorial.
Uses a simpler Intent which actually works :)

Fixes: 149348244
Bug: 148542211
Change-Id: I5e28c63d1eec93b4642e398c7532e7ec4809d6e2
2020-05-13 10:48:38 -07:00