Commit Graph

5341 Commits

Author SHA1 Message Date
Tracy Zhou
9d706b1ada Fix failed test in order to enable Live Tile (in the next change)
Live tile changes certain assumptions we have for tests, for example
- Launcher will not be in the resumed state after swiping up to Overview

Also, disable live tile for 3rd party launcher for now

Test: presubmit
Fixes: 169694902
Change-Id: Ifd466db0354f59290c4f66a0a2ad4c82f1169f29
2021-03-25 19:44:36 -07:00
Tracy Zhou
29c1e8437e Merge "Fix a memory leak" into sc-dev 2021-03-25 16:48:46 +00:00
Alex Chau
5d225245b6 Merge "Fix taskbar crash after cleanup" into sc-dev 2021-03-25 11:28:55 +00:00
Alex Johnston
ad4c83ad36 Merge "Block recent work profile apps content capture" into sc-dev 2021-03-25 09:14:05 +00:00
Tracy Zhou
773050d228 Fix a memory leak
Currently we pass a callback from AbsSwipeUpHandler to TaskAnimationManager to render task view launch animation, exposing the launcher activity to the static TouchInteractionService, which causes the leak. To not only fix the leak, but consider a better place for this functionality semantically, RecentsView is a better home.

Fixes: 183458638
Test: Run presubmit

Change-Id: Id35d0ad22005003d2516c34515a5cb338605be0b
2021-03-24 23:47:55 -07:00
Winson Chung
394ede6fe6 Merge "Fix activity NPE when clearing flags" into sc-dev 2021-03-24 23:28:58 +00:00
Alex Chau
dedbc8ac36 Remove grid scaling in Overveiw
- Grid scaling has problem that scales task icon and menu, which makes it hard to control icon size and text size in the manula
- Replaced the whole concept with dedicated Task size calculation in grid layout
- Support different icon size in TaskView in grid and removed task_thumbnail_top_margin
- Removed grid progress in TaskViewSimulator as well
- Refactored how ClearAllButton scroll and translations are calcualted to align clear all properly in grid
- Make page center calculation aware of PagedView pivot and scaling

Bug: 174464863
Test: Manual on two screens
Change-Id: I47b13ef6e55c6e16c52ea04225f5bde02ed82fc2
2021-03-24 18:46:32 +00:00
Zak Cohen
21aa7042c0 Merge "Overview - Adds first pass at making landscape layout real." into sc-dev 2021-03-24 18:44:29 +00:00
Tony Wickham
11bc3118c9 Merge "Remove dead taskbar code" into sc-dev 2021-03-24 17:20:18 +00:00
Winson Chung
6151a34543 Fix activity NPE when clearing flags
- If the activity is already destroyed then skip setting flags

Bug: 183400378
Test: Just adding a null check
Change-Id: Id2fddb5adb3b68302fb58fce340abd29237ca731
2021-03-24 10:01:44 -07:00
Zak Cohen
334efebaba Overview - Adds first pass at making landscape layout real.
Adds dynamic sizing to margins around task view, also creates space in the
overview actions view in landscape to make space for the proactive chips if
needed.

Bug: 182529089
Test: Local build and run on two devices
Change-Id: I447de3564a3249ede4e8e8a4d3e5d1c177f6be61
2021-03-24 14:45:48 +00:00
Andras Kloczl
a4cb0f02de Fix staggered animation on right panel home screen
Recently we have added support for multiple panels
on the home screen but the current StaggeredWorkspaceAnim
logic only supports animation for the leftmost panel.

Test: manual
Bug: 183032642
Change-Id: I539e1c1a26292b75801eb3070e22f0fbde1ebc7e
2021-03-24 12:37:22 +01:00
TreeHugger Robot
bbfef42e48 Merge "Prevent setting task thumbnail during swipe to overview" into sc-dev 2021-03-24 01:46:34 +00:00
TreeHugger Robot
b9d201a5d6 Merge "Remove some unused hotseat/qsb scaling code" into sc-dev 2021-03-24 00:16:01 +00:00
Tony Wickham
aea0cbf9d3 Fix taskbar crash after cleanup
- Set LayoutTransition after adding initial views
- End running transitions in cleanup
- Only run update listener if LayoutTransition is active

Test: No crash after taskbar cleanup()
Bug: 182512211
Change-Id: I1049857935d09235388c1ef1fe4d89ef53b79aa5
2021-03-23 15:35:46 -07:00
Vinit Nayak
706ff85fe5 Prevent setting task thumbnail during swipe to overview
Previously we were setting the incorrect thumbnail when
swiping to overview, then taking a task screenshot right
when the animation ends and replacing the first thumbnail.
This sometimes caused a flicker of the old thumbnail, now
we avoid setting the thumbnail at all for the taskview that
is being swiped up.

Another edge case handled here is when switching nav modes
and then immediately entering overview, Recents receives an
onConfigChange for changing task icon size. That would cause
all taskviews to null out both their existing icon and
thumbnail, now only the icon gets nulled out.
Existing issue where switching to 3 button nav and then
entering overview shows blank icon, doesn't register for
receiving the updated task snapshot fast enough.

Fixes: 179307265
Test: Ask assistant for weather, swipe to overview
Ask assistant for time, swipe to overview, no flicker

Switch nav modes to gesture, swipe to overview.
There's a flicker for config change, but thumbnail is correct

Change-Id: I300b29f999f6d6876f82bc0189b44f4c10ae33fe
2021-03-23 12:00:06 -07:00
Tony Wickham
e63bd38a55 Remove dead taskbar code
Test: Works as before
Bug: 182512211
Change-Id: Id4c979f2924f9ae6881a9bed18bcc52fbd80c05b
2021-03-23 11:42:50 -07:00
Tony Wickham
3629b93546 Merge "Add TaskbarView as a child of Hotseat" into sc-dev 2021-03-23 18:36:53 +00:00
Tony Wickham
d0b6bfaa69 Remove some unused hotseat/qsb scaling code
Now that QSB is always part of Hotseat, we don't need
getQsbScaleAndTranslation(), and now that HOTSEAT_ICONS are never in
Overview, we can remove the getHotseatScaleAndTranslation() override

Test: Everything works as before
Bug: 175137718
Change-Id: I902815d8e270269c1a2a9af54fa8480e5aef929d
2021-03-23 10:33:44 -07:00
Alex Johnston
284aaba153 Block recent work profile apps content capture
Stop data exposure of work profile by blocking
content capture of recents apps when the work
profile is locked.

Manual testing steps
* Set up work profile
* Set personal and work pattern
* Open work app, enter work pattern and
  verify content capture is possible
* Lock device
* Go to Recents and select already opened
  work app. Verify content capture is not
  possible until work pattern is entered.

Bug: 168802517
Test: manual testing
Change-Id: I3e6ba1d8645335785e8e26cdc895ea9c0017a0fd
2021-03-23 16:09:39 +00:00
Steven Ng
dd1026b0c0 Merge "Increase the number of prediction for widgets model" into sc-dev 2021-03-23 10:12:14 +00:00
TreeHugger Robot
516dfc6ace Merge "Fix extra haptic on swipe up" into sc-dev 2021-03-23 03:06:48 +00:00
Sreyas
59b5e241e2 Hide chips if loaded in select mode.
Bug: 182375263
Test: Manual

Change-Id: Id9709a2033b303c09d9ca26d2e05af6af45df564
2021-03-22 15:59:54 -07:00
Tony Wickham
9ce3b25ef6 Add TaskbarView as a child of Hotseat
Instead of keeping the Taskbar window showing above the home screen,
we now integrate a copy of TaskbarView directly into Launcher's view
hierarchy. Most TaskbarController calls apply to both TaskbarViews
(mTaskbarViewInApp and mTaskbarViewOnHome), except for calls related
to Hotseat, which only apply to mTasbkarViewInApp given the real
Hotseat will be showing with mTaskbarViewOnHome.

More cleanup will follow this change.

Test: All taskbar interactions (e.g. drag and drop) continue to work
Bug: 182512211
Bug: 171917176
Change-Id: I0f0b124f652daa85f866e1df8f9e2981540331a0
2021-03-22 15:26:01 -07:00
Tony Wickham
62e08797f3 Fix extra haptic on swipe up
Test: swipe up in 0 button mode, no haptic until pause detected

Bug: 181165935
Change-Id: I69b598cf8e1ac1038d5cfad0f43468a8d7d23e4a
2021-03-22 15:13:21 -07:00
Tracy Zhou
5ac61e1a2e Merge "Support live tile with OVERVIEW_GRID" into sc-dev 2021-03-22 21:20:22 +00:00
Steven Ng
05df2843ee Increase the number of prediction for widgets model
Test: launch all widgets tray and observes widgets predicted.

Bug: 179797520
Change-Id: Id231cde5015a2a79b7532a39343b3340c27e09c9
2021-03-22 20:22:42 +00:00
TreeHugger Robot
6db6c9fe7d Merge "Don't go to NORMAL after task launches if animation in progress" into sc-dev 2021-03-22 19:42:35 +00:00
Tony Wickham
089ad5faab Merge "Dump input monitor and input event receiver to bug reports" into sc-dev 2021-03-22 19:04:14 +00:00
Tracy Zhou
ef45cc95b5 Support live tile with OVERVIEW_GRID
Test: turn on both ENABLE_QUICKSTEP_LIVE_TILE and OVERVIEW_GRID. Swipe up from app to overview
Fixes: 183231362
Change-Id: Ic918e1fad423295d532cefce13c85e622ff8116c
2021-03-22 10:30:22 -07:00
Tony Wickham
85a8da0290 Dump input monitor and input event receiver to bug reports
Test: adb shell dumpsys activity service TouchInteractionService
Bug: 180915942
Change-Id: Ic1155b323cd3f9cef164ce4d663cadc4b29a0893
2021-03-22 09:30:18 -07:00
Bob Badour
41b58c6ec7 Merge "[LSC] Add LOCAL_LICENSE_KINDS to packages/apps/Launcher3" into sc-dev 2021-03-19 23:55:24 +00:00
Tracy Zhou
f209a77a96 Merge "Continue receiving key events from input consumer after settling into Overview" into sc-dev 2021-03-19 20:18:41 +00:00
Tony Wickham
4076cae87f Merge "Use taskbarSize as bottom inset when taskbar is present." into sc-dev 2021-03-19 18:15:52 +00:00
Tony Wickham
e31af6264d Don't go to NORMAL after task launches if animation in progress
Test: Swipe down on a task, swipe up immediately as it launches;
state stays as BACKGROUND_APP instead of NORMAL
Fixes: 171757635

Change-Id: Ia38774c01190bd184e229ff532ea9df2a75abcb4
2021-03-19 11:07:39 -07:00
Sreyas Rangaraju
a2c2d861ba Merge "Fixes OverviewActionsView height sizing." into sc-dev 2021-03-19 17:06:21 +00:00
Tracy Zhou
b0b2a9acd0 Continue receiving key events from input consumer after settling into Overview
This builds on ag/13732971. In live tile mode after settling into overview, recents_animation_input_consumer should have the focus, and thus we will need to extend the lifecycle of input consumers so that key events can be routed to launcher

Overall, since live tile extends the lifecycle of certain private variables of AbsSwipeHandler, I am thinking of doing a refactor by putting those things into a separate class, but it might be too big for this change.

TODO: I've verified that this change works while if we don't process motion events, it would cause b/182932863. Will investigate on that.

Fixes: 181404912
Test: Cherry pick ag/13732971; Go to overview; Swipe back; Observe the animation to go back to app
Change-Id: I5afd397be387b75f373442781dd1d00560dca99e
2021-03-19 10:00:54 -07:00
Sunny Goyal
ddbc7bf03d Merge "Fixing ActivityInit getting called before the full launcher components are initialized" into sc-dev 2021-03-19 16:41:34 +00:00
Pat Manning
b2cfab5321 Merge "Respect clip hint when aligning cropped thumbnails." into sc-dev 2021-03-19 15:26:18 +00:00
Bob Badour
390b27e46c [LSC] Add LOCAL_LICENSE_KINDS to packages/apps/Launcher3
Added SPDX-license-identifier-Apache-2.0 to:
  quickstep/Android.bp
  robolectric_tests/Android.bp
  tests/Android.bp

Bug: 68860345
Bug: 151177513
Bug: 151953481

Test: m all

Exempt-From-Owner-Approval: janitorial work
Change-Id: I699e0796410f691ae7cf4802c41987d79e4e486d
2021-03-19 04:22:23 -07:00
Winson Chung
6ffdceadfe Merge "Update calls to go through the feature interface instead of sysui proxy" into sc-dev 2021-03-19 06:55:32 +00:00
Tracy Zhou
e3ae7e3afa Merge "Revert "[Live tile] Finish recents animation when the phone goes to sleep in live tile mode"" into sc-dev 2021-03-19 04:28:13 +00:00
Sreyas
8dbf38e30f Fixes OverviewActionsView height sizing.
By fixing the action buttons container height and allowing wrap content on overviewActionsView all views have enough room to be displayed and actions button container height can be calculated.
Bug: 182854439
Test: Manual

Change-Id: I34516ba42430d8fe6774e10215dd8ac1127920c8
2021-03-18 20:18:36 -07:00
Evan Rosky
16a713c450 Merge "Add rotation support to launch animations" into sc-dev 2021-03-18 23:24:50 +00:00
Sunny Goyal
a8bbcb9c04 Fixing ActivityInit getting called before the full launcher components are initialized
Bug: 182575999
Test: Presubmit
Change-Id: Iea6986624b70caf2d502c1b21318b57a8b2fde03
2021-03-18 15:49:00 -07:00
Tony Wickham
b31d8fc379 Use taskbarSize as bottom inset when taskbar is present.
This was done in ag/13841736 but not included in ag/13821586

Test: QSB in correct position when taskbar present and not present
Bug: 171917176
Change-Id: I6aa220559afebe8710b5f01cdec9c2baa9f4c926
2021-03-18 13:57:20 -07:00
Tracy Zhou
e6354c1ab2 Revert "[Live tile] Finish recents animation when the phone goes to sleep in live tile mode"
This reverts commit d028937e74.

Reason for revert: Caused a few bugs

Change-Id: I1a3f4aa90679dec18ed27d2a5a5f0446c6d52594
Fixes: 174866547
Fixes: 181937887
Fixes: 183124957
2021-03-18 19:23:44 +00:00
Mariia Sandrikova
f7864feded Merge "Revert "Enable Live Tile"" into sc-dev 2021-03-18 19:18:34 +00:00
Vadim Tryshev
93f2b75223 Merge "Fixing testOverview test" into sc-dev 2021-03-18 18:07:32 +00:00
Winson Chung
19946daf22 Update calls to go through the feature interface instead of sysui proxy
Bug: 180074017
Test: atest PinnedStackTests
Test: Verify Pip works w/ launcher (shelf offsets, autoenter, etc)
Change-Id: I7de733f7267123218f6550963e44f6a893ad99b2
2021-03-18 10:25:39 -07:00