Commit Graph

124 Commits

Author SHA1 Message Date
Evan Rosky
c12b7355b1 Fix NPE that happens occasionally on start-up
Was not checking if topActivity was null.

Bug: 189935087
Test: boot phone thousands of times.
Change-Id: I3c779be5f09d82d52a3df9478c801a1963e0a5c2
2021-08-31 15:10:47 -07:00
shawnlin
4e15fe0726 [DO NOT MERGE] Update QuickStepContract.getWindowCornerRadius API
Update from getWindowCornerRadius(Resources) to
getWindowCornerRadius(Context)

Bug: 131221697
Test: make
Change-Id: Ia5f10e9292e205dab7e69d97dfc82d17690816fb
2021-08-19 15:52:10 +08:00
TreeHugger Robot
fe5ce7334a Merge "New app animation specs." into sc-qpr1-dev am: 686d42a1d4
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15587964

Change-Id: If21b096b1d5ac025ffb4116c805d31acba6cc662
2021-08-19 00:57:46 +00:00
Jon Miranda
bda98de9f8 New app animation specs.
- New values and interpolators.

Bug: 173107751
Test: open apps from different parts of the home screen
Change-Id: I81bec0221aec9c04dac0bb3e926c879999699e57
2021-08-18 18:26:46 +00:00
Andy Wickham
13f3ffed95 Adds initial Taskbar Edu implementation.
Currently it just pops up with one placeholder image for splitscreen.
The Next button doesn't do anything.

Screenshots:
Light: https://screenshot.googleplex.com/B27CwBcwobHTghN.png
Dark: https://screenshot.googleplex.com/48EuJZv8evd5RGW.png

Known issues:
 - Back gesture is picked up behind by the app behind the taskbar.
 - When the flag is enabled, the Edu shows up each time you open
   an app, rather than only the first time.

Bug: 180605356
Test: Manual
Change-Id: Ifba9aa59abf1501b5f8ddebb3fcc13df85f6efaa
2021-08-17 09:57:47 -07:00
Tony Wickham
635e180e56 Extend taskbar color to entire screen in overview
Only when taskbar is unstashed in apps:
- Scrim workspace with the taskbar color when opening apps and in BackgroundAppState
- Crop opening apps to above the taskbar
- Crop TaskViews to above the taskbar during gestures

If taskbar is stashed in apps, behavior is the same as before, i.e. no scrim over the wallpaper and no cropping of tasks.

Added a field DeviceProfile#taskbkarPresentInApps to distinguish these cases. LauncherTaskbarUIController and TaskbarStashController ensure this value is set appropriately.

Test: Ensure tasks don't appear behind taskbar when it's unstashed; set ENABLE_SCRIM_FOR_APP_LAUNCH = true to test the whole screen scrimming when opening an app

Bug: 196257194
Fixes: 190681228
Change-Id: I481501457a5a6d49c380feea3db3b4058e4cf3f8
2021-08-16 16:50:52 -07:00
Evan Rosky
8fb6c2156b Part of fixing Splashcreen cts tests
This passes the launcher component name into the transition filter
so that it only matches if the launcher is the current home activity

Bug: 194112093
Test: atest SplashscreenTests
Change-Id: Ie2185545a5bef8b317e104b6ac878f6cde0d7350
2021-07-20 14:23:55 -07:00
Jonathan Miranda
e6f0509d1d Merge "Fix bug where app icon is gone for first frame on cold start." into sc-dev am: 3334c32120
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15164770

Change-Id: I38ace4adec4591e9259a8859ed547e1b951b922c
2021-07-01 18:36:20 +00:00
Jonathan Miranda
3334c32120 Merge "Fix bug where app icon is gone for first frame on cold start." into sc-dev 2021-07-01 18:34:47 +00:00
Jon Miranda
17cc821c28 Fix bug where app icon is gone for first frame on cold start.
We need the icon to be full alpha during the init pass, then when
the actual animation starts, we can swap the icon with the window
(splash screen that draws the icon).

Bug: 192366079
Test: slow down window animations
      check no empty frame on cold start app launch
      check no empty frame on warm start app launch

Change-Id: I16a1779e5252d8e88bc3c408e1dc40b264fe4cf4
2021-07-01 00:11:41 +00:00
Lucas Dupin
3fb19d41b6 Merge "Decouple zooms and blurs on app launch" into sc-dev am: c2ef0363af
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15145970

Change-Id: Idadf9a85d4de92e584a524ff48856cca5c81d664
2021-06-30 00:25:43 +00:00
Lucas Dupin
0f00c35268 Decouple zooms and blurs on app launch
We'd like to be able to disable blurs during app launch, but without
disabling zooms as well. The previous sysprop would set the depth of
BackgroundAppState to 0, when what we want is to conserve wallpaper
zoom.

Bug: 191969790
Test: adb shell setprop ro.launcher.blur.appLaunch false
Change-Id: Ie4b26096f6ac723c3981bba2829557e6cc6c733b
2021-06-29 13:02:12 -07:00
Lucas Dupin
820b0987bd Merge "Reset DEPTH at the end of launch animations" into sc-dev am: 789f01af7e
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15130116

Change-Id: I5d4b3c70bf2201831ed25405083eaf6de1bdf92f
2021-06-28 22:28:34 +00:00
Lucas Dupin
789f01af7e Merge "Reset DEPTH at the end of launch animations" into sc-dev 2021-06-28 22:15:21 +00:00
Lucas Dupin
9d8580bd2a Reset DEPTH at the end of launch animations
This way the wallpaper won't be zoomed out if an app crashes.

Test: adb am crash <some test app>
Fixes: 191979512
Change-Id: I7576798f736d63c3e46bbac1b983b9d1a437647d
2021-06-28 11:45:14 -07:00
Vadim Tryshev
e3f02c4de6 Merge "Postponing CUJ start by 1 frame" into sc-dev am: e70e6a3b0b
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15096971

Change-Id: Iaedc20bb98781ad97b8f72e064cb47e77e7f2975
2021-06-26 15:10:04 +00:00
Vadim Tryshev
e70e6a3b0b Merge "Postponing CUJ start by 1 frame" into sc-dev 2021-06-25 17:56:34 +00:00
vadimt
ca383ffdf5 Postponing CUJ start by 1 frame
for CUJ_APP_LAUNCH_FROM_ICON, CUJ_APP_CLOSE_TO_HOME,
CUJ_APP_LAUNCH_FROM_WIDGET and CUJ_APP_LAUNCH_FROM_RECENTS

Test: Local perfetto run
Bug: 190858586
Change-Id: I7a26d91c44a0a4c767bde3230d39a096a26d7b75
2021-06-24 11:44:57 -07:00
Sunny Goyal
9ffb0f803b Merge "Fixing TaskView.launchTask.onEndCallback is not called" into sc-dev am: eb3367796a
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15032513

Change-Id: I0b76512550814f23fde9c95a59e90e50280e3dde
2021-06-22 18:20:46 +00:00
Sunny Goyal
696c612964 Fixing TaskView.launchTask.onEndCallback is not called
Sometimes onAnimaitonCancelled can be called without onCreate. Calling
onEnd in this case so that the sate is cleared

Removing additional subclassing for the runner

Bug: 190856140
Test: Manual
Change-Id: If105cb343cab446a4eac90a45184ce50c6e4c485
2021-06-21 16:06:40 -07:00
Jonathan Miranda
94df55bada Merge "Fix bug where workspace alpha does not get set to 1 when animation gets cancelled." into sc-dev am: f9df8f3682
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15023032

Change-Id: I9ab72caa407fd3e6a2e6130bcf9e924ba2c7726c
2021-06-20 22:59:04 +00:00
Jon Miranda
651abb9924 Fix bug where workspace alpha does not get set to 1 when animation gets cancelled.
- Can also remove QSB from app launch animator, since its in the hotseat now.

Bug: 189458349
Test: manual
Change-Id: Ib41376e3f8c58166c6ee6fbfed38bdd443663df4
2021-06-18 15:39:36 -07:00
Jonathan Miranda
c01e87daf0 Merge "Add ENABLE_SCRIM_FOR_APP_LAUNCH feature flag." into sc-dev am: 28e39335bc
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14987185

Change-Id: Iecfbdc781852e24aafb92744f9a3de4ff5cbbd00
2021-06-16 20:39:08 +00:00
Jon Miranda
b73e591712 Add ENABLE_SCRIM_FOR_APP_LAUNCH feature flag.
Bug: 191088291
Test: manual
Change-Id: Ia144c72e0fe1292ed856a37ee714a1cda50083d5
2021-06-16 18:13:23 +00:00
Jonathan Miranda
620c7d1854 resolve merge conflicts of bea8267854 to sc-v2-dev
Bug: 181901105
Change-Id: I4bbe6258e0d2e5f04931d2a3d8d1f784a90f91de
Merged-In: Ia904b8b96301042c900e0589f33fc625c1c1148b
2021-06-15 02:32:30 +00:00
Jon Miranda
0750f03c96 Address LAUNCHER_APP_LAUNCH_FROM_ICON jank.
- Delay app launch animations by a frame, and skip logic to skip the first frame.
- Note the icon pressed state animation still occurs, so there is still some
  visual feedback for the user that something is happening.

Bug: 181901105
Test: ensure animation still looks smooth (using window animation scale & record in slow mo)
Change-Id: Ia904b8b96301042c900e0589f33fc625c1c1148b
Merged-In: Ia904b8b96301042c900e0589f33fc625c1c1148b
2021-06-14 23:29:29 +00:00
Cyrus Boadway
801dbf90c4 Merge "Use the splash screen background color as the fallback background color" into sc-dev am: 3616f29f83
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14881306

Change-Id: I5ad3b65fb0e74ca77e37aa9bea590f82519283a0
2021-06-12 17:27:27 +00:00
Cyrus Boadway
9f06168692 Use the splash screen background color as the fallback background color
For the widget transition animation fallback background color, use either
the splash screen background color if a task is starting or the task
description-attached background color.

With a background in place, allow the window to fully fade out before
fading in the widget, by moving the window alpha math into an animation
factory-specific implementation.

Bug: 187706750
Test: Manual
Change-Id: I2b5a7783b0585d447ad60534bc48d2e2176877ed
2021-06-10 21:03:24 +00:00
Wei Sheng Shih
e909a01164 Merge "Read the starting surface icon size from framework" into sc-dev am: 630efccd7a
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14609921

Change-Id: I7e9b8813fea7d2ed9cdef8c163f65875c9f026c1
2021-06-03 06:49:47 +00:00
Wei Sheng Shih
630efccd7a Merge "Read the starting surface icon size from framework" into sc-dev 2021-06-02 10:00:22 +00:00
Lucas Dupin
c53c5d8599 Merge "Set blur on effect layer during app launch" into sc-dev am: ee4d67c52d
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14750658

Change-Id: Ibc67ff5638774294801974e4fe3c6357bf4ee22c
2021-06-02 00:38:36 +00:00
Lucas Dupin
ee4d67c52d Merge "Set blur on effect layer during app launch" into sc-dev 2021-06-02 00:32:52 +00:00
Jonathan Miranda
121587eb13 Merge "Update launcher content animation to spec." into sc-dev am: cdc73b512e
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14757888

Change-Id: If73328d6c5a4827052ff0d7652c5002ccfc5d365
2021-06-01 19:52:05 +00:00
Lucas Dupin
6e50860616 Set blur on effect layer during app launch
Test: manual
Fixes: 189207458
Change-Id: I8fabba92c6831c2fd54fe08156fc9a9b5d141a56
2021-06-01 11:07:17 -07:00
Jon Miranda
5df1fa5031 Update launcher content animation to spec.
- Scales content
- Fades in scrim

Bug: 177264697
Test: manual
Change-Id: Ie60908b6c417d94f1e075ea9728bd48eea55083e
2021-05-27 22:21:30 -07:00
Evan Rosky
a7b9f89e5b Merge "Fix launcher-in-transition-targets detection" into sc-v2-dev 2021-05-26 01:06:36 +00:00
Sunny Goyal
c4c3269206 Crossfading splashscreen if icon is themed
Bug: 188840653
Test: Manual
Change-Id: Ibd00bb1a94576a7512872eba39a936c174f9871d
2021-05-25 18:25:18 +00:00
Evan Rosky
e902918a31 Fix launcher-in-transition-targets detection
Shell transitions promotes animation up to root task so
we can't compare to leaf-taskid derived from ActivityRecord.getTaskId
since home tasks are all children of a root and thus aren't
organized.

This replaces the task-id check with a componentname check.

Bug: 172695387
Test: with shell transit enabled, launch an app from launcher
      and observer launcher content animating.
Change-Id: Ieeca72b57ec47c9cbe15e635f5026b53edebd0ad
2021-05-25 10:22:54 -07:00
shawnlin
3380ab3053 Support the nav animation in widget launch remote animation
Launcher now support remote animation for widget but doesn't add the nav
animation for this type of animation.

Add the nav animation in widget launch remote animation in launcher.

Bug: 185303414
Test: manual - launch a widget in launcher and observe the nav bar
Change-Id: I11f4bd75b9624118b8ffef09c99f54fc7f1fbbca
2021-05-25 03:43:25 +00:00
Sunny Goyal
d5500548dc Revert^2 "Moving taskbar lifecycle to TouchInteractionService"
430465a3d5
Bug: 187353581
Change-Id: I7b2280d16adfafd3e85ffc1d22e32d0c00d12b67
2021-05-21 07:05:02 +00:00
Kholoud Mohamed
430465a3d5 Revert "Moving taskbar lifecycle to TouchInteractionService"
This reverts commit e215fb730b.

Reason for revert: DroidMonitor-triggered revert due to breakage https://android-build.googleplex.com/builds/tests/view?invocationId=I13700009003387451&testResultId=TR89423459137251402, bug https://buganizer.corp.google.com/issues/188755902

Bug: 188755902
Change-Id: I4650136975b60f311499ee6ff5b27ab9a32d23d6
2021-05-20 13:32:05 +01:00
wilsonshih
1bcb9d94ce Read the starting surface icon size from framework
Bug: 177264697
Test: Manual verify icon size on splash screen.
Change-Id: Iec6b0c519cf4692ac6851911ed1e21a3c1b752b4
2021-05-19 19:29:03 +08:00
Sunny Goyal
5bb515b6cc Merge "Moving taskbar lifecycle to TouchInteractionService" into sc-dev 2021-05-18 17:17:27 +00:00
Sunny Goyal
e215fb730b Moving taskbar lifecycle to TouchInteractionService
> Inflating taskbar views with a non-launcher window context
> Removing separate taskbar view in Launcher
> Handling taskbar icon clicks directly instead of going via launcher
> Fixing some relayouts during show/hide animation

Bug: 187353581
Test: Manual
Change-Id: Ia7d44acbb770bf0345922234b3daa5cc040a5843
2021-05-17 21:47:08 -07:00
Jon Miranda
7d2dfcfb3f Add WorkspaceRevealAnim, successor to StaggeredWorkspaceAnim.
- Added support for widgets for the new close animation.
- This anim is used with the new app close.
- This anim is not compataible with the old app close, so we need to
  keep StaggeredWorkspaceAnim in case we turn the app close flag off.

- We will also use this anim in the lockscreen to launcher anim, will
  connect them in a follow up CL.

Bug: 188413065
Bug: 173107751
Test: manual
Change-Id: Icab3fd700f2c268bb1c4509a37466e4e6748f789
2021-05-17 23:04:07 +00:00
Cyrus Boadway
a27ebc1633 Merge "Add interaction jank monitoring for widget app launch CUJ" into sc-dev 2021-05-14 17:40:16 +00:00
Cyrus Boadway
670473301a Improve widget-activity transition animation for translucent activities
Activities may be translucent. In that case, the widget should not
visually be a part of the activity launch or return animations.

Bug: 169042867
Test: manual
Change-Id: Ifb690672f71854e491fa240a6c7f0d882910a47c
2021-05-12 11:47:33 +00:00
Sunny Goyal
5996937798 Removing Launcher dependency from Folders
This allows opening/closing folders without a Launcher context

Bug: 187353581
Test: Manual
Change-Id: Id73a40445a23004eb554f0422d286aa0ff6b3c41
2021-05-10 14:01:43 -07:00
Cyrus Boadway
e2ea1f3f33 Add interaction jank monitoring for widget app launch CUJ
Instrument the widget app launch animation with interaction jank monitoring.

Bug: 169042867
Test: presubmit
Change-Id: Icc9c7cceee7950272fa5d58e0a2f18efc022ce69
2021-05-07 13:29:11 +00:00
Cyrus Boadway
1c5ddff010 Remove widget launch CUJ from jank monitoring
The widget launch animation should not be measured with the icon launch
animations. No widget launch CUJ yet exists, so no jank monitoring
should be applied to widget app launches.

Bug: 169042867
Test: manual
Change-Id: I2a525c42cca8dd17c4a96bde7f11b14cfe87cabc
2021-05-07 09:38:40 +00:00