Commit Graph

203 Commits

Author SHA1 Message Date
Zak Cohen 418b9bc5fc Adapt the task footer container to be a named container.
Bug: 126744445
Test: manual
Change-Id: Id00ffac4581bbbe5dfd73a63b05c4512394745c1
2019-05-20 10:44:20 -07:00
Zak Cohen 1159c9c18a Moves proactive hints and wellness toast into a linear layout.
This ensures that they do not fight for the space. This is intended to
be iterated upon as we find solutions to some of the technical
challenges in the current POR.

Change-Id: I831e8797b16f28fe2cd742c96e9b7c916abf77a5
2019-05-15 15:47:58 -07:00
Perumaal S 64941fd9c6 Add proactive hints container
This replaces all other chips containers and causes minimal
layout overhead: It is strictly within the task itself and
causes zero jank or space issues.

Screenshots:
https://drive.google.com/corp/drive/folders/1-3ZNCJtWc9_cgmP1nNd8U1yvpCr6GGoq
Test: manual
Change-Id: I5e22a34c4dc1ac3e73c4d5c913befc2360cb388e
2019-05-12 14:56:25 -07:00
TreeHugger Robot 0f07b87420 Merge "Import translations. DO NOT MERGE" into ub-launcher3-qt-dev 2019-05-10 07:34:58 +00:00
Bill Yi 229ecc4224 Import translations. DO NOT MERGE
Auto-generated-cl: translation import

Bug: 64712476
Change-Id: Iee3e02b60f19e7230c327b7bfe324ba72195de01
2019-05-09 23:30:10 -07:00
Tony 918863083b Add ScreenPinnedInputConsumer
When screen pinning is active, swipe up and hold to stop it.

Bug: 130828539
Change-Id: I343050d2a224ac723143cd3be4f78bc321f1a026
2019-05-09 18:10:10 -05:00
Sunny Goyal 69300227c4 Adding support for blocking gesture nav on a particular activity
Bug: 129796627
Change-Id: I939598f62924fb113e913e0309247d8a2088bf8a
2019-05-02 13:02:22 -07:00
Tony bbea105be0 Move logic that overrides MotionPauseDetector to callers
There are 2 conditions that we force the MotionPauseDetector to treat
the motion as not paused:
1. If we haven't passed a small displacement (48dp before, 36dp now)
2. If we have moved mostly orthogonally

These existed soley for the OtherActivityInputConsumer case, because
1. We only need the displacement requirement to make room for the
   peeking shelf, which doesn't exist in other cases (it's already there on
   home for example)
2. We can only move orthogonally for quick switch, which again doesn't
   exist for other users of MotionPauseDetector.

So now instead of checking min displacement and orthogonal distance
inside MotionPauseDetector, we let callers setDisallowPause()
before adding positions to their MotionPauseDetector.

The only user visible change is that you no longer have to swipe up 48dp
before we allow pause to overview from home. This also paves the way to
using the same logic that determines to disallowPause to also detach
recents from the window while swiping up from an app.

Bug: 129985827
Change-Id: Ie690aa314da3260aff2209341a29638604f9501c
2019-04-24 16:10:40 -07:00
Adam Cohen 9bc1431f37 Additional Assistant gesture tuning
=> Using the drag slop (currently 10dp), which is the appropriate slop when comparing to the other gestures. Touch slop (which was being used for the Assistant) is only being used for gestures starting from the back button. This means that the delegate was getting triggered much too often (unfair slop competition). This prevents that.

=> Fixed additional bugs with the consumer delegate / sharedState; the shared state notion really only applies to the OtherActivityInputConumer, and it wasn't being propagated from the AssistantConsumer.In addition, the isActive() method is only being used as a proxy for whether or not to use the shared state, so clarified the naming. This fixes another case where touch could become completely stuck and you could no longer swipe up.

=> Modified the effective angle to be 90 degrees down to 20 above the horizontal.

=> Reduced the drag threshold to 55 dps.

=> Known issue: the time threshold requires motion events to be triggered. In practice, this works because the finger doesn't stay completely still, but we should add a timer to update the progress smoothly.

=> Removed pause detector.

Change-Id: Ie23e836c6d778914594774b830c3cd2e7b94eca4
2019-04-24 16:46:03 -04:00
Sunny Goyal 77b3419ad5 Adding support for showing predicted apps as a floating row in all-apps
and overview

Bug: 130053407
Change-Id: Idb93a0ba6cfea8406f75ab86d9e0acde2fc04b3a
2019-04-23 14:26:44 -07:00
Adam Cohen b117707d31 Tune Assistant Gesture
=> bumping detectable region to 48 dp horizontal + vertical within corner
=> centering detectable angle;  total 70 degrees (ie. btw 10 off the vertical and 10 off the horizontal)
=> pilfering touch events when slop is passed and assistant gesture is engaged
=> Fixing issue where we were incorrectly using “sharedState” causing incorrect handling of gestures subsequent to AssistantTouchConsumer being invoked (it was forgetting to clear it’s input state and hence reporting “active” when it wasn’t). The symptom was that gestures after the AssistantTouchConsumer would never actually move the active window even though state was being updated; you’d feel the Overview haptic.
=> Devices with large corner radii are still somewhat problematic as the initial touch down often lands high on the display (ie. above the 48 dp region).

Change-Id: I3d5761112f4cb8b7b1eee987de5afe9aee260304
2019-04-18 12:54:28 -07:00
Hyunyoung Song a19584d820 Change default icons for launcher [3/3]
Bug: 126738409
Bug: 129955150
Change-Id: I9daf5bd253dc72c99ab3a466766a4d30a95d0952
2019-04-13 00:51:33 -07:00
Hyunyoung Song 7924a3c97a Change default icons for launcher [2/3]
Bug: 126738409
Bug: 129955150
Change-Id: Ia140c5d16b74e4719131aa5035313b7b27028ad1
2019-04-12 16:19:53 -07:00
vadimt c6d9ddfddb Removing hourglass_bottom
Now that we don't show DWB toast for negative remaining time

Bug: 127689526
Change-Id: I3ced3ec0da9bd7b09df9b66b4ef608e87339573f
(cherry picked from commit e921bacfb8)
2019-04-12 19:27:17 +00:00
Hyunyoung Song 052624d897 TaskCornerRadius should not use dialogCornerRadius on devices not supporting rounded corners
Bug: 123985787

Change-Id: I4ffe06362256d4cc83bbe34c139d71ea1f6ca92e
2019-04-10 14:29:36 -07:00
Tony Wickham 5e29395eba Merge "Swipe up on nav bar to go home from -1 and widgets" into ub-launcher3-qt-dev 2019-04-09 18:14:15 +00:00
Tony Wickham 9791bd1555 Swipe up on nav bar to go home from -1 and widgets
More specifically, any window (e.g. qsb search) or AbstractFloatingView.

NavBarToHomeTouchController now implements TouchController directly instead
of AbstractStateChangeTouchController, as it not only dealing with
launcher states. This makes it easier to override intercept logic to
handle cases like not having window focus, for example.

AbstractFloatingViews can createHintCloseAnim() to play an animation
hinting that it is about to be closed by swiping up. Widgets sheets use
this to pull back similar to the all apps transition to home.

Bug: 129976669
Change-Id: Ie157b978d9f1ee36d5fd32cea72ec02ce40878c0
2019-04-09 10:53:24 -07:00
Hyunyoung Song 2aec9c42f5 Change task view / all apps/ widgets / folder radius to dialogCornerRadius
Bug: 123985787
Change-Id: Iaa8088beb51d37dba90d57ad065f9eac0dd46270
2019-04-09 00:27:07 +00:00
Tony 1787ee9596 Peek overview on motion pause, then animate fully on touch up
Add AnimationComponents.ATOMIC_OVERVIEW_PEEK_COMPONENT, and rename
previous ATOMIC_COMPONENT to ATOMIC_OVERVIEW_SCALE_COMPONENT.

When SWIPE_HOME is enabled:
- Overview lives to the left of Workspace, which is encoded in
  LauncherState.NORMAL.getOverviewScaleAndTranslation().
- Create atomic animation based on ATOMIC_OVERVIEW_PEEK_COMPONENT
  and OVERVIEW_PEEK state when swiping and holding from home screen.

Bug: 111926330
Change-Id: Iab6dbef7238dae15b3036d4b2a026b781eee6b4b
2019-03-27 19:45:04 -05:00
Bill Yi 3092a21532 Import translations. DO NOT MERGE
Change-Id: I3bfe6c1b97612ecc829e361fc70d98b9318da417
Auto-generated-cl: translation import
2019-03-26 22:14:07 -07:00
Bill Yi 56635d4f85 Import translations. DO NOT MERGE
Change-Id: Ibed07a95d0eb703afc04a19e9c0018944ffaf9f7
Auto-generated-cl: translation import
2019-03-23 08:05:19 -07:00
vadimt 0ed1797fad Removing graying apps in Overview
The reason is that there is no API that reports that an app is grayed.
Not showing DWB toast for apps that ran over their limit because they
shouldn't be in Overview.

Bug: 129067053
Change-Id: Ia04e17aa85ca015b7932496ad5e730fe61b4be69
2019-03-22 12:17:48 -07:00
Matthew Ng a3b03418c1 Moved assistant gesture to corners
The corners will be separated with quick switch by detecting at the slop
of the angle from touch down to that position. If over 30 deg then
assistant will be tracked otherwise quick switch while swipe up will not
be tracked at all.

Test: manual
Bug: 112934365
Change-Id: I6a3aeb1509d9706696a30ef1fba3ce7e3e5ec07c
2019-03-18 14:53:11 -07:00
Tony Wickham 7550c1227e Merge "Fix some issues with MotionPauseDetector" into ub-launcher3-master 2019-03-05 22:00:24 +00:00
Matthew Ng 077c29e091 Added assistant gesture swipe up right side region on nav bar
Bug: 112934365
Test: manual
Change-Id: I467e71f13da4afba3a556fafb0bfdf01650ab4bf
2019-03-01 13:53:13 -08:00
Tony Wickham ac60d91cec Fix some issues with MotionPauseDetector
- Orthogonal displacement now checks angle instead of fixed amount
- Only allow timeout when passed min primary displacement and not
  orthogonal displacement
- Don't set timeout for !SWIPE_HOME, which should never detect pause

Change-Id: I3d810831316affff138968dfc62b921b20c752c5
2019-02-27 16:40:59 -08:00
Kevin 750bbe08da Implement fallback recents activity for Go
Implement recents activity for Go for when the default launcher does not
have recents implemented. To do this, we factor out some common recents
activity functionality from RecentsActivity and extend it to make a Go
specific activity that pops in the icon recents fragment.

Bug: 114136250
Test: Manual test NexusLauncher and Launcher3QuickstepGo by installing a
quickstep-less launcher and setting it to default
Change-Id: I936568489e8966da4a62e4b779ae660a220f2aeb
2019-02-19 14:12:42 -08:00
Bill Yi 2c3aa0c0cf Import translations. DO NOT MERGE
Change-Id: Iff9eaa06498b8641ac0225f0b9c778db8b926189
Auto-generated-cl: translation import
2019-02-02 00:41:03 -08:00
TreeHugger Robot 80748ae6f4 Merge "Increasing char limit for string, per localization request." into ub-launcher3-master 2019-01-30 21:28:19 +00:00
TreeHugger Robot 5b1cd9cecb Merge "time_left_for_app: increasing limit" into ub-launcher3-master 2019-01-30 21:28:17 +00:00
vadimt 5c749392bd time_left_for_app: increasing limit
Bug: 123638440
Change-Id: I20a444edfdad737206fcbcb9ab5c2b7c1d1973da
Tests: emulated a string with this size
2019-01-30 13:17:36 -08:00
vadimt 21550b4673 Increasing char limit for string, per localization request.
Bug: 123638453
Change-Id: I40aea84f88cb91e4cd123fa0181894867c0e02f7
Tests: none
2019-01-30 13:04:07 -08:00
Tony Wickham 42dec18638 Merge "Make quick switch ("hook") more reliable" into ub-launcher3-master 2019-01-30 19:56:23 +00:00
TreeHugger Robot abdb80a6d0 Merge "Adding dismiss-all method" into ub-launcher3-master 2019-01-30 19:06:06 +00:00
vadimt 8ac8d29121 Adding dismiss-all method
See the bug.

Bug: 123259701
Change-Id: I4b41d2cfe14c53db1a99cb6a693d3047057fa925
Tests: testOverview
2019-01-30 10:36:52 -08:00
Bill Yi 2aeee4ba55 Import translations. DO NOT MERGE
Change-Id: Ic9282c2ed62a6ac88e8e61f309f1dfffdf1e487a
Auto-generated-cl: translation import
2019-01-29 19:35:37 -08:00
Tony Wickham 023f404a12 Make quick switch ("hook") more reliable
- Add max orthogonal displacement to MotionPauseDetector to avoid
  pausing when swiping left or right
- When gesture in ambiguous between swipe up for home or swipe over
  for the new task, base the decision on the faster velocity component
- Disable recents freescroll mode when dispatching motion from the nav
  bar. This way recents handles it naturally and we don't need custom
  logic to snap to the next page at the end of the gesture.
- Fix a bug where you couldn't hook to start a new task when SWIPE_HOME
  was disabled

Bug: 111926330
Change-Id: If63aa2bb32b57c3f401c5df8b3f6f4efec97b1fa
2019-01-29 17:11:12 -08:00
Tony Wickham 18759647f0 Swipe up to go home, swipe and hold to go to overview
- Pause (swipe and hold) detection based on velocity and acceleration,
  so it feels immediately responsive
- Don't show shelf during swipe; peek when swipe pauses
- Disallow long swipe
- If swiping to go home (we didn't detect a pause), animate window and
  launcher together (not final animation, but mechanism is in place)
- Guarded by SWIPE_HOME flag

Bug: 111926330
Change-Id: Ie4af04517c6688e3d649c2971a1aad197837cb3b
2019-01-28 11:37:33 -08:00
TreeHugger Robot 90048de773 Merge "Disable window corner rounding on some devices" into ub-launcher3-master 2019-01-25 00:31:52 +00:00
Lucas Dupin a2074857dc Disable window corner rounding on some devices
Bug: 122347746
Test: visual; on taimen, marlin and walleye
Change-Id: If6ac1c75297dd25ad40d3ec61537e8793bceceb7
2019-01-24 16:19:49 -08:00
TreeHugger Robot f81da5f4ee Merge "Removing querying whether DWB time limit is for a group" into ub-launcher3-master 2019-01-24 23:07:48 +00:00
vadimt d4c45e8104 Removing querying whether DWB time limit is for a group
This API is removed for Q.

Bug: 118319143
Test: Manual
Change-Id: I1605ba14a914bfe018c4a2f6d974afaea7e51e05
2019-01-24 13:52:49 -08:00
Kevin c4ad03b9ef Split LauncherAppTransitionManagerImpl for Go
Split LauncherAppTransitionManagerImpl common functionality into a base
quickstep app transition class and subclass for recents-specific
implementation. In addition, override the app transition manager to the
appropriate manager depending on the build.

Bug: 114136250
Test: Manual test NexusLauncher, Launcher3GoWithQuickstep
Test: Build Launcher3GoIconRecents
Change-Id: Iab1b5ae0c75af276879d5e12df95f62a514bf571
2019-01-23 14:59:19 -08:00
vadimt 534178c926 Using hourglass icons for DWB toast
Bug: 118319143
Change-Id: I67018db3ceb8b6c0d863a46c9a9148013c68c1f7
Tests: Manual
2019-01-18 12:50:08 -08:00
vadimt 759db43f3b Implementing available part of UX spec for DW toast
See https://docs.google.com/presentation/d/1AepsnLeKcRhjMW35SkB5yMKO3u6waigug8Tyfe0LO5o/edit#slide=id.g4c5ab81849_0_0

Also using time formatting code copy-pasted from Google DWB app.

Bug: 118319143
Tests: Manual
Change-Id: I84392d7655f402e38cf4c46ae530d06f755a7df8
2019-01-17 12:57:02 -08:00
Sunny Goyal 9e4b32f6a3 Recycling taskViews instead of inflating & throwing them away everytime
Bug: 122345781
Change-Id: If86d22729a42b8d5200f24dbf37a568fb9b11a5b
2019-01-10 23:11:52 -08:00
Kevin 2f6cb3167d Add icon recents fragment for IconRecents
Split out overview_panel from recents and override it with IconRecents
version to replace the recents view entirely.

Currently, on the IconRecents build variant, as expected, this hits a
class cast exception since many quickstep classes assume the overview
panel is an instance of RecentsView. All other variants build and push
fine.

Bug: 114136250
Test: Build + push NexusLauncherDebug, Launcher3Go,
Launcher3GoQuickstep, Launcher3GoQuickstepIconRecents
Change-Id: I3ac7331772e53ee81cb1735a709b4fb7b3bdb78c
2019-01-08 09:55:13 -08:00
Hyunyoung Song 339a311d99 Cleanup strings for iconoverride
Bug: 120736782
Change-Id: I9745fe999cec3c4e1f442decb482ed916d0b871a
2018-12-26 20:59:57 -08:00
Bill Yi 80f5c19fd2 Import translations. DO NOT MERGE
Change-Id: I1539df9cc5f5633585a5714fc8069163d7edb951
Auto-generated-cl: translation import
2018-12-11 10:47:07 -08:00
Winson Chung 5466f284f3 Merge changes from topic "rounded_corners_ub_launcher" into ub-launcher3-master
* changes:
  Revert "Revert "Correct 🕳️ 👊👊👊👊👊👊""
  Revert "Revert "Rounded corners on app transitions""
2018-12-06 19:58:25 +00:00