Commit Graph

174 Commits

Author SHA1 Message Date
Suphon Thanakornpakapong
28df5361d4 Fix build 2022-05-08 21:31:31 +07:00
Tony Wickham
1a2d581cf0 Only inset IME by 48dp instead of 60dp when taskbar is present
- Update providedInternalImeInsets whenever taskbar height changes, since the insets are subtracted from the taskbar window height. This ensures the IME always has the same bottom inset (48dp) regardless of taskbar's window size
- Also translate nav buttons down to center in the new size when IME is showing

Test: Open IME from home and in apps, both in gesture nav and 3 button mode. Ensure IME bottom inset is always 48dp and nav buttons center within that space
Fixes: 201115344
Change-Id: I5ed25b0ffc08145b2221cc5c960e669cc21b2aa7
2021-12-09 22:17:21 +00:00
Alex Chau
992db75dae Use percentage scaling for overview thumbnail size
- Limit overview to screen ratio to be at max 70%
- Tuned row spacing and page spacing
- Added 2 more test activities to testOverviewForTablet to avoid dismissing tasks at end of grid, as more grid tasks are now shown

Bug: 207350366
Test: manual
Change-Id: Id04871464bdb3ef2d6b046977b0ffd9bd51bc230
Merged-In: Id04871464bdb3ef2d6b046977b0ffd9bd51bc230
2021-12-07 14:50:40 +00:00
Alex Chau
1bf0fe1b70 Add back screenshot button to Launcher3
- Also make spacing between buttons always 36dp
- Updated screenshot button image for Launcher3

Fix: 208384949
Test: Start overview in Launcher3WithQuickStep, test screenshot button is working
Change-Id: Ieb60ce134813202c1d14137fff0a131e1f5f8c96
2021-12-03 12:32:29 +00:00
Thales Lima
45f2306ce9 open grid task menu to the right of icon
This makes the TaskMenuViewWithArrow open to the right of the icon if
there is enough space, and to the left if not. It also works correctly
in RTL, inverting the side to open by default.

Bug: 193432925
Test: open Overview and tap the app icon
Change-Id: Ib1098f48ed28d2e0758fb0e3fb733e86271fa1a0
2021-11-18 12:01:16 -03:00
Thales Lima
c335ad28a2 launcher: use a different task menu for foldables
Foldables use a different menu from phones, positioned either to the
right or left of the app icon, and display an arrow. Since TaskMenuView
is very specific for handhelds, it was cleaner to create another class
to handle foldables case extending from ArrowPopup.

This creates a working menu, the correct style will come in later CLs.

Bug: 193432925
Test: open Overview and tap the app icon

Fixes: 205298731
Test: atest NexusLauncherTests

Change-Id: I7a5c1fb4800a309f40fadb2df0f6c3a4c3f42679
2021-11-10 17:30:13 +00:00
Greg Kaiser
5b4145e34b Merge "Revert "launcher: use a different task menu for foldables"" into sc-v2-dev 2021-11-05 16:19:43 +00:00
Greg Kaiser
24898d3be0 Revert "launcher: use a different task menu for foldables"
This reverts commit 10eb3cd98b.

Reason for revert: Root cause of P0 b/205278434
Bug: 205278434
Bug: 193432925
Test: Local reverted and now launcher works on wembley

Change-Id: I3605c01066a3ce383d45e0a938f1e00b3c7f7bb9
Merged-In: I5ee18d3ee1b671fcaedda633e7a268addd5c5c15
2021-11-05 16:19:05 +00:00
Alex Chau
67ddd0fefd Merge "Update overview clear all button to be larger" into sc-v2-dev 2021-11-05 11:49:56 +00:00
Thales Lima
10eb3cd98b launcher: use a different task menu for foldables
Foldables use a different menu from phones, positioned either to the
right or left of the app icon, and display an arrow. Since TaskMenuView
is very specific for handhelds, it was cleaner to create another class
to handle foldables case extending from ArrowPopup.

This creates a working menu, the correct style will come in later CLs.

Bug: 193432925
Test: open Overview and tap the app icon
Change-Id: Icb068954e1e20a52d80c16c52d8e38ce9a181a8b
Merged-In: Icb068954e1e20a52d80c16c52d8e38ce9a181a8b
2021-11-04 16:40:37 +00:00
Alex Chau
56bd257478 Update overview clear all button to be larger
- Tuned the size and corner radius
- Tuned the margin from screen edge
- Tuned the vertical position

Bug: 204153113
Test: manual
Change-Id: Ibf3df599b31c7ecc2c9c951fc89e7e09c90253ef
2021-11-04 16:02:17 +00:00
Nick Chameyev
5f11bf60a8 Do not use shared lib resources
Temporary removes usages of SysUI shared
resources as it leads to crashes in Launcher
tests.

Bug: 204727471
Test: install launcher, try autorotate suggestion
Change-Id: I1e3c1f5b331a22a753acc3fe0ee544d50fba5c18
2021-11-01 15:49:54 +00:00
TreeHugger Robot
3edb8de094 Merge "Add mock animated taskbar to gesture nav tutorial for foldable devices." into sc-v2-dev 2021-10-27 17:45:38 +00:00
Sunny Goyal
eed4bbfb49 Using a different transition for All-set activity
Bug: 201797003
Test: Manual
Change-Id: I33b342ca224ab283e2ac475d4defe2eac6a87bb8
2021-10-26 11:25:32 -07:00
Schneider Victor-tulias
e61fd5f316 Add mock animated taskbar to gesture nav tutorial for foldable devices.
Bug: 198434693
Test: launched and completed tutorial on regular phone and foldable device.
Change-Id: Id378e9bdd21fdfbc880ef528cb040b6390699d43
2021-10-20 16:16:10 -07:00
Schneider Victor-tulias
b4307ff8aa Merge "Update gesture navigation tutorial with new specs for foldable devices." into sc-v2-dev 2021-10-19 17:59:31 +00:00
Vinit Nayak
74b25ca266 Align 3 button nav with hotseat
* Animate translationY alongside icons
* When device rotates on home, update
translationY
* Add padding to contextual buttons to center
it

Bug: 189807374
Change-Id: I149ef25df570fb1fd385f1da960c827105ff975d
2021-10-14 18:32:35 -07:00
Schneider Victor-tulias
97b85ee6cb Update gesture navigation tutorial with new specs for foldable devices.
- Added new layout files for mock screens.
- Added new mock hotseat

Bug: 198434693
Test: launched and completed tutorial on regular phone and foldable device.
Change-Id: I1ad04f9e8e3a012528d6fd8fbaa0366687c65d06
2021-10-14 12:37:34 -07:00
Schneider Victor-tulias
ab60c1fc6e Update gesture navigation tutorial for foldable devices.
- Updated mock conversation layout to work on large devices.
- Added AnimatedTaskView helper view to animate previous task view.
- Added animation from single previous app to two peaking previous apps.
- Updated app orientation to work with larger screens (forced protrait was causing letterboxing).

Test: manual, tested tutorial on non-foldable device, foldable device (closed, opened in landscape, opened in portait and switching between the three)
Bug: 198434693
Bug: 187701213
Known issue: 200579260

Change-Id: I98cb269f7d25985989cf66e791bf535228ab5293
2021-09-27 19:55:53 +00:00
Andy Wickham
768e686466 Merge "Makes All Set layout more responsive." into sc-v2-dev 2021-09-23 23:12:44 +00:00
Andy Wickham
13c3f31a0d Makes All Set layout more responsive.
- No longer forced portrait mode
 - Bottom texts are aligned proportionally to the screen height
   to avoid overlapping in landscape folded
 - Subtitle text width is limited to force wrapping to avoid an
   awkward line of text on wider screens

Fix: 189896987
Bug: 187701213
Test: Manually went between portrait/landscape/folded/unfolded.
Change-Id: Ibb2bbe545cf7f154ad77e10d574e72f8d9110a72
2021-09-23 23:11:59 +00:00
Vinit Nayak
9e6a642d8b Shorten and center TaskMenuView for landscape
* The width of the task menu view for landscape
(both fake and real) is the same as the width
it would be in portrait.
* With the shorter width, we also center the
positioning of the TaskMenuView
* Note this is only for phone, large screen
changes TODO

Bug: 193432925
Test: Tested real/fake landscape + seascape,
view is centered. Portrait same as before.

Change-Id: Ide41e252a3c177c4a911aab544f78930fed2e76f
2021-09-22 14:55:29 -07:00
Vinit Nayak
fd5e2ff933 Merge "Show all nav buttons when IME showing" into sc-v2-dev 2021-09-08 21:44:01 +00:00
Vinit Nayak
7f4f499515 Show all nav buttons when IME showing
* Keep home and recents button, and rotate back button
to be down when IME shows in 3 button task bar.
* Move IME switcher to left side of taskbar for 3 button,
keep on right side for gesture nav.

Bug: 191399224
Test: Tested RTL and LTR, gesture + button nav
with and w/o IME.

Change-Id: I7959d26986e546596e2436b8b5eb7668f44b55cf
2021-09-07 14:43:17 -07:00
Winson Chung
543c226ffa Provide internal IME insets
Bug: 197727397
Test: Collapse taskbar, open IME
Change-Id: Ia251be1d5892a58b062f241bdafc5dbfc223e4c3
2021-09-03 10:22:56 -07:00
Tony Wickham
31f787d352 Add "wave" animation when entering taskbar edu
Each icon scales and translates up, then back down. If the icon is predicted, it also plays a "slot machine" animation through random icons from AllAppsList.

Test: Visual
Bug: 180605356
Change-Id: Ia41cb0e340347eea6b580d23c8a2386837e9c399
2021-08-26 13:00:43 -07:00
Alex Chau
2683bd7728 Merge "Support different task icon margin for grid tasks" into sc-v2-dev 2021-08-18 08:41:42 +00:00
Alex Chau
eaa6d682d4 Support different task icon margin for grid tasks
- Focused and non focused grid now have differnt margin between icon and snapshot
- The overall margin above snapshot is still the same
- Invoke updateChildTaskOrientations when focus task changes to update the margin
- Also lowered the row spacing according to spec

Bug: 194194694
Test: manual
Change-Id: I25267bef19d5a8b1dc1cf96fc1babdc3ebc39330
2021-08-17 18:33:21 +01:00
Andy Wickham
13f3ffed95 Adds initial Taskbar Edu implementation.
Currently it just pops up with one placeholder image for splitscreen.
The Next button doesn't do anything.

Screenshots:
Light: https://screenshot.googleplex.com/B27CwBcwobHTghN.png
Dark: https://screenshot.googleplex.com/48EuJZv8evd5RGW.png

Known issues:
 - Back gesture is picked up behind by the app behind the taskbar.
 - When the flag is enabled, the Edu shows up each time you open
   an app, rather than only the first time.

Bug: 180605356
Test: Manual
Change-Id: Ifba9aa59abf1501b5f8ddebb3fcc13df85f6efaa
2021-08-17 09:57:47 -07:00
Alex Chau
ac9df38e9f Make icon drawable for non-focused grid tasks smaller
- Center the icon drawable in center of IconView with and allow a smlaler size to be set

Bug: 194194694
Test: dismiss focus task, swipe from app etc.
Change-Id: I2855249b13e2ccdb45f101bfb7afef4311f7b46f
2021-08-03 17:36:15 +01:00
Alex Chau
5fd9d491b0 Tune Overview size according to VisD
- Removed modalTransformY as overview actions no longer need to move in modal view
- Moved row spacing and page spacing to DeviceProfile
- Added several tablet / orientation specific DeviceProfile params

Bug: 194194694
Test: Manual
Change-Id: Id5435e7f6fc1b6fb7c0e55e55fa240cf84c4d6da
2021-07-26 12:01:30 +01:00
Vinit Nayak
7903758d08 Animate SplitPlaceholderView when entering split from overview
Bugs tracked in b/181704764

Bug: 181704764
Test: Tested on phone and large screen in multiple orientations

Change-Id: I07509006ae3d1f4425dc5119d0c8ed52b41a3bc2
2021-07-22 20:12:26 +00:00
Pat Manning
3786fa188d Scale recents during quick switch for large screens.
Test: manual
Fix: 192470757
Change-Id: I4522455e488213a6f461549a31e78edef35aac21
2021-07-21 17:43:04 +00:00
Vinit Nayak
9241fe62d1 Merge "Set correct divider dimension for task menu options" into sc-dev am: 7d0826f3d1
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15164589

Change-Id: Ia48a1e6b2ebab8f94f374d0c4369bf4b62d13bea
2021-07-07 20:13:15 +00:00
Vinit Nayak
7d0826f3d1 Merge "Set correct divider dimension for task menu options" into sc-dev 2021-07-07 19:56:56 +00:00
Sunny Goyal
2e5176e51f Merge "Fixing some dimentions in AllSet activity" into sc-dev am: f3d3dcf4a1
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15160037

Change-Id: I3e8d01451a9ad4b14128bf90a9d758e922d04f4e
2021-07-01 18:32:02 +00:00
Vinit Nayak
837359b1ea Set correct divider dimension for task menu options
Previously divider drawable dimension was set on height,
which only works when things are divided vertically.
For horizontal layouts, we need to set divider width.

Bug: 192398954
Test: Tested portrait + fake/real landscape
+ tablet

Change-Id: I5a63df9749bf37c3a563e923a1b4724aa17d9409
2021-07-01 02:05:42 +00:00
Sunny Goyal
25f386edc8 Fixing some dimentions in AllSet activity
Bug: 192412172
Test: Manual
Change-Id: I599c858fc21d45dd41eaa01ff3d91863d52f6ae8
2021-06-30 12:19:30 -07:00
Vinit Nayak
69a7768ea6 Merge "Add rounded corners to TaskMenu Items" into sc-dev am: 646fdb802e
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/15084517

Change-Id: Ida241e8f5d6293ccd7e2dec7524b27c9aaa94bdb
2021-06-24 20:24:17 +00:00
Vinit Nayak
d86a9948f9 Add rounded corners to TaskMenu Items
Bug: 188168717
Test: Manual
Change-Id: I7cce42fb08f03a9689b4c5d56ed8208d6f60f7d7
2021-06-23 23:16:01 +00:00
Tony Wickham
3fd22847ac Initial commit of taskbar stashing
- Added StashedHandleViewController to provide properties such as ViewOutlineProvider to animate the handle that's shown in place of taskbar while it's stashed
- Added TaskbarStashController to coordinate the stashed state, including orchestrating the animation across taskbar controllers
- Added TaskbarStashInput consumer to detect long press in the nav region when taskbar is stashed

Behavior:
- Long pressing taskbar background animates to the stashed state by morphing the TaskbarView into the stashed handle view and offsetting the background offscreen
- We persist the stashed state across app launches and reboot; to unstash, long press the stashed handle
- We also visually unstash when going back home

Test: long press tasbkar background when in an app to stash it, long press the resulting stashed handle to unstash; while stashed, swipe up to home to also unstash until launching another app
Bug: 189503603
Change-Id: I698eff785388dff1ef717c76879719d6af236c2d
2021-06-18 17:51:39 -07:00
Sunny Goyal
57b2279dcb Taskbar layout update
> Calculating the hotseat padding statically
> Animating taskbar views individually when animating to home
  instead of a layout animation
> Moving all navbar buttons to a separate layout/controller and independent
  of Launcher
> Fixing RTL layout for taskbar and nav bar

Bug: 187353581
Test: Manual
Change-Id: If21696f38beee328f553e467394776a8e8ed4c3e
2021-06-03 16:10:02 -07:00
Pat Manning
668d10d6c4 End drag touch event when crossing task drag threshold, and only when task is going up (drag to dismiss) am: 49cb49b1f5
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14800534

Change-Id: I93c5b7dc6bd6cabb3560334102fae46553b39506
2021-06-03 07:29:24 +00:00
Pat Manning
49cb49b1f5 End drag touch event when crossing task drag threshold, and only when task is going up (drag to dismiss)
Test: manual
Fix: 188618115
Bug: 188618115
Change-Id: I51d157e224eaeee34ed131e4945bb92d6baf18cd
2021-06-02 16:28:25 +00:00
TreeHugger Robot
cabb9096f3 Merge "Adjust task menu text size and colors" into sc-dev am: 137323c299
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14792892

Change-Id: Iec85e73cef73116f829d09d28bd06cab1cb2791d
2021-06-02 00:03:20 +00:00
Vinit Nayak
6ea5f721e5 Adjust task menu text size and colors
Fixes: 189855320
Fixes: 189855322
Change-Id: I0df4109f91ab09211b3cb5f3d18ad7374fa3f68c
2021-06-01 14:24:42 -07:00
Jonathan Miranda
121587eb13 Merge "Update launcher content animation to spec." into sc-dev am: cdc73b512e
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14757888

Change-Id: If73328d6c5a4827052ff0d7652c5002ccfc5d365
2021-06-01 19:52:05 +00:00
Jon Miranda
5df1fa5031 Update launcher content animation to spec.
- Scales content
- Fades in scrim

Bug: 177264697
Test: manual
Change-Id: Ie60908b6c417d94f1e075ea9728bd48eea55083e
2021-05-27 22:21:30 -07:00
TreeHugger Robot
89c8b063eb Merge "Overview - Remove the space withheld for proactive chips" into sc-dev am: d98a784d0e
Original change: https://googleplex-android-review.googlesource.com/c/platform/packages/apps/Launcher3/+/14706422

Change-Id: Idaaa1ab0c829f0e65ca6131cceda25f502914b10
2021-05-26 00:16:14 +00:00
TreeHugger Robot
d98a784d0e Merge "Overview - Remove the space withheld for proactive chips" into sc-dev 2021-05-26 00:11:18 +00:00