Commit Graph

1650 Commits

Author SHA1 Message Date
Jon Miranda f58db150af Play fallback animation if icon in All Apps is covered by header.
Bug: 230707341
Test: enter all apps
      scroll so icon is covered by header
      open app, swipe back to return to all apps
      confirm fallback animation plays

      repeat but scroll so icon is not covered by header
      confirm normal animation plays

Change-Id: I56cda07f3eccc11e8909f7fb28210f65cc6e0f1d
2022-06-02 16:06:37 -07:00
Stefan Andonian 45fc301b0e Change accessibility announcement for workspace from "Pixel Launcher" to "Home".
Bug: 228410736
Test: Verified correct talkback announcements.
Change-Id: Ic0a5295cde3cd23d2fc5a6fcd19b6cf8e0f3e386
(cherry picked from commit 83bc5f5050)
2022-05-24 18:21:33 +00:00
Sunny Goyal a292987030 Merge "Adding support for extending back behavior in Launcher" into tm-dev 2022-05-17 23:02:50 +00:00
Sunny Goyal 3f2637faee Adding support for extending back behavior in Launcher
Bug: 231224820
Test: Manual
Change-Id: I9accc30c01dce5f6920b611cfeed9fa0584d2846
2022-05-16 14:40:19 -07:00
Pinyao Ting 6a41d56b50 Log the reason why a WorkspaceItemInfo was removed
In the past we've seen a WorkspaceItem disappeared from the workspace
but wasn't able to determine why it was removed. This CL includes the
reason why it was removed in the error log, which hopefully would help
us debugging similar issues in the future.

Bug: 231239260
Test: make
Change-Id: Iba3d57568c9b3e011a6b65b26f0d4170d42fe1a5
2022-05-16 20:17:47 +00:00
Jon Miranda a82a7dc205 Clear all DragView in onResume
- Multiple users reports view getting stuck on screen. This CL
  clears all DragView when user leaves launcher.
- Moved to onResume to not interfere with start up time,
  and also aligned with when we remove AbstractFloatingView.
- Root cause still undetermined, but happens enough that it warrants
  a temp fix.

Bug: 162636845
Test: drag and drop configurable widget
      (widget that gets dropped then opens up a
       configuration activity)
Change-Id: I532b5274a1308c53f67c23c5c8ca07f2b7f9802c
2022-05-10 11:48:32 -07:00
Schneider Victor-tulias a78e070a2e Merge changes from topic "presubmit-am-1224af9ca3f341a895e4bc19976e2bb8" into tm-dev
* changes:
  Fix recents animation flicker
  Fix janky overview animation.
2022-05-06 18:48:29 +00:00
Schneider Victor-tulias 9f922d3598 Fix recents animation flicker
The recents animation can sometimes start before launcher has started when started with 3-button mode. This causes the animation to start before the recents UI has been initialized by Launcher. Added a callback to properly synchronize launcher start and the recents animation.

Fixes: 229360539
Test: started the recents animation and checked logs (order of operations), when the recents animation or launcher started first
Change-Id: I5938bbba778a2886b4a1e4ee4844eaf28c6fac0e
2022-05-04 22:27:50 +00:00
Sunny Goyal f76524151d Merge "Replacing ItemInfoMatcher with predicate" into tm-dev 2022-05-03 20:04:55 +00:00
Sunny Goyal 32084d49d3 Replacing ItemInfoMatcher with predicate
This removed unnecessary componentName lookups when it
is not required. Many checks just rely on IDs and
userHandle

Bug: 231153610
Test: Presubmit
Change-Id: Ief93954abc5861062a9f55dc2ef181d3de106c62
2022-05-03 10:07:22 -07:00
Schneider Victor-tulias 9b6babf839 Translate the 3 navigation buttons to/from their in-app position when animating to/from the -1 screen, all apps and widgets.
Bug: 221455508
Test: opened all apps, widgets, -1 screen, notifications shade and keyboard in various combinations and orders; locked screen, launched app, returned home with the back/home buttons, opened overview
Change-Id: Ia0b406aacf72b34bd6b7ff1c01278ab6895a7da4
Merged-In: Ia0b406aacf72b34bd6b7ff1c01278ab6895a7da4
(cherry picked from commit 9c1a452a1d)
2022-05-02 18:45:01 +00:00
Anushree Ganjam 5cc7ff0990 Revert "Refactors Search results into separate RV for Toast."
This reverts commit 6729f0b950.

Reason for revert: This change caused b/230648542.

Please see https://b.corp.google.com/issues/230648542#comment5 for the video after reverting this change.

Bug: 206905515
Bug: 230648542

Change-Id: I85f063c56cad137c05b810204244bba7e8f94ee7
2022-04-28 01:37:49 +00:00
Andy Wickham 6729f0b950 Refactors Search results into separate RV for Toast.
This will help enable transitions between A-Z apps lists and
search results because both can be seen simultaneously and
manipulated independently.

Some high level items of the refactor:
 - SearchRecyclerView is added; logic that populated the main
   (personal) tab with search results was simply redirected to
   this RV instead.
 - BaseAllAppsContainerView added isSearching() method. Returns
   false, and ActivityAllAppsContainerView overrides (as search
   is handled there).
 - Renamed BaseRecyclerView to FastScrollRecyclerView to better
   describe what it does. SearchRecyclerView extends this, but
   returns false for supportsFastScrolling().
 - AlphabeticalAppsList#mAllAppsStore is now optional, so the
   Search RV doesn't need to store/listen to apps. Note this
   doesn't affect the predicted app row which is still updated
   if one of the predicted apps is uninstalled (I tested this).

Future work:
 - Determine why dispatchRestoreInstanceState is not called for
   BaseAllAppsContainerView. Save is called, e.g. on rotation.
   Effect of restore not called: rotating while searching goes
   back to A-Z list.
 - Keep suggested apps in Header while searching. Currently they
   are rendered in the SearchRV above search results, as before.
 - Potentially extract Personal/Work tabs to move independently of
   header.
 - AlphabeticalAppsList is a misleading name because it can also
   contains search results. However, things are pretty intertwined
   between that and BaseAllAppsAdapter (effectively a circular
   dependency), so I figured cleaning all that up was out of the
   immediate scope of this refactor, which is mainly meant to
   unblock transition work.

Bug: 206905515
Test: Manually checked for regressions, ran tests.
Change-Id: I4d3757c8a8f9b774956ca6be541dd4fcdad1de13
2022-04-24 17:36:48 -07:00
Sunny Goyal 7b8d63fcf8 Removing fade in logic during load.
Launcher already blocks the draw during load, which ensures
that system draws the loading screen. Additional fade animation
is not visible since the Launcher window is already getting fade in

Bug: 199120420
Bug: 199120420
Test: Verified on device

Change-Id: I7089cea4c5f97f6ef92eabcba56451de407c98b8
2022-04-22 16:35:40 +00:00
Shikha Malhotra 2e255ed0ac Merge "Refactor code to be used in LauncherLily features" into tm-dev 2022-04-21 07:50:32 +00:00
Shikha Malhotra e957b600d3 Refactor code to be used in LauncherLily features
Refactor add to workspace code to be used in Lily Launcher.
Also utilising code swap feature to swap out functionality of sorting
items on workspaces and finding next vacant space.

Bug: b/218186705
Test: Manually tested Launcher3 works.
Change-Id: I42a44eabeb307e1d23ef333e0a169437f9062bb6
2022-04-20 07:22:20 +00:00
Sunny Goyal cd2ac0f3e9 Updating target SDK for Launcher
Bug: 229173942
Bug: 226461147
Test: Presubmit
Change-Id: Id9e303f113cba87adf26442f1417ed2814555c54
2022-04-18 13:55:01 -07:00
Shikha Malhotra f78da1bae3 Review comments followup
These are review comments followup from ag/17399997

Bug: b/218187058
Test: manually test thet Launcher3 features work correctly
Change-Id: I9865a37c1ed663370dc28e7678994f3d961e3cd1
2022-04-12 14:33:07 +00:00
Shikha Malhotra 6d6f62c462 Merge "Added provision to switch the PageIndicator in specific Launchers" into tm-dev 2022-04-08 20:17:44 +00:00
Shikha Malhotra 0f2e1b6714 Added provision to switch the PageIndicator in specific Launchers
Please see the related CL in LauncherLilyGoogle where pagination is
implemented as persistent dots.

Bug: b/218187058
Test: manually test thet Launcher3 features work correctly
Change-Id: Ic20aa92249b1bbe3c4ab7810683b54648a181722
2022-04-08 11:47:46 +00:00
Stefan Andonian d123fbd15d Simplify AbstractFloatingView.closeOpenViews usage.
This is a follow-up code review to ag/1754638 to address a comment that was missed before the CR was pushed.

Bug: 227142635
Test: Folders still close when launcher is paused.
Change-Id: Ib6724dc3a6ba49e259ba7de655f6810d6a692d16
2022-04-07 22:19:26 +00:00
Stefan Andonian 52eaebead4 Merge "Close open folders when pausing launcher." into tm-dev 2022-04-07 18:53:45 +00:00
Stefan Andonian 253c23b2e8 Close open folders when pausing launcher.
Previously, folders wouldn't close after launching an app and quickly navigating back the launcher.
This is because the onStop state which contains a call to AbstractFloatingView.closeViews() wasn't being called.
This change adds an additional call to specifically close any open folders when the Launcher enters a paused state.

Bug: 227142635
Test: Verified that the issue is fixed after code change.
I logged the Launcher's lifecycle state to ensure my manual testing was reliable.

Change-Id: I838f992f83afdd754672ebbe85d0eb2a7e894417
2022-04-06 21:47:35 +00:00
Sunny Goyal 5c20fdd73f Adding finish signal to GestureNavContract.
Also fixing also-closing behavior for FloatingSurfaceView for Android S

Bug: 228260232
Test: Verified manually on device
Change-Id: I83f6417a756c1459533294d681e83abba6ea58aa
2022-04-06 13:42:59 -07:00
Abhilasha Chahal dfd154f18d Use numAllAppsColumns to calculate height of all apps icons
Additionally opens up access of some fields to allow them to be overridden.

Test: Manually verified that Launcher3 layout does not change

Launcher3 APKs: https://drive.google.com/drive/folders/1hBcZU9xou4tZJxbTmkya_LyBbD2oYuwV?resourcekey=0-R0I1IQ2rSUIEfPjW8S_ppA&usp=sharing

Bug: 216150572

Change-Id: I4b97a7e9e15973fc5aa70a4b98f0b73dd5bf3c17
2022-03-23 21:09:54 +00:00
Brian Isganitis bde3c8b6bd Move activity starting logic into new ActivityContext extension.
This code branch is needed for taskbar, so needs to be moved from the
activity classes to an interface that both can share.

Test: Manual
Bug: 216683257
Change-Id: I042c0dcf08207d94847b9d7a1783acc14613ef5f
2022-03-16 13:59:03 -07:00
Jon Miranda e8b174482d Merge "Add debug logs for bad launcher state." into tm-dev 2022-03-10 22:03:37 +00:00
Jon Miranda 7ebe209c21 Add debug logs for bad launcher state.
Bug:223498680
Bug:221658803

Test: manual
Change-Id: I138a7ab031269009fa8ca492cd0bd48085aa4e68
2022-03-10 20:25:38 +00:00
Jon Miranda 7db484396a Merge "Never look for matching view in All Apps when swiping up to go home." into tm-dev 2022-03-10 18:46:51 +00:00
Thiru Ramasamy 694407ce08 Make AllAppsEntry and exit events optional.
This change will allow us to skip logging AllApps entry and exit events when entering into AllApps state from QSB.

Bug: 210792253
Test: wwdebug && wwlogcat
Change-Id: I658ff0842c72aa27335d426abaa46435ae312941
2022-03-09 07:14:36 -08:00
Jon Miranda b42e124f5b Never look for matching view in All Apps when swiping up to go home.
The swiping up gesture will never return an app in All Apps,
so we can ignore All Apps state in those cases.

This fixes an edge case where user swipes up and launcher state
is still in All Apps. This causes us to animate the icon to
where it would be in All Apps, even though by the time the
animation starts we are actually in Normal state.

Bug: 222124240
Test: open app from  all apps then quickly swipe up to go home
Change-Id: I756a870660a397d6629aec82e4f5ec4914ed0669
2022-03-08 16:37:35 -08:00
Schneider Victor-tulias 789a6a95cc Add method to pause expensive view updates during the app launch aimation
Fixes: 220922269
Test: Manual
Change-Id: I39066f575c0ddfc4868ab9e27149e2bd9492b39c
2022-03-04 13:59:33 -08:00
TreeHugger Robot 49141ccf2e Merge "Revert "Clear all DragView in onSaveInstanceState"" 2022-02-17 20:45:46 +00:00
Jon Miranda baf1ef55ab Revert "Clear all DragView in onSaveInstanceState"
This reverts commit 14d6771aae
to fix bootline regression.

Bug: 210383463
Test: manual
Change-Id: I5a0dadee59bfd6b5a164fd2ca3ecdd1885cb4134
2022-02-14 20:26:40 -08:00
Brian Isganitis 099945b075 Add predictions row to taskbar all apps.
- We need to listen to DeviceProfile changes in case the number of
  columns changes in the grid. I made an interface/mixin separate from
  ActivityContext to avoid polutting the latter with too many things. I
  also applied this change to existing taskbar A-Z grid.
- Added all apps visited count to onboarding preferences for only
  showing "All Apps" label in place of divider 20 times. Label is also
  tracked on taskbar side and should be kept in sync.

Test: Manual
Fix: 216843395
Bug: 174174514
Change-Id: I97aa91397c334123626caf18251f19e17c7104fb
2022-02-14 11:24:16 -08:00
Alex Chau bf63e9cf2b Merge "Add debug logs for testPromiseIcon_addedFromEligibleSession" 2022-02-14 11:38:57 +00:00
Jon Miranda 701774d021 Add debug logs for testPromiseIcon_addedFromEligibleSession
Bug: 202985412
Test: PromiseIconUiTest
Change-Id: I160b9229bebe07015575f8184ac2d53bcbf2bad0
2022-02-10 17:26:11 -08:00
Kholoud Mohamed 6974d39a44 Merge "Expose action that allows landing on the work tab" 2022-02-08 17:12:18 +00:00
kholoud mohamed ceec31b17c Expose action that allows landing on the work tab
Bug: 217385869
Bug: 203531272
Test: manual
Change-Id: I68a6add9f603105e0a2ee01ebdc3059e18c9a050
2022-02-07 18:53:49 +00:00
Thiru Ramasamy 529fa34650 Merge "[OneSearch] Extract logging event for all apps entry into separate method." 2022-02-04 19:21:16 +00:00
Thiru Ramasamy 5fbac637c6 [OneSearch] Extract logging event for all apps entry into separate method.
Add containerInfo to the AllApps entry events to track from which workspace
user entered into AllApps drawer

Bug: 217583896
Test: Manual http://gpaste/6272522430447616

Change-Id: I77069a350a7b0e88cb321485144e0d8b976c4da9
2022-02-04 19:20:59 +00:00
kholoud mohamed c76b2035aa Allow overriding enterprise related strings in Launcher
Test: manual
Bug: 188414133
Bug: 211422509
Bug: 188410712
Change-Id: I75858cdcf2057e7c270da5893cd9a90c6753f182
2022-01-28 16:33:03 +00:00
Brian Isganitis c19b51e1f3 Merge "Refactor all apps to depend on activity context." 2022-01-25 18:34:30 +00:00
TreeHugger Robot 78cac51636 Merge "Remove ADAPTIVE_ICON_WINDOW_ANIM feature flag." 2022-01-25 14:21:24 +00:00
Jon Miranda 78d0d4f832 Remove ADAPTIVE_ICON_WINDOW_ANIM feature flag.
Has been enabled for past few releases, no longer needed
as a debug flag.

Bug: 209856611
Test: manual
Change-Id: Id25e36522636e5c5d8ee60cdec49b3ee3f4d4251
2022-01-24 18:00:04 -08:00
Brian Isganitis 1664c9f418 Refactor all apps to depend on activity context.
The current AllAppsContainerView has been split into a base class and a
subclass for activities. The base class allows using all apps with an
activity context. A-Z and work profile tabs are supported, but search
and the hotseat still require an Activity.

Test: Manual. All apps should work the same.
Bug: 204696617
Change-Id: I3b146714bc11b3b3555d97623aab5d78ac836482
2022-01-24 20:24:20 -05:00
Josh Tsuji 46728f6481 Merge "Adds Launcher in-window animations, and reworks how the unlock flow works." 2022-01-24 20:34:44 +00:00
Jon Miranda 0aff1151c3 Add log to help debug crash during bindItems.
Bug: 198115560
Test: can't repo, need to catch in wild
Change-Id: I9d457fce4903c5df33833a5e4817f8a32ed260e2
2022-01-21 22:07:48 +00:00
Josh Tsuji 231c9229bf Adds Launcher in-window animations, and reworks how the unlock flow works.
Bug: 197636887
Test: atest SystemUITests
Change-Id: Idab7249e4a761040863578d546f0831794efaf4a
2022-01-21 10:41:00 -05:00
Sunny Goyal 80a071be2b Updating interface name to avoid AS build errors due to name conflict with SysUI
Bug: 152086714
Test: Verified building locally
Change-Id: I348d7672bda76f6cffc975cb44916c5867d9728d
2021-12-27 13:31:40 +05:30