Commit Graph

16456 Commits

Author SHA1 Message Date
Samuel Fufa cfec6b5151 Adding tracing for work profile removal
Bug: 159671700
Change-Id: I6e1bcdfbf1bbaab989106ce2979575652a3fb404
2020-07-28 17:09:08 +00:00
TreeHugger Robot 87ec5d5555 Merge "Misc test improvements" into ub-launcher3-master 2020-07-28 15:32:51 +00:00
Hyunyoung Song 26bca08089 Handle requestFocus for ENABLE_DEVICE_SEARCH
Bug: 161594550

Change-Id: Ic99c04f1235e48e90b64df86e3739f8e14bc648f
2020-07-28 01:37:57 -07:00
thiruram b6d0607d8b Logs system navigation details part of launcher snapshot logging.
Bug: 157997545
Change-Id: I18e908dc62bb790c3a77e1aacd0236a7d84e8ce5
Merged-In: I18e908dc62bb790c3a77e1aacd0236a7d84e8ce5
2020-07-27 16:32:21 -07:00
andychou ca394a3eab Add ActivityOptions for SecondDisplayLaucher to launch activity
Currently, SecondDisplayLauncher doesn't specify ActivityOption to
launch on second display, so application will launch on main display
even the user tries to launch APP from SecondDisplayLauncher.
So need to specify ActivityOption then activity can launch on the correct
display

Bug: 162042798
Test: manual testing
Change-Id: Iceb4e01b725834983a5d01cf54350f61851ad172
(cherry picked from commit 3a8075366c)
2020-07-27 22:05:34 +00:00
thiruram 90573f0515 Logs system navigation details part of launcher snapshot logging.
Bug: 157997545
Change-Id: I18e908dc62bb790c3a77e1aacd0236a7d84e8ce5
2020-07-27 09:51:52 -07:00
vadimt f8ceabbcc1 Misc test improvements
Ignoring state events from NexusLauncher in Launcher3 tests.
Improving diags for failed app launch.

Change-Id: I3ffb49c598edef7b6698b48ba7b63e6163ef25b4
2020-07-24 17:59:50 -07:00
Hyunyoung Song 72ffd8ead6 Merge "Add InsetTransitionController to device search" into ub-launcher3-master 2020-07-24 22:04:19 +00:00
Hyunyoung Song d25dabb466 Add InsetTransitionController to device search
Also removed plugin support as if both the feature flag and
the plugin is turned on, there are object/resource contention

Bug: 161594550

Change-Id: I2cb98e83c46c7e47db96b90fa8d7cb9620643221
2020-07-24 13:57:16 -07:00
TreeHugger Robot a02206e4f8 Merge "Minimal Phone Mode (part-1)" into ub-launcher3-rvc-qpr-dev am: 5484fd3e7a am: 07ab7015f4
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12171290

Change-Id: I4eeb9731c15b3b0d0aac32b4545675e11cc8391a
2020-07-24 18:51:37 +00:00
TreeHugger Robot 5484fd3e7a Merge "Minimal Phone Mode (part-1)" into ub-launcher3-rvc-qpr-dev 2020-07-24 18:16:16 +00:00
andychou 3a8075366c Add ActivityOptions for SecondDisplayLaucher to launch activity
Currently, SecondDisplayLauncher doesn't specify ActivityOption to
launch on second display, so application will launch on main display
even the user tries to launch APP from SecondDisplayLauncher.
So need to specify ActivityOption then activity can launch on the correct
display

Bug: 162042798
Test: manual testing
Change-Id: Iceb4e01b725834983a5d01cf54350f61851ad172
2020-07-24 20:19:31 +08:00
TreeHugger Robot cae7831764 Merge "Adding support for storing container based item list in the model" into ub-launcher3-master 2020-07-23 23:14:11 +00:00
Alex Mang 91da602e4c Merge "Add filtering of preferences in developer options" into ub-launcher3-master 2020-07-23 22:57:40 +00:00
Sunny Goyal 28f5075eb0 Adding support for storing container based item list in the model
These items get updated automatically during various model tasks.
Also simplifying the pinned shortcut state, by calculating the
list of ppined shortcut on demand, instead of storing a refCount.

Bug: 160748731
Change-Id: I3169d293552b05b4f4d6c529397fbc761887a282
2020-07-23 15:27:50 -07:00
alexmang 457ae09acc Add filtering of preferences in developer options
Search will recursively go into each preference group and set visibility of preferences based on title match. If a preference group (category) has no preferences, we will hide that preference group as well.

All queries and titles are sanitized by turning them to lower case and replacing underscores with spaces for convenience.

Change-Id: Ibdc689d74d0c872c92c1d523bbc0efdb9e31aecd
2020-07-23 13:33:44 -07:00
TreeHugger Robot d4046edcd2 Merge "Pass through touches in FolderIcon padding area" into ub-launcher3-rvc-qpr-dev am: 1a32f951f7 am: 18f73dc1b9
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12195184

Change-Id: Ia60641fdb48c054013fbc137d8ddb8e8ed290fcf
2020-07-23 20:23:42 +00:00
TreeHugger Robot 1a32f951f7 Merge "Pass through touches in FolderIcon padding area" into ub-launcher3-rvc-qpr-dev 2020-07-23 18:47:26 +00:00
Samuel Fufa 3c3116826b Pass through touches in FolderIcon padding area
Pass touch events happening in padding of folder icon to workspace. BubbleTextView already does this.

Bug: 161014416
Test: Manual
Change-Id: Ibfa24adb2d84efbfab36f02a2240837f03858e43
2020-07-23 11:09:20 -07:00
Winson Chung 18b76be7f2 Merge changes from topic "ub-one-handed-rebase" into ub-launcher3-master
* changes:
  Guard swipe to notification gesture with system settings preference
  Update state and touch region after one handed overlay changed
  Hook one-handed gesture to expand notification panel by default
  Enable one-handed mode gestural in QuickStep
2020-07-23 02:37:54 +00:00
Jonathan Miranda b2a4677503 Merge "Fix folder crash where view is added when it already has a parent." into ub-launcher3-rvc-qpr-dev am: 20d3187d88 am: cbc1336abb
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12195976

Change-Id: Ie6e1c73e161aede9d0ad07f842385e8926609caa
2020-07-21 20:47:19 +00:00
Jonathan Miranda 20d3187d88 Merge "Fix folder crash where view is added when it already has a parent." into ub-launcher3-rvc-qpr-dev 2020-07-21 20:13:06 +00:00
Sunny Goyal b9a0a99ade Adding home animation support for non-system Launcher am: 30ac97d938 am: c60023449c
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12150115

Change-Id: Idbd4c1ab36928420023987e0e4bdb06edd9e3268
2020-07-21 20:07:31 +00:00
Pinyao Ting a07932fb77 Fix launcher crash after restore with some specific widgets. am: 8dae83ee9b am: 5134643c00 am: 1b31a72388
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12196250

Change-Id: If7e4e70efbbfc534e9359bf2df3a1b559ed7a497
2020-07-21 19:40:54 +00:00
TreeHugger Robot 3db3679c04 Merge "Fix launcher crash after restore with some specific widgets." into ub-launcher3-rvc-qpr-dev am: 664020146f am: 74baee14e2
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12196565

Change-Id: I1bd51f15d56386e644f287080ba7a8f2070082b7
2020-07-21 19:05:45 +00:00
Pinyao Ting 422015cb9f Minimal Phone Mode (part-1)
Include feature flag for minimal phone mode

Bug: 161462256
Test: manual
Change-Id: I4ddbe7fd2fd73b4cfaa27ab18c210f38133dd3c2
2020-07-21 11:45:36 -07:00
Sunny Goyal 30ac97d938 Adding home animation support for non-system Launcher
When user swipes up to home, Launcher will receive a onNewIntent
callwith a bundle-extra gesture_nav_contract_v1. It will contain
the componentName & UserHandle of the closing app & a callback.
Launcher can use the callback to return the final position where
the app should animate to and an optional surface to be used for
crossFade animation. The surface cleanup can be handled in
onEnterAnimationComplete.

Change-Id: I76fdd810fdcb80b71f7d7588ccac8976d9dfe278
2020-07-21 11:43:21 -07:00
Winson Chung fbb8c69a56 Guard swipe to notification gesture with system settings preference
Bug: 154080211
Test: make and install, check the gesture works as expectedly

Change-Id: Ibd6bbd595d2fba5d68e66eb54e4a7fec160b9bf8
(cherry picked from commit 779efaca91)
2020-07-21 09:59:44 -07:00
Winson Chung fc6c42107d Update state and touch region after one handed overlay changed
The matrix for overall modes x state changes:
-----------------------------------------------------
   Mode     |      State changed     | *Before|*After
-----------------------------------------------------
  OneHanded |  Portrait->Landscape   |  80dp  |  32dp
  OneHanded |  Landscape->Portrait   |  32dp  |  80dp
-----------------------------------------------------
  OneHanded |  Disable->Enable       |  32dp  |  32dp
 (Landscape)|  Enable->Disable       |  32dp  |  32dp
-----------------------------------------------------
  OneHanded |  Disable->Enable       |  32dp  |  80dp
 (Portrait) |  Enable->Disable       |  80dp  |  32dp
-----------------------------------------------------
  NO_BUTTON |  Portrait->Landscape   |  32dp  |  32dp
  NO_BUTTON |  Landscape->Portrait   |  32dp  |  32dp
  2 BUTTON  |  Portrait->Landscape   |  48dp  |  48dp
  2 BUTTON  |  Landscape->Portrait   |  48dp  |  48dp
  3 BUTTON  |  Portrait->Landscape   |  48dp  |  48dp
  3 BUTTON  |  Landscape->Portrait   |  48dp  |  48dp
-----------------------------------------------------
* dimen : navigation_bar_gesture_height

Test: adb bugrepot | grep mOneHandedModeRegion
Test: manually triger one handed
Test: atest WindowInsetsBehaviorTests
Test: atest com.android.launcher3.memory.MemoryTests
Test: flake -once
Test: rnlot -t com.android.launcher3.memory.MemoryTests
Bug: 157958539
Bug: 159183864

Change-Id: I19755938c3c93eb59a9f621af5722f5679c1da14
(cherry picked from commit 70b5ca2505)
2020-07-21 09:59:44 -07:00
Tony Huang a0dfbff96a Enable one-handed mode gestural in QuickStep
Handling swipe-down/swipe-up gestural in device bottom area
for one-handed mode

1) The regsion is larger than gesture navigationbar view
2) One handed gestural in quickstep only active on NO_BUTTON, TWO_BUTTONS mode
3) One handed gestural only support on portrait mode

Bug: 150747547
Bug: 154189137
Bug: 156988988

Test: make and install
Test: manual enable one handed mode and swipe down to trigger
Test: manual start one handed and rotate device

Change-Id: I7b2447bfb2fe4082c95176b62934b98077b84920
(cherry picked from commit 7d375e31fe)
2020-07-21 09:59:43 -07:00
Pinyao Ting 8dae83ee9b Fix launcher crash after restore with some specific widgets.
The internal implementation of PendingAppWidgetHostView#getDefaultViews
uses the same view across updates which causes the exception in
AppWidgetHostView#applyContent when it tries to call addView() because
the view has already been added to its parent view in previous iteration.

Bug: 151901506
Test: manual
Change-Id: Ieccec814ac514e592d0d4f196b60ba89aec0d661
2020-07-21 00:57:17 +00:00
Pinyao Ting f1af0171b7 Fix launcher crash after restore with some specific widgets.
The internal implementation of PendingAppWidgetHostView#getDefaultViews
uses the same view across updates which causes the exception in
AppWidgetHostView#applyContent when it tries to call addView() because
the view has already been added to its parent view in previous iteration.

Bug: 151901506
Test: manual
Change-Id: Ieccec814ac514e592d0d4f196b60ba89aec0d661
2020-07-20 17:55:14 -07:00
Jon Miranda 447ea429cd Fix folder crash where view is added when it already has a parent.
The fix is to prevent re-arrangement if the views are already unbound.

This is caused when:
- Folder is open
- Item has deep shortcuts
- Long press on deep shortcut to create DragView that could land in the
  folder if the folder did not auto close. This is important because it
  starts a drag within the folder

The folder unbinds all views as part of the Folder close complete callback.
And then the folder exit alarm gets triggered (because we drag DragView
outside of the folder) which causes the folder items to get
rearranged and added back to the folder's CellLayout.

Bug: 161559911
Change-Id: I142589b2c541dc21c47a67c20a93e627732107ef
2020-07-20 16:54:17 -07:00
TreeHugger Robot aaf4abd7b3 Merge "Fix bug where realtimeReorder is called after views have been unbound." into ub-launcher3-rvc-qpr-dev am: f55ccf4350 am: acecc0c3fc
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12196208

Change-Id: Id135a0d81cd6a37defe556058ffb51ddd475a7f7
2020-07-20 23:39:27 +00:00
TreeHugger Robot f55ccf4350 Merge "Fix bug where realtimeReorder is called after views have been unbound." into ub-launcher3-rvc-qpr-dev 2020-07-20 23:01:30 +00:00
Jon Miranda 0f620500b0 Fix bug where realtimeReorder is called after views have been unbound.
Bug: 161498651
Change-Id: I89beaad9a91bfa1763454965bf95ba1a94d29902
2020-07-20 15:28:25 -07:00
Samuel Fufa 63c64097d9 Invalidate stale BgDataModel when predictions are disabled am: e47896cb91 am: adc8870aa1
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12193276

Change-Id: I9169f3a794bed745eb395ba938bca1ff847abdfc
2020-07-20 21:46:01 +00:00
TreeHugger Robot 44b72984e6 Merge "Removing diags for a fixed flake" into ub-launcher3-master 2020-07-20 20:27:09 +00:00
Samuel Fufa e47896cb91 Invalidate stale BgDataModel when predictions are disabled
Launcher stores ItemInfos for cached predictions in list BgDataModel.cachedPredictedItems  on Launcher start (LoaderTask#run). The list reused if launcher has to rebind UI. Hence, the list should be cleared if launcher receives empty predictions.

Bug: 161245294
Test: Manual
Change-Id: I275655d5f52f6a6e5297473dd2f642728c1964a6
2020-07-20 12:41:07 -07:00
vadimt 665232be61 Removing diags for a fixed flake
Bug: 160238801
Change-Id: Ia166eb1f154ddeeb70da5a141c9e985a265ba49a
2020-07-20 12:24:50 -07:00
Jon Miranda a73b532e87 Fix bug where double swipe gets us stuck in Hint state while in Overview. am: a8c08584a7 am: 721d5c7cc7
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12173854

Change-Id: Iaab1df73b6f7a60ef829ec9372b71b0266641d50
2020-07-20 18:45:50 +00:00
Jon Miranda a8c08584a7 Fix bug where double swipe gets us stuck in Hint state while in Overview.
With the second swipe, we never complete the swipe to Overview

NoButtonNavbarToOverviewTouchController#maybeSwipeInteractionToOverviewComplete
- mReachedOverview = true
- mDetector.isSettlingState = false

And then the second swipe starts the state transition to Hint but then
it never gets completed because:
1. The animation starts
2. Gets cancelled
3. Starts again
4. Finishes, but is not marked as success since the cancel in #2 was never
   set back to false

Bug: 160759508
Change-Id: I8c3972e6209c3d5a4a0bdd9f9b7683de18105d57
2020-07-20 10:29:29 -07:00
Samuel Fufa 9ae44d6c2b Setup controller for on device search
With introduction of feature flag ENABLE_DEVICE_SEARCH, Launcher can now show a softkey input when user goes to all apps.

Bug: 161545076
Test: Manual
Change-Id: Ie75d059da0a20d0fb98b87bb948a205c080ba529
2020-07-18 13:00:32 +00:00
Tracy Zhou c332b7dbff Merge "Infinite loop when migrating calendar widget" into ub-launcher3-rvc-dev am: 8c46b20958 am: 011fa1bac1 am: 835b25d1dd
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12151323

Change-Id: I7cdb94a92668c239b442933c48a5b8c797cda088
2020-07-17 23:07:17 +00:00
TreeHugger Robot f7ca580c99 Merge "Prevent showing TaskMenuView if icon isn't present" into ub-launcher3-rvc-qpr-dev am: 4b1d1a0f18 am: 3a80d76fac
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12130181

Change-Id: If090c1028ce2a6656390a93607a6d0822a09f97b
2020-07-17 23:06:12 +00:00
Sunny Goyal eaa7ea4243 Merge "Fixing shortcut popop non-clicable on the icon" into ub-launcher3-rvc-qpr-dev am: 4ef25b0122 am: a587387a4f
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12141678

Change-Id: Iece987df079621b7991291103f1f5dfca8e32819
2020-07-17 23:05:56 +00:00
TreeHugger Robot 91e270257a Merge "Focuses on folder container for Accessibility when no contents to focus on." into ub-launcher3-rvc-qpr-dev am: 4c7ced91c0 am: 171b2ae917
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12146163

Change-Id: I059c80cc120ce112576dede464ee49238c1ff639
2020-07-17 23:05:32 +00:00
TreeHugger Robot 5474f78a57 Merge "Calculate all apps cell height based on actual sizes." into ub-launcher3-rvc-qpr-dev am: 36a1600d66 am: d318bc6dda
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12121642

Change-Id: I3d555960063616f722fba26e389841d8eed9b449
2020-07-17 21:04:41 +00:00
Tracy Zhou 9faaf90b3c Merge "Infinite loop when migrating calendar widget" into rvc-d1-dev am: 4527d2dbb2 am: f96e2b89c3 am: 2342af53f8
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12160682

Change-Id: I7c590c4b84cc1852e7ba805c43d854160b2d57b0
2020-07-17 20:19:23 +00:00
Tracy Zhou 011fa1bac1 Merge "Infinite loop when migrating calendar widget" into ub-launcher3-rvc-dev am: 8c46b20958
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/12151323

Change-Id: Ifc101b5e4b76976cb835d3d0210320fe332ff323
2020-07-17 19:20:37 +00:00