Commit Graph

380 Commits

Author SHA1 Message Date
Bill Yi 0a044199ec Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I638f862f37915af69371535dd0792ae5d59c2c3b
2021-05-18 23:10:48 +00:00
Jon Spivack a44bb71d95 Merge "NIU Actions and Recents UI updates on Go" into sc-dev 2021-05-18 18:05:19 +00:00
Jon Spivack f90db8a8eb NIU Actions and Recents UI updates on Go
This tweaks the layout and fonts in the Go Overview. It also adds rounded corners to the task snapshots in the Recents view on Go by adding an overrideable value to the base Quickstep Launcher.

Bug: 186004471
Test: Manual (Pixel 3A)
Change-Id: I220836a95a6416b85bdb71d88822d25d939cf205
2021-05-17 11:57:01 -07:00
Bill Yi 8132baf3de Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I71372d68317892f9044ff5c8f9397f8f6fd70e71
2021-05-17 10:50:49 +00:00
Bill Yi 6b2be3789c Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: Ia6bc84a966d24fa30a9a5d812c76bd18066acf31
2021-05-13 07:39:28 +00:00
Jon Spivack 9e0189bac6 Default screen context permissions for NIU Actions
This updates the checks for ASSIST_STRUCTURE_ENABLED and ASSIST_SCREENSHOT_ENABLED to return 1 if the settings do not exist. This matches the logic in the Settings app iself, which has the toggle boxes on by default but does not actually initialize those values until they are toggled for the first time.

Bug: 187868947
Test: Manual (tested on Pixel 3A)
Change-Id: I4ef067dcf21b40eea71199e057d7a00d1d8fb2b3
2021-05-11 19:02:58 -07:00
Jon Spivack 4ff2f7697c Merge "Rework NIU Actions buttons UI" into sc-dev 2021-05-11 22:29:12 +00:00
TreeHugger Robot 95ff5cf63e Merge "Handle config changes in Launcher" into sc-dev 2021-05-11 10:58:48 +00:00
Bill Yi c28b75b8eb Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I384f2a0b04475aed1587f685e6046b14ffaa9240
2021-05-11 04:19:24 +00:00
Jon Spivack 6a7094d43a Rework NIU Actions buttons UI
The shapes, colors, icons, and layout of the NIU Actions buttons have been updated to match the latest UI specs. The icons also no longer overlap with the layout above them, which solves a picking issue.

Bug: 186004471
Bug: 187460625
Test: Manual (tried on Wembley and Pixel 3A)
Change-Id: Ie7a0ca0c21805fc0f126053ec791fd2460710d33
2021-05-10 18:22:52 -07:00
Alex Chau a02eddc144 Handle config changes in Launcher
- This is practically a revert to http://ag/c/13687966/5 and refactored to use DisplayController.DisplayInfoChangeListener
- Make Launcher handle size and density change so transition is less janky when screen size changes
- Added fix in RecentsView to update state and TaskView when display profile changes
- Removed 720dp specific resoureces
- Removed unused widget_section_indent
- Removed unnecessary all_apps_background_canvas 600dp override that is not needed in AllApps+
- Moved remaining dp specific into DeviceProfile
- Simplified allowRotation logic to use single variable in DeviceProfile to determine if allow rotation is enabled by default

Fixes: 180803696
Test: manual
Change-Id: Iea0a7d1a0e14dc3613152dd3b3887450a2e1fc2f
2021-05-10 18:50:02 +01:00
Bill Yi 14980fe0dd Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I67cae1b3cc2fd0e16750dd31f762b9d480792595
2021-05-09 10:50:07 -07:00
Bill Yi 2ca3f98921 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I432d4ee0276275401879ce050f9600e2319ef883
2021-05-07 14:43:37 +00:00
Jon Spivack bdf64e79bd Add app package names to NIU Actions Intents
This adds the package name of the currently suspended app to the NIU Actions Intents, for logging purposes.

Bug: 186388671
Test: Manual (printed out the Intent extras while trying various apps)
Test: m -j RunLauncherGoGoogleRoboTests
Change-Id: I8180347675c8940c960e4aa4c47dec508207c780
2021-04-30 17:37:16 -07:00
Jon Spivack c5919749ea Check screen context permissions for NIU Actions
This checks for the ASSIST_STRUCTURE_ENABLED and ASSIST_SCREENSHOT_ENABLED permissions before sending NIU Actions Intents. If either permission is absent, the screenshot is not sent, and an error code is added to the Intent.

Bug: 182010359
Test: Manual (toggled permissions and clicked NIU Actions buttons on Wembley device)
Test: m -j RunLauncherGoGoogleRoboTests
Change-Id: Icf0db739f5010862cc2bac496f5410665625f3be
2021-04-28 18:26:13 -07:00
Jon Spivack 23a76dae18 Go Launcher: Update Overview Actions buttons
This updates the layout of the overview buttons to better match more recent UX mocks. It also restores the buttons' captions, which had gone missing.

Bug: 183448909
Test: Manual (verified on Wembley and Sargo)
Change-Id: I931df92cd0d255289168694d4a950649eec7da75
2021-04-14 18:46:32 -07:00
Sunny Goyal 11d7d34f0d Removing unnessary resource split in overview
Bug: 184169818
Test: Presubmit
Change-Id: Iff5a8510be337472f05acb5629712ec088361471
2021-04-02 11:43:29 -07:00
Alex Chau dfde4d96ea Focus running task in overview grid
- calculateTaskSize now returns the Rect for focused task
- Introduced calculateGridTaskSize for non-focused task, and translate non-focused tasks to fit the grid
- As Task Rect is now vertically centered, removed ClearAllButton's grid vertical translation
- When ClearAllButton is not shown (e.g. quickswitch), make sure ClearAllButton's scroll won't be used when page snapping. This happens when page scrolls are translated so they're negative.
- Added back ActionsView when task is focused below the TaskView, which become invisible as you scroll
- In Modal state, move the ActionsView down so it won't cover the TaskView

Bug: 175939487
Test: manual
Change-Id: Idfa94a51f856418adc0503cf04211dcb4b1814fe
2021-04-01 14:52:25 +01:00
Zak Cohen 733efa1bcd Overview - extract AssistContentRequester logic for reuse.
Extract the logic for fetching AssistContent into a common reusable place.

Bug: 179705864
Test: Local build of main launcher
Change-Id: Ife37a393d93f899fa1ae460bdcf0cadff6468b04
2021-03-27 14:53:34 -07:00
Rajeev Kumar f23ea3b067 Merge "Add OWNERS to Launcher3/go" am: 278edf2938 am: dc71c0178a am: ee9a99a6a8
Original change: https://android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/1653167

Change-Id: I227d47f2ba807e4b5de60fba8dbad60f279bdba4
2021-03-25 16:30:13 +00:00
Rajeev Kumar 278edf2938 Merge "Add OWNERS to Launcher3/go" 2021-03-25 14:50:06 +00:00
Alex Johnston ad4c83ad36 Merge "Block recent work profile apps content capture" into sc-dev 2021-03-25 09:14:05 +00:00
Jon Spivack 6914f93f8e Merge "TaskOverlayFactoryGo: Minor updates for testability" into sc-dev 2021-03-25 05:08:49 +00:00
Jon Spivack 177cff38fa Add OWNERS to Launcher3/go
The code in this directory only impacts the Go Launcher variants, so it would make sense for the owners to be from the Go team.

Bug: 183627385
Test: N/A
Change-Id: Iab09be2d590d25bce6de07048befa2e832a54623
2021-03-24 11:47:54 -07:00
Jon Spivack 387e65e3c4 Change label for Search button in Go Overview
The visual search button on the Recents screen (on Go devices) will be renamed to Lens.

Bug: 183618164
Test: Manual
Change-Id: I86371e604bd0204510737e5088c95404129818bb
2021-03-24 17:23:32 +00:00
Jon Spivack 375a1bbb92 TaskOverlayFactoryGo: Minor updates for testability
Made a few things public and marked them as @VisibleForTesting.

Bug: 179738220
Test: atest -v LauncherGoGoogleRoboTests
Change-Id: I231316ecf9282ad4d54038e218f44f062b3fa413
2021-03-24 04:05:03 -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
Jon Spivack 1de153c6e5 Merge "Pass Assistant web URI in NIU Actions" into sc-dev 2021-03-22 23:57:58 +00:00
Jon Spivack f0b702f61b Enable NIU Actions on Go devices
This flips the feature flag to enable the NIU Actions buttons in the Go Launcher Recents page.

Bug: 158157668
Test: Manual (on local wembley device)
Change-Id: Ifa49cbb8840556ce53a09f00e36b0f6a12eb8d60
2021-03-19 14:38:22 -07: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
Jon Spivack 840b42f66f Pass Assistant web URI in NIU Actions
The Task Overlay for the activity shown in Recents requests the AssistContent for that activity. If the content includes a web URI, this is added to the Intents sent by the NIU Actions buttons.

Bug: 180157890
Test: Manual (tested with Chrome as the recent activity on local device)
Test: TODO (b/179738220)
Change-Id: I33c79e75678605693e0282e4ad82dc6af28957dd
2021-03-17 17:47:29 -07:00
Steven Ng 3a8353256a Widgets recommendation backend
Add a widgets recommendation mechanism based on AiAI app predication
ranking with the following changes:

1. Only one widget is picked from one app.
2. Widgets that are already added to the workspace are excluded from
   the recommendation.

Test: run PredicationUpdateTaskTest

Bug: 179797520
Change-Id: Ia697bc6df0bae75969e68b7b3de32d57901f7461
2021-03-08 23:37:51 +00:00
Alex Chau 8c575c378e Remove smallestScreenSize from configChanges
- Remove smallestScreenSize so Launcher activity restarts when screen size changes to pick up new smallestSize dependent values e.g. R.bool.allow_rotation

Bug: 180803696
Test: Ensure rotation preference is respected when switching between large and small screen

Change-Id: I58f856a97effa8e35236d013300181c5d332b25a
2021-03-01 12:20:26 +00:00
Rajeev Kumar 1216e5999e Merge "Add NIU Actions buttons to the Go Overview" into sc-dev 2021-02-12 18:23:17 +00:00
Steven Ng 2f5648a911 Refactoring before adding a new view type in the WidgetsListAdapter
Changes made:
1. Model: added an abstract class for storing common information for
   entries shown in the full page widgets picker.
2. Introduced a ViewHolderBinder interface to split the logic of binding
   data to ViewHolder into separate classes.
3. Move the view holder binding of WidgetsListRow from WidgetListAdapter
   to its new class.
4. Move some widgets picker classes into a new picker package.

Test: Auto: Run WidgetsListAdapterTest, WidgetsListRowEntryTest and
      WidgetsListRowViewHolderBinderTest.
      Manual: open the all apps widgets tray and navigate the list.

Bug: 179797520
Change-Id: Iab29557842bb79156cad84d00a4c5d0db0c5aa06
2021-02-10 21:23:40 +00:00
Jon Spivack 3a1cfc9082 Add NIU Actions buttons to the Go Overview
The buttons send Intents to the designated app (specified by
niu_actions_package) to do the following:
Listen - Read the contents of the screen aloud
Translate - Translate the contents of the screen
Search - Perform a visual search on the contents of the screen

The Intents also include (via URI) the screenshot of current app used as
a thumbnail by Recents.

The feature is controlled by the enable_niu_actions flag, set to false
here. Both this flag and the niu_actions_package String must be set for
a given Launcher to use these buttons.

Bug: 177955244
Bug: 177955748
Test: Manual (enabled on LauncherGoGoogle and sent Intents to demo Lens
app)

Change-Id: I3d1f870bb176ed0cbae637a45c072bd8acac1d4b
2021-02-09 14:50:56 -08:00
Jon Spivack a89a5084f2 Add the Share App system shortcut to the Go Launcher
This shortcut allows users to initiate peer-to-peer app sharing from an app's long-press menu on the home screen. It does so by passing an intent to the specified component. In this base implementation, that specification in config.xml is left blank, and the button will not appear. In GMS Launchers such as LauncherGoGoogle, the config should be set to point to Nearby Sharing.

This also establishes Launcher3QuickStepGo as a distinct subclass of QuickstepLauncher instead of merely a build configuration.

Bug: 157515296
Bug: 174286192
Test: Manual (tested on local wembley devices)
Test: m -j RunLauncherGoGoogleRoboTests
Change-Id: I826bd03721d2e7e963b15d5958e9a18a1cc16f1d
2020-11-30 18:53:56 -08:00
Sunny Goyal 9136897b65 Merging from ub-launcher3-master @ build 6782663
Test: manual, presubmit on the source branch
x20/teams/android-launcher/merge/ub-launcher3-master_master_6782663.html

Change-Id: I649c4d931b84c1e8e22a58fa92b92c76f5222451
2020-08-21 14:35:09 -07:00
Sunny Goyal 63d327442c Disabling notification dots for Launcher3Go
Bug: 164457095
Change-Id: If751719a698785957d37b4656a0132d2b56b64f9
2020-08-19 17:04:38 -07:00
Mehdi Alizadeh 4595166bf5 Merging from ub-launcher3-master @ build 6767682
Test: manual, presubmit on the source branch
x20/teams/android-launcher/merge/ub-launcher3-master_master_6767682.html

Change-Id: I5e9c73a7ac3033fe82006c4bd72824f56b8988f8
2020-08-16 12:31:21 -07:00
Sunny Goyal 5fb83a47f2 Removing icon recents version
Change-Id: Ibdc88715e38590cedf8a7b5174061bb2c6ef9533
2020-08-14 10:49:19 -07:00
Greg Kaiser 1bab050df2 Go Launcher: Fix icon placement retention
We need dbFile set when MULTI_DB_GRID_MIRATION_ALGO is in
use.  This was set for other launchers, but not the Go launcher.

Bug: 157557047
Test: Built, flashed, moved icons on home screen, rebooted, and confirmed icons retained their position.
Change-Id: Icfcb56e00a8ac2f74e5f7a1957fd46cee5cb8b5b
(cherry picked from commit 8f490e21c9)
2020-07-07 16:32:54 +00:00
Greg Kaiser 8f490e21c9 Go Launcher: Fix icon placement retention
We need dbFile set when MULTI_DB_GRID_MIRATION_ALGO is in
use.  This was set for other launchers, but not the Go launcher.

Bug: 157557047
Test: Built, flashed, moved icons on home screen, rebooted, and confirmed icons retained their position.
Change-Id: Icfcb56e00a8ac2f74e5f7a1957fd46cee5cb8b5b
2020-07-07 04:58:57 +00:00
Rajeev Kumar e941d72380 Get rid of unused notification_badging_enabled configuration.
Bug: 159637333
Test: Manual tests by building system image and testing launcher app.
Change-Id: I0a7a3048ae6b4ffa52497748f45a6cf366fe0433
2020-06-22 20:16:49 +00:00
Rajeev Kumar 1a51e29ffe Disable notification dots launcher setting on Android Go devices.
Bug: 158805631
Test: Manual test by opening Launcher settings and verifying
notification dots is not shown anymore.

Change-Id: I7c31e5d85d8b9c0859d789de76d149a4013f7104
2020-06-18 04:25:38 +00:00
Tracy Zhou 10a285dc24 Render user's actual workspace in ThemePicker preview (Part 5)
This change takes care of rendering widgets using widget provider's layout info.

Test: manual
Bug: 144052839

Change-Id: I7002d8bf653513cdd317736d550a47f61f0ee474
2020-02-19 16:46:25 -08:00
Sunny Goyal 18204e4eea Various icon cache fixes
> Multiple instances of LauncherIcon created when
    LauncherIcons refers IconCache which in turn creates new LauncherIcons
> Widget icons are never cached as they were using low res icons
> Shortcut drag icons are not loaded synchronously
    when using PinItemRequest flow
> Wrong lastUpdatedTime is used in iconCache for shortcuts
> IconUpdateHandler does not ignore managedUser promise icons

Change-Id: Ie7eed68a30fad11d1861b6c70c380953a15ae1cf
2020-02-06 14:16:34 -08:00
Sunny Goyal a7a5bf3101 Adding support for multiple Model clients
Bug: 137568159
Change-Id: Ia4db800b19cc80c695fcb9ea28e07709dfd08c6a
2020-01-10 12:23:27 -08:00
Sunny Goyal 85cb1b65c2 Fixing widgets enabled ag/9375162
Change-Id: I2e7e731dacf3c617fc2abe4c5289519856d0c2a3
2020-01-07 20:32:40 -08:00
TreeHugger Robot f10903e601 Merge "Removing static reference of deep shortcut manager" into ub-launcher3-master 2020-01-02 20:54:05 +00:00
Sunny Goyal fa39536570 Removing static reference of deep shortcut manager
Bug: 141376165
Change-Id: Ie60b82be63a8926825598c681d8b2a1b2ace6413
2020-01-02 20:13:12 +00:00
Peter Kalauskas 0842cf5f9d Remove Launcher3GoIconRecents
Bug: 144129431
Test: Build and check that Launcher3QuickStepGo is used instead
Change-Id: Ib2a30c9e1e78de7792f34c3505372c8af1cb307d
2019-12-11 12:18:52 -08:00
Sunny Goyal 337c81f664 Removing static instances of UserManagerCompat and AppWidgetManager
> Changing the lifecycle to follow other static objects in Launcher
> Removing compat interface and inlining everything to helpers

Bug: 141376165
Change-Id: I82bd5db1969101de9a7eac77f32728d70195bb35
2019-12-11 10:03:19 -08:00
Tony Wickham 37a0970bf5 Improve quick switch from home by tracking both x and y motion
- Add NoButtonQuickSwitchTouchController which uses
  BothAxesSwipeDetector to track horizontal and vertical motion.
- Initially, we only detect swipe left to right to quick switch
  (like before), but then we allow swipe up to either go to
  overview (if you hold) or back home (if you don't hold).
- xDisplacement transitions non-overview components out (e.g. shelf
  and workspace), and translates overview in.
- yDisplacement translates overview up and scales it down

Bug: 126596417
Change-Id: Id679ad84c08246e205c667a78ed5df00d7276258
2019-11-14 15:50:18 -08:00
Tony Wickham 2785a5996c Improve quick switch from home by tracking both x and y motion
- Add NoButtonQuickSwitchTouchController which uses
  BothAxesSwipeDetector to track horizontal and vertical motion.
- Initially, we only detect swipe left to right to quick switch
  (like before), but then we allow swipe up to either go to
  overview (if you hold) or back home (if you don't hold).
- xDisplacement transitions non-overview components out (e.g. shelf
  and workspace), and translates overview in.
- yDisplacement translates overview up and scales it down

Bug: 126596417
Change-Id: Id679ad84c08246e205c667a78ed5df00d7276258
Merged-In: Id679ad84c08246e205c667a78ed5df00d7276258
2019-11-14 12:31:01 -08:00
Tony Wickham 42a9ef0e9f Move shelf peeking anim code to ShelfPeekAnim class
Bug: 126596417
Change-Id: I5ba501b04b3eaf12a20ba1312ef362f9734761c3
Merged-In: I5ba501b04b3eaf12a20ba1312ef362f9734761c3
2019-11-14 12:30:32 -08:00
Pinyao Ting 1397a42fc2 include predicted_rank in app launch logging
Test:
1. . build/envsetup.sh && tapas NexusLauncher
2. ccdebug && cclogcat
3. launch from workspace any app that is also in predicted apps
4. verify in terminal it has correct predicted_rank

Bug: 143855018
Change-Id: I07a62f07057537a6c09384cf944bbc5aa5888d22
Merged-In: I07a62f07057537a6c09384cf944bbc5aa5888d22
2019-11-13 01:15:37 +00:00
Pinyao Ting 2cf2871392 include predicted_rank in app launch logging
Test:
1. . build/envsetup.sh && tapas NexusLauncher
2. ccdebug && cclogcat
3. launch from workspace any app that is also in predicted apps
4. verify in terminal it has correct predicted_rank

Bug: 143855018
Change-Id: I07a62f07057537a6c09384cf944bbc5aa5888d22
2019-11-12 16:40:34 -08:00
Tony Wickham 85d6f25016 Move shelf peeking anim code to ShelfPeekAnim class
Bug: 126596417
Change-Id: I5ba501b04b3eaf12a20ba1312ef362f9734761c3
2019-11-07 15:21:23 -08:00
Jon Miranda 13a7980e09 System apps must target API 29 or higher
AndroidManifest.xml already updated

Bug: 143991628
Change-Id: Ia9ddeda016548a0ebe5c5ec527741a7a8f9c0e4d
2019-11-06 16:01:25 -08:00
Sunny Goyal 14168431bd Adding support for dynamic calendar and clock icons
Change-Id: Icdba34340a27a4f6dff7310d0bf9fd29aef1330c
2019-10-29 13:50:02 -07:00
Sunny Goyal 210e174c9c Subclassing Launcher instead of using UiFactory
Allows us to override only the required methods, instead of providing
a proxy method for everything

Change-Id: I816dcdb2a8d5432496050118ded0f2bbe7122cf7
2019-10-21 11:10:21 -07:00
Winson Chung dd9d1ea1bf 12/ Clean up some ActivityInterface calls
- Require users of the activity interface to go through the interface to
  get the raw activity
- Remove calls that pass in the activity since the interface already can
  get the reference to it internally (and the interface always has the
  reference before the caller)

Bug: 141886704

Change-Id: I13e52caba593db918e8a7764c751044142fe7ece
Signed-off-by: Winson Chung <winsonc@google.com>
2019-10-16 17:18:12 -07:00
Winson Chung c9bf6d45ac 9/ Clean up swipe shared state
- Add TaskAnimationManager which keeps track of the animation state whose
  lifecycle can be longer than the gesture.  Move some of the logic related
  to cleaning up old animations into this class (called when the state is
  shared across gestures).
- Instead of calling into the shared state directly via UIFactory, add
  callback to cleanup the animation and shared state from Launcher

Bug: 141886704

Change-Id: Ib6140b37162f7460a20fa1046cfd4f4068e4a1c6
Signed-off-by: Winson Chung <winsonc@google.com>
2019-10-16 17:17:34 -07:00
Winson Chung d7269bf8b6 8/ Rename ActivityControlHelper
- ActivityControlHelper -> BaseActivityInterface
  LauncherActivityControlHelper -> LauncherActivityInterface
  FallbackActivityControlHelper -> FallbackActivityInterface
  QuickCaptureTouchConsumer -> QuickCaptureInputConsumer
- Move gestures to use the activity interface from the gesture state

Bug: 141886704
Change-Id: I6f12daeb03d564143404767dfe4576e3e5da2a1d
2019-10-08 13:39:13 -07:00
Winson Chung d3da92ac66 7/ Rename RecentsAnimationWrapper
- Move the recents animation classes out of util into base quickstep pkg
- Clean up some local var names

Bug: 141886704
Change-Id: I1556179e203cbb43b77ea58e6fe520aa9944099b
2019-10-08 13:30:27 -07:00
Winson Chung 8ff53f7e65 4/ Move SystemUiProxy to its own singleton instead of routing through the model
Bug: 141886704
Change-Id: I415b9ef7b57b525407e3a341b946e3ca66125102
2019-10-08 13:15:13 -07:00
Winson Chung 75eb0e0f20 2/ Move device state logic to its own class
- Feed the class down to the input consumers and related gesture classes
  instead of specific sysui state flags

Bug: 141886704

Change-Id: I2ade7f48555c9d0ba0d3fac5c1f2dae694624224
2019-10-07 20:49:08 -07:00
Winson Chung 92a015f2fc 1/ Renaming some classes for clarity
- SwipeAnimationTargetSet -> RecentsAnimationTargets
- RemoteAnimationTargetSet -> RemoteAnimationTargets
- RecentsAnimationListenerSet -> RecentsAnimationCallbacks
- SwipeAnimationTargetSet.SwipeAnimationListener -> RecentsAnimationCallbacks.RecentsAnimationListener
- ClipAnimationHelper -> AppWindowAnimationHelper
- AssistantTouchConsumer -> AssistantInputConsumer

Bug: 141886704

Change-Id: I78485a1651bb360ffbac2d0c462855931a995ee1
2019-10-07 20:49:08 -07:00
Tracy Zhou c8611b3afe Merge "Live tile should switch to screenshot before finishing recents animation" into ub-launcher3-master 2019-10-03 00:08:09 +00:00
Tracy Zhou 387279d938 Live tile should switch to screenshot before finishing recents animation
Fixes: 139439373
Test: Launch a new app from shortcuts in Overview mode. Make sure the
live tile stays put (no hole). Same with touching empty space in
Overview to go home.

Change-Id: I6cacf2842e21f9856d0021cea9fddf4f870f09f0
2019-10-02 16:53:02 -07:00
Sunny Goyal e84c5b82be Unifying activity tracker callback
> Using a common class for both Launcher and RecentsActivity
> Removing static refenrece to LauncherModel and using a common pattern for
  tracking activities

Bug: 141376165
Bug: 137568159
Change-Id: Ic1897abe6913ec78e25725118eedf5b468d5ec70
2019-10-01 13:54:26 -07:00
Winson Chung 1b231ecc56 Updating launcher interface for recents animation change
Bug: 140626334
Change-Id: Ib8e837c157bb99db429b7936fdf111e05170ac25
2019-09-20 15:15:43 -07:00
Sunny Goyal 3e3d759db2 Removing flag overrides. All flags should be defined as togglable flags instead.
Change-Id: Ia7b9ff84413096cd5b0c4a9a81a232019f2522d2
2019-09-12 10:17:14 -07:00
Andy Wickham ddc9622e92 Reduces padding of the Overview shelf in no button mode.
Before: https://screenshot.googleplex.com/iw6baTCfoy2.png
After: https://screenshot.googleplex.com/8CcsQvLhYDo.png
Desired: https://b.corp.google.com/action/issues/139551306/attachments/26925873?download=false

Test: Examined before and after padding and verified 3-button is unaffected.
Fixes: 139551306

Change-Id: Ia416399cf25e7c6c2fb8aa84ad20e7ad74dcd31b
2019-08-29 11:11:12 -07:00
Sunny Goyal 6fe3eec95c Moving various common executors to a single location
Change-Id: I44bca49b8adb6fa22c3b48d10f674e42c28d792c
2019-08-20 14:36:17 -07:00
Pinyao Ting 49a3e699f9 show dot in deep shortcuts when notification contains exactly identical
set of person

Bug: 132336512
Change-Id: I975524e28168c10a186cdc24b188c161faf433cf
2019-08-05 20:41:58 -07:00
Becky Qiu 9c6cfb4e04 Fill the log container as hotseat or workspace based on position.
am: 84fa94e2fc

Change-Id: If9a5d88062addbd09909e04ef5c2c59e7e5488a7
2019-08-01 16:00:47 -07:00
Becky Qiu 84fa94e2fc Fill the log container as hotseat or workspace based on position.
Test: manual
Bug: 137953006

Swipe from workspace:
07-30 15:15:44.031  9779  9779 D UserEvent: action:FLING direction=UP direction=UP
07-30 15:15:44.031  9779  9779 D UserEvent:  Source child:WORKSPACE id=0 span(951,1313)	parent:WORKSPACE id=0
07-30 15:15:44.031  9779  9779 D UserEvent:  Destination child:ALLAPPS
07-30 15:15:44.031  9779  9779 D UserEvent:  Elapsed container 826 ms, session 9361 ms, action 0 ms

Swipe from hotseat:
07-30 15:15:46.010  9779  9779 D UserEvent: action:FLING direction=UP direction=UP
07-30 15:15:46.010  9779  9779 D UserEvent:  Source child:HOTSEAT id=0 span(786,1908)	parent:WORKSPACE id=0
07-30 15:15:46.010  9779  9779 D UserEvent:  Destination child:ALLAPPS
07-30 15:15:46.010  9779  9779 D UserEvent:  Elapsed container 1139 ms, session 11339 ms, action 0 ms

Change-Id: I959528889fda778efc569bb59e7f44d3bd5b81bc
2019-08-01 22:24:44 +00:00
Pinyao Ting 0cd5bd5f95 Ensure each dot contains only relevant notification to the shortcut
and displays system shortcut when long click on deep shortcut.

In this CR we
1) for each shortcut, we filters the notifications to ensure we only
 get notifications with identical shortcutId.
2) allow system shortcut to be displayed when user long click on a
DeepShortcut

Bug: 132336512
Change-Id: Idc9eaed55e900ed4027a43ee9c3fd7dc6f4480b2
2019-08-01 02:47:24 +00:00
Pinyao Ting bf608722b9 Ensure each dot contains only relevant notification to the shortcut
and displays system shortcut when long click on deep shortcut.

In this CR we
1) for each shortcut, we filters the notifications to ensure we only
 get notifications with identical shortcutId.
2) allow system shortcut to be displayed when user long click on a
DeepShortcut

Bug: 132336512
Change-Id: Idc9eaed55e900ed4027a43ee9c3fd7dc6f4480b2
Merged-In: Idc9eaed55e900ed4027a43ee9c3fd7dc6f4480b2
2019-07-31 23:56:54 +00:00
Pinyao Ting 4d1a0e2a7b show dot on shortcut when incoming notification contains exactly the
same shortcut id

Bug: 132336512
Change-Id: Iddf4cfe8ad60c12e8de8b171bed392f1bb0a6761
Merged-In: Iddf4cfe8ad60c12e8de8b171bed392f1bb0a6761
2019-07-30 19:39:10 +00:00
Pinyao Ting 559dd806d7 show dot on shortcut when incoming notification contains exactly the
same shortcut id

Bug: 132336512
Change-Id: Iddf4cfe8ad60c12e8de8b171bed392f1bb0a6761
2019-07-29 16:53:52 -07:00
Sunny Goyal 87dcde6d6c Separating apps list callback from model callback and simplifying various events
Bug: 137568159
Change-Id: I4d8bb5c01cabe642731ebd3f57fe15bdc5a569b7
2019-07-25 11:29:16 -07:00
Sunny Goyal 6d9eed757f Merge "Using the first frame delay based on the display refresh rate instead of hardcoding it to 16ms" into ub-launcher3-qt-r1-dev
am: b7094fcf36

Change-Id: Icd4e52b33b33718cb91b2fd082d85637e820390f
2019-07-24 12:57:15 -07:00
Sunny Goyal 4e6c45bcd3 Using the first frame delay based on the display refresh rate instead of
hardcoding it to 16ms

> Creating a utility class for caching display property changes

Bug: 128940249
Change-Id: I6f9a214548de65bd1c8530508d665ee88312da4a
2019-07-24 10:12:37 -07:00
vadimt d3c2a6cecf Fix waiting for launcher initialization
am: c8d496fe00

Change-Id: I7d764152d5d9da8c9df8db479dd01683d9e6148a
2019-07-18 19:10:06 -07:00
vadimt c8d496fe00 Fix waiting for launcher initialization
Bug: 137836033

Change-Id: Ifc8ce867abd85eaeacd09a2b39636ecc4109c046
2019-07-18 18:31:49 -07:00
Sunny Goyal 31ab19f71d Removing global state from DeepShortcutManager
This makes DeepShortcutManager thread-safe and avoids any locks

Change-Id: If4593b3541da6259591ff7a607efa58158006481
2019-07-17 15:16:33 -07:00
vadimt 853852351f Correctly restarting Launcher from OOP tests
Waiting for touch interaction service; waiting for package-restart
events.

Bug: 136215685
Change-Id: I0c31c09fe3a58b898168dfdb4e4d23757b94a47c
2019-07-11 14:17:06 -07:00
Sunny Goyal f11dd8e107 Using a higher priority executor than BackgroundExecutor for various recents tasks
BackgroundExecutor is also using thread pool executor where the order is perserved

Change-Id: Ieef8825599f35fe22da3e9adb1270c5525449d62
2019-07-11 09:38:54 -07:00
Sunny Goyal 4f2d926d42 Resetting UI state when the last has launched
Bug: 135038270
Change-Id: Ie0af9c7d47f69b32caedd72f98ed1706bdbef5fa
2019-06-28 14:50:24 -07:00
Winson Chung 0b70cd4ca4 Finish recents animation when starting a new activity
- Defer starting the activity when an activity is paused, and finish
  the current animation to trigger launcher to be resumed

Bug: 132811175
Test: Swipe up and launch a new app
Change-Id: I78b76800052512eb93f69ccf0523f4d752a82ece
2019-06-26 14:01:56 -07:00
Rajeev Kumar 8ca7205c24 Fix NPE in OverviewComponentObserver constructor while accessing activityInfo.
Bug: 132461400
Test: Manual tests
Change-Id: Icee3730454db8129e597714c147c2cbaddc70987
(cherry picked from commit 219208a0f5)
2019-06-25 20:55:53 +00:00
Tony Wickham 59c6901823 Some improvements to home to overview transition for 0 button mode
- Peek in overview further, and with more overshoot
- Fade out and scale down workspace faster while swiping up
- Scale and translate workspace slower when letting go to enter
  overview (so it doesn't zoom out at warp speed)
- Fade in all apps shelf sooner

Bug: 132455160
Change-Id: Ieafad0ccf9bb587889bc35d536627661db10e358
2019-06-19 14:48:57 -07:00
Tony Wickham e8836dc082 Gracefully handle failed task launches during quick switch
When quick switching from home or overview, go to OverviewState if the
task launch failed. Otherwise we get stuck in BackgroundAppState.

Bug: 135038270
Change-Id: I42785c261cef0df95666bc106ec5ca6ef0553cc7
2019-06-12 15:24:58 -07:00
Tony Wickham a04e746e84 Fix getting stuck in BackgroundAppState for 2-button mode
When ending in recents, we reapply the state - therefore, it's important
to make sure we are in OverviewState before onSwipeUpComplete(). This is
done by mLauncherTransitionController, which sets OverviewState on end.
We already force mLauncherTransitionController to end before calling
onSwipeUpComplete(), but in this case we were calling cancel() and
setting mLauncherTransitionController = null, which meant we could never
call end() on it. Instead, we should always call end() if we set it to
null.

Also ensure mLauncherTransitionController is created even if the gesture
is completed, if an existing controller isn't already running. This can
happen if you swipe up quickly enough that we get onGestureEnd before
launcher is drawn, and in that case we still want the launcher component
to animate once its ready. This is even more important for 2-button
mode, because again, we rely on mLauncherTransitionController to set the
state to OverviewState before we reapply it.

Finally, clarified some methods by renaming "swipeUp" to
"swipeUpToRecents".

Bug: 132757019
Change-Id: Ieb24a4f36a39780e5d64d7bc312791608db474d1
2019-05-31 16:11:40 -07:00
Kevin 3c7d5fb9db Recents Go: Conform to device default style
System apps in Q should attempt to conform to device style, so naturally
Recents Go should also conform to this so that text changes with the
device style changing. This CL ensures all text views change font based
off system theming title fonts.

Bug: 131839392
Fix: 131839392
Test: Change device theme body font, see that change is propogated to
Recents Go app texts, clear all, and empty recents message
Change-Id: Ib85ff49383221ef18ed8aa9e53eff129129e37c2
2019-05-22 13:39:32 -07:00
TreeHugger Robot d2e40927a7 Merge "Scale down thumbnail with app surface" into ub-launcher3-qt-dev 2019-05-14 23:26:46 +00:00
TreeHugger Robot 512a3c59ea Merge "Fallback recents should wait for remote anim ready" into ub-launcher3-qt-dev 2019-05-13 19:21:04 +00:00