Commit Graph

3774 Commits

Author SHA1 Message Date
Samuel Fufa acebd1f69a [Search][Motion] Introduce header protection in AllApps
ScrimView exposes ScrimDrawingController that allow FloatingHeaderView to observe AllApps scroll progress and draw header protection on Scrim. In addition, search box independently adopts header protection background to ensure proper clipping behavior.

Test: local
preview: https://drive.google.com/file/d/1_E577AAJ0LBg0zrKJQSEJK9GQnrtx7uv/view?usp=sharing&resourcekey=0-MTxjlB3xWyJ3qPvr4qMdig
Bug: 184946772
Change-Id: I64c0f4f50d26c475d31542148a15c7c145588d3f
2021-05-07 11:15:05 -05:00
Lucas Dupin f6f0892467 Merge "Fix launcher ripple opacity" into sc-dev 2021-05-07 15:08:45 +00:00
Bill Yi 3cf8cace5b Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I290c44f7134dc44c6ef200215d32c8c8a893e501
2021-05-07 14:44:16 +00:00
Shan Huang f1d3cf02c9 Merge "Add a background scrim to launcher for text protection." into sc-dev 2021-05-07 03:59:26 +00:00
Lucas Dupin e4d07f960b Fix launcher ripple opacity
colorControlHighlight has a might higher opacity on the launcher theme.
themes_material.xml defines it with 10% opacity instead, for both light
and dark themes.

Test: manual
Bug: 187465854
Change-Id: I9abb44aec1fe40db500c9ebdadd5877d1246331b
2021-05-07 02:06:11 +00:00
Samuel Fufa f94540b28a Merge "[WorkProfile] Update work/personal tab to pills" into sc-dev 2021-05-06 23:33:06 +00:00
Steven Ng 57347bd6b7 Only show collapse handle when the bottom widgets picker is scrollable
Test: Go to contact bottom widgets picker. No collapse handle is
      shown because the content isn't scrollable. Go to Google calendar
      bottom widget picker. Collapse handle is hown because the content
      is scrollable.
Bug: 185134663
Change-Id: Ic6109c055a072aa1cf3521f829833fd5f4cece0f
2021-05-06 17:39:49 +01:00
Shan Huang 18caa92dba Add a background scrim to launcher for text protection.
This is a temporary approach to dim the wallpaper. Flip on ENABLE_WALLPAPER_SCRIM to enable the scrim.

In the long term we'll dim the wallpaper layer directly.

Test: Manual
Bug: 185890335
Change-Id: Ia88597bbcba6ae1536015d1b2a35260cab4a4453
2021-05-06 15:43:48 +08:00
Steven Ng edfec2fc0b Fix scrolling issue in the full widgets picker
Before this change, the widgets recommendation table handles all the
touch events. The table doesn't distinguish a touch event from a scroll
event. This change forwards the motion event to the active recycler view.
If the recycler view doesn't handle the event, it will then forward the
event back to the view hierarchy.

Test: Open the full widgets picker, then start scrolling on the
      recommended widgets UI. The full widgets picker scrolls perfectly.
      Drag-n-drop a recommended widget
Bug: 186567644
Change-Id: I89d473179796c516d2394332dd75f8e9a1d8b388
2021-05-05 23:19:09 +01:00
Santiago Etchebehere b90a951fed Merge "Update the label of Wallpapers button" into sc-dev 2021-05-05 00:59:02 +00:00
Sunny Goyal c52c0782a7 Merge "Adding support for determining split layout for launcher." into sc-dev 2021-05-04 22:33:38 +00:00
TreeHugger Robot 4a96831745 Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev 2021-05-04 17:55:35 +00:00
Bill Yi 9f8530948b Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: Ia5ca69da14eee63aa7d18caeb1a57d1556ab737a
2021-05-04 11:16:51 +00:00
Santiago Etchebehere 7e6e1693ef Update the label of Wallpapers button
Use the updated name

Bug: 179129352
Test: manual
Change-Id: Ia4878ce924b7d7f3ba1d8d661c8ac00c7310ee20
2021-05-03 20:12:50 -07:00
Jon Miranda 8fbf5cd263 Set swipe_up_rect_xy_stiffness back to 200 for existing app close anim.
Bug: 173107751
Test: manual
Change-Id: Ic878a2f788c35bffe97d83cb364d3878638272a1
2021-05-03 15:58:43 -07:00
Sunny Goyal 19ff728b92 Adding support for determining split layout for launcher.
> Simulating the windo wmanager API to get available device
  profiles until final API
> When a device has multiple internal displays, and with both
  tablet and phone possibilities, it uses a split workspace layout

Bug: 186160341
Bug: 175782275
Test: Manual
Change-Id: Ieff2329acac7cdd6b9abe6f96cd459cd45bd0efe
2021-05-03 14:48:28 -07:00
Adam Cohen 0a1b030bb3 Merge "Don't fade out active page outline during drag-and-drop" into sc-dev 2021-05-03 19:15:22 +00:00
Samuel Fufa db9b483c02 [WorkProfile] Update work/personal tab to pills
Bug: 186857875
Test: Manual
Screenshot: https://screenshot.googleplex.com/89jD32tHqNkBUWb
Change-Id: Ia4bb91372896d8a53017e3eadbe985878ce7f0ec
2021-05-03 10:53:33 -05:00
Bill Yi b3609ce590 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: Ia1732615c64fdae549156761932647f4dd14b4ba
2021-05-01 19:57:46 +00:00
TreeHugger Robot 51991a7333 Merge "Fix few A11y/ UI bugs for widget pickers" into sc-dev 2021-04-30 19:09:53 +00:00
TreeHugger Robot f9f506ca7e Merge "Update drop target styling based for BC." into sc-dev 2021-04-30 16:46:53 +00:00
TreeHugger Robot ed40c7735e Merge "Correct "cropping" of widget picker's search bar" into sc-dev 2021-04-30 15:00:32 +00:00
Pierre Barbier de Reuille 0e092292fb Correct "cropping" of widget picker's search bar
To corrent, I added 1dp of bottom margin. Not doing this, the framework
ignores the dropped shadow due to the elevation when some text is
entered in the box, leading to the observed cropping.

Fix: 186722040
Test: Manually
Change-Id: I746a8f014197552416ed9c40e9736baf22794c5f
2021-04-30 14:30:37 +01:00
Alina Zaidi c16c281305 Fix few A11y/ UI bugs for widget pickers
- Add a subtext in pin widget dialog informing users how to add widget
manually. This is not important for accessibility, as drag and drop is through an
action item for visually impaired users.
- Update search bar text hint color so that it passes accessibility test.

Bug: 182994384
Bug: 182993604
Test: Manually Tested using accessibility scanner app and talkback
Change-Id: I5a49d0bc3e5973b76c41b2a178af509e96a3cdd7
2021-04-30 13:30:03 +01:00
Alina Zaidi b42513fbc5 Merge "Fix some bugs in widget pickers." into sc-dev 2021-04-30 09:19:07 +00:00
Alina Zaidi 2b5124ec41 Fix some bugs in widget pickers.
- Update color of Educational tip view contents. Background colorAccentSecondary
in NexusLauncher above S, colorAccent otherwise (b/185834169)
- Update widget picker search bar color and its text font and color. (b/186423026)
- Update button padding and text in pin widget picker. (b/182994384, b/183601584)

Bug: 185834169
Bug: 186423026
Bug: 182994384
Bug: 183601584
Test: Manually tested
Change-Id: I36cd3ed2285677d0c164db8f57f6c90a5f247982
2021-04-30 07:52:23 +01:00
Bill Yi 5ed594fde0 Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev 2021-04-30 01:25:44 +00:00
Adam Cohen 0c4d278ed2 Don't fade out active page outline during drag-and-drop
=> Keep page backgrounds stable and only slightly modify the alpha + add stroke for active page
=> Don't shrink cell outlines to be too small (issue in hotseat on some devices)
=> Reduce cell radius to 22dp

Bug: 185163323
Test: manual

Change-Id: Ic17999f5672a3355dceeb25af923f02e960389d9
2021-04-29 23:09:56 +00:00
TreeHugger Robot 14e2070709 Merge "Replace conversations widget app icon" into sc-dev 2021-04-29 22:15:21 +00:00
Bill Yi a7e17232a0 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I9097c2e5797ad0b1b256e3e731dc0aa917aa4513
2021-04-29 19:00:55 +00:00
Steven Ng 1140f84b6f Replace conversations widget app icon
Test: Open full widgets picker and observe the expected icon for
      the conversations category.
Bug: 184878454
Change-Id: I580b0148d39c8dd004113c8f966135b22165a329
2021-04-29 17:46:29 +01:00
Steven Ng 99d4010c6e Merge "Use widget picker color surface for WidgetsBottomSheet" into sc-dev 2021-04-29 13:51:51 +00:00
Steven Ng 1777a1be4f Use widget picker color surface for WidgetsBottomSheet
Test: Launch widgets bottom sheet, search popup to confirm the expected
      background color is applied.
Bug: 183601302
Change-Id: I300a364605e00a0d8046a907a40f4cb797ec161e
2021-04-29 12:44:31 +01:00
Yogisha Dixit a3a6f51b12 Update drop target styling based for BC.
Spec: https://docs.google.com/presentation/d/1UxdDh8EFhPbdRWRwzjbpgL-j02ew4Ew3eG3XBCeoYdo/edit#slide=id.vXfwHn8

Demo: https://drive.google.com/file/d/1ZIa3Dgo85vdVkfPm7aGJDyctZQR_c8Xx/view?usp=sharing

Test: manual
Bug: 184713740
Change-Id: I17dbbf1f7bbc40939cfc0fedb506a35f39ecc2e3
2021-04-29 09:18:05 +00:00
Shan Huang 64fc7543f0 Merge "Updated launcher text shadow values." into sc-dev 2021-04-29 00:16:47 +00:00
TreeHugger Robot 45167d6030 Merge "Removing dependency on wallpaper colors and using theme resources" into sc-dev 2021-04-28 03:00:17 +00:00
TreeHugger Robot 222b4757f5 Merge "Allow Workspace Scrim to be colored per state" into sc-dev 2021-04-28 00:10:26 +00:00
Sunny Goyal 4ed0fb5074 Removing dependency on wallpaper colors and using theme resources
Bug: 184676715
Test: Manual
Change-Id: Ie9a9a784c4a8a8cd484bfd8ea463deedcd4deed6
2021-04-27 16:29:08 -07:00
Zak Cohen 4d35ac3020 Allow Workspace Scrim to be colored per state
Make it possible to set the color of workspace scrim to a different color
per state. Motivated by making Overview Scrim and All Apps scrims different
colors.

Bug: 186253733
Test: Local build and flash
Change-Id: Id7c38ce3c9173308eedfcb7592ececa7bd6bf220
2021-04-27 14:04:46 -07:00
Steven Ng f4bd91f0ab Merge "Add a11y action for expand / collapse items in WidgetsFullSheet" into sc-dev 2021-04-27 16:28:11 +00:00
Steven Ng fd68f757c8 Add a11y action for expand / collapse items in WidgetsFullSheet
Test: Enable talkback. When focusing on a collapsed item, it announces
      Collapsed "App Name" "n widgets/shortcuts". Action available. Use
      tap with 3 fingers to view. 3 fingers tap > Action > Expand.
      Widgets are expanded.
      When focusing on an expanded item, it announces
      Expanded "App Name" "n widgets/shortcuts". Action available. Use
      tap with 3 fingers to view. 3 fingers tap > Action > Collapse.
      Widgets are collapsed.
Bug: 183120145
Change-Id: Ibbb6025b929c141aa9e2fd2c72dce314e8be837e
2021-04-27 16:28:00 +00:00
Cyrus Boadway 5f35ff021d Merge changes I65d2b1bc,I35bf9cb4 into sc-dev
* changes:
  Animate App Widget activity launch from Quickstep launchers
  Add a mechanism to temporarily defer App Widget updates
2021-04-27 10:17:00 +00:00
TreeHugger Robot c2f4f0de02 Merge "Include recommended widgets table vertical padding in the height estimation" into sc-dev 2021-04-27 08:57:32 +00:00
Cyrus Boadway 61110601f6 Animate App Widget activity launch from Quickstep launchers
Following the general pattern on icon launch animations, define a
'floating widget view' to represent the appearance of the app widget
through the launch animation.

The floating widget view separates the foreground and background
components of the LauncherAppWidgetHostView, which can be positioned
and animated separately.

The background (or placeholder if no background can be identified)
moves and grows from its original position and size to the launched
app's position and size.

The widget's foreground scales and moves to match, fading out to be
replaced with the app window.

Bug: 169042867
Test: manual
Change-Id: I65d2b1bc80275f9df460790720e13d1650093347
2021-04-27 08:31:49 +00:00
Jonathan Miranda 19c1b86bc3 Merge "Use separate color for popup when on top of another surface (folder/all apps)." into sc-dev 2021-04-26 23:59:04 +00:00
TreeHugger Robot 4958e0b0b2 Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev 2021-04-26 22:50:35 +00:00
Jon Miranda a3c8662a56 Use separate color for popup when on top of another surface (folder/all apps).
This ensures the two surfaces contrast.

Bug: 175329686
Test: long press on item in folder
Change-Id: Ic2ac9c433ce219452024071388fa0cfb51487fb6
2021-04-26 17:59:21 -04:00
Steven Ng c7d7410178 Include recommended widgets table vertical padding in the height estimation
Test: run AddWidgetTest, AddConfigWidgetTest
Bug: 186450511
Change-Id: If306b569058edb3edb3c741199e9c0d96a88f412
2021-04-26 22:19:58 +01:00
Bill Yi 32ca4c3476 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: If093427db67d1d6809f0ba59aac1a18ccddaf8f1
2021-04-26 19:16:09 +00:00
Alina Zaidi b7f5ab04ad Fix few UI bugs in widget picker.
- Update colors for widget picker (b/184236316)
- Adjust padding according to mocks (b/184236316)
- Make sure view holders refresh corners in search mode. (b/185099541)
- Fix search bar shadow being cropped (b/183602001)

Bug: 184236316
Bug: 185099541
Bug: 183602001
Test: Manually tested
Change-Id: Ifa33e090cdf31c95db9c1145e623ef55c42dd52e
2021-04-26 16:48:14 +01:00
TreeHugger Robot 6d115b395c Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev 2021-04-23 17:05:16 +00:00
Bill Yi 22a8c92361 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I0753ecdead89494ec98b72e7fb3a6a46a848291b
2021-04-23 08:49:13 +00:00
Jonathan Miranda 02f12006fb Merge "Add new app close implementation." into sc-dev 2021-04-22 22:17:02 +00:00
Jon Miranda c9ad2dd6c7 Add new app close implementation.
- We remove the fling completely
- We set damping to 1 for x/y springs so there is no
  bounciness, and updated the stiffness and bounds to tighten
  up the path to the final location.
- During the animation, we translate all launcher content
  down
- When the x/y springs, and rect animator all finish,
  we use a spring to bounce the launcher content back up

- Added AppCloseConfig so that the entire animation can
  be defined in one location, with getter methods so that
  all the involved parties of the animation can access the
  current value.
- The animations are all defined linearly, and then
  interpolated over using a 3 point curve.

Building behind feature flag as we tune the values.

Bug: 173107751
Test: manual, visual
Change-Id: I83ad0fa2c4234cf30004240d43e191354595adc8
2021-04-22 16:11:11 -04:00
Schneider Victor-tulias 5a6e10bba8 Merge "Complete gesture nav sandbox for for UXR." into sc-dev 2021-04-22 17:35:29 +00:00
Shan Huang 5620c75c01 Updated launcher text shadow values.
Also update the way we compute shadow alpha so that it combines both text
alpha and shadow color alpha.

Test: Manually checked text appearances in launcher.
Bug: 185890335

Change-Id: I720a97bbaf21de86a5c446529109ce5b9ac5f6f7
2021-04-22 12:13:17 +08:00
Bill Yi 8954828d68 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I2f16395279d44a14cc82e54188978bfb8a1a9be7
2021-04-21 08:50:07 +00:00
TreeHugger Robot 58c6ae1852 Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev 2021-04-20 18:14:08 +00:00
Bill Yi 5a3b0497c8 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: Ifdb448fe337ff8ebb0ec85928563e18d09603bb5
2021-04-20 15:56:18 +00:00
Schneider Victor-tulias fb552936fd Complete gesture nav sandbox for for UXR.
- Removed All set screens altogether.
- Added "x" button to feedback view. This button now launches a dialog that allows the user to skip the tutorial.
- Added a progress tracker to the feedback view.
- Created a launch option to launch the back, home, then overview gesture tutorials in order.
- Added a button in the feedback view to progress through the tutorial.
- Updated tutorial animations to AnimatedVectorDrawables (with green accents).

Bug: 148542211

Test: manual
Change-Id: Icf3ec424141069895f97da74cd4ae881ff898d3f
2021-04-19 13:41:57 -07:00
Samuel Fufa 3722bb5620 [Search][Keyboard] Update default allApps vertical transition inset
Bug: 184721373
Test: Manual
Change-Id: I96c930a05055caa6ae1789c9d82810c099a0d133
2021-04-19 17:23:04 +00:00
Bill Yi e01c1f5354 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: Idf2317e39764e840bd008282c629f8d863bc33a9
2021-04-19 03:45:43 +00:00
Bill Yi 2875c4daa2 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I244c0a7b406c4fe2629f682e9813c835be8c82ef
2021-04-17 22:15:44 -07:00
Andy Wickham 6c9f4ef566 Merge "Sandbox changes for use in UXR prototype." into sc-dev 2021-04-17 05:37:41 +00:00
Andy Wickham 855072cda5 Sandbox changes for use in UXR prototype.
- "All Set" screen doesn't show after Home/Overview/Back tutorials.
 - X button in top left is hidden (we'll want to move this to the
   feedback view).
 - Feedback pops in and out from the top of the screen.
 - Hand animation is replaced by video feedback at start and after
   incorrect gesture.
 - Back tutorial goes left then right, in order to match video.
 - Updated strings and marked translatable (UX-reviewed already).
 - Added Chinese translations.
 - Many other things.

Test: Manual
Change-Id: I126a3ea0dad645014fab9cdee2ed19e06a8a56e9
2021-04-16 16:54:41 -07:00
Adam Cohen 868cab175b Fix errorprone build
=> dialogCornerRadius introduced in v28; this is enforced by errorprone build

Bug: 185623950

Test: manual

Change-Id: I8913cc4645a2f5a26f9b98226ba66f8a8b27c77c
2021-04-16 16:12:17 -07:00
TreeHugger Robot 447dcd4052 Merge "Fix the corner radius on workspace page outlines" into sc-dev 2021-04-16 21:01:58 +00:00
Adam Cohen 4ae6d0b286 Fix the corner radius on workspace page outlines
Bug: 185163323

Test: manual
Change-Id: Ibc84b93147e2a5020b266e0a81f12a8e18258d29
2021-04-16 11:10:54 -07:00
Adam Cohen 6adae06ed2 Merge "Update drag and drop visualizations" into sc-dev 2021-04-16 18:06:54 +00:00
Bill Yi 0cfa744c8a Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I063d8e9209e92bd5941af2597c180923e759252c
2021-04-15 20:40:19 +00:00
Adam Cohen f7ca3b4e3f Update drag and drop visualizations
=> Remove the bitmap-based icon outline
=> Add simple cell based location preview of drop location
=> Round corners of page outlines
=> Get rid of page background for focused page
=> Update colors to use system accent color

Bug: 185163323

Test: manual

Change-Id: Id604c59201536967e25236f305eeeb0aafc9c022
2021-04-15 12:45:24 -07:00
TreeHugger Robot 3d819a9d19 Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev 2021-04-15 00:52:16 +00:00
Bill Yi 83e481e56b Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I5bed8e41dee73591239d1685237ec70a2df5e08c
2021-04-14 23:32:26 +00:00
Samuel Fufa 99c6927dbb Merge "[Search] Update specs per UX" into sc-dev 2021-04-14 19:05:45 +00:00
Alina Zaidi 1e849a95f9 Merge "Add education tip to widget picker." into sc-dev 2021-04-13 19:26:30 +00:00
Tony Wickham 5df03e1585 Merge changes from topic "taskbar-hotseat" into sc-dev
* changes:
  Update taskbar to add extra hotseat items instead of recent apps
  Add support for having more hotseat icons in the DB than we show
2021-04-13 18:41:47 +00:00
Alina Zaidi 120d6476f6 Add education tip to widget picker.
A tip is shown on the first widget/shortcut in the recommended table.
If there are no recommended widgets, a tip is shown on first widget
in an expanded header.

There is a delay of few milliseconds, to let the WidgetCells be
completely rendered on screen before getting their location.

Test: Manually tested
Bug: 184920163
Change-Id: I2637e84e7fc467b27888023434e3578a4b8ed4d6
2021-04-13 16:47:04 +01:00
Alina Zaidi df9582e559 Merge "Fix UI bugs for widget picker search." into sc-dev 2021-04-13 15:42:34 +00:00
TreeHugger Robot 1ea2f0e045 Merge "Adding support for customize highlight region in preference" into sc-dev 2021-04-13 11:17:15 +00:00
Alina Zaidi 1ccd7efaf0 Fix UI bugs for widget picker search.
- Mirror search icon in RTL (b/184162989)
- Fix spacing between edit text and cancel button, to make it consistent
with space between search icon and edit text. (b/183602001)
- Scroll to top on every search result. (b/183602001)
- Fix keyboard overlap on orientation change. This is fixed by clearing
text on edit text differently (b/184048899)

Test: Manually tested
Bug: 184162989
Bug: 183602001
Bug: 184048899
Change-Id: I72ed51e1968a55a3105bd8b389d1bbd74d50d8af
2021-04-13 10:41:18 +01:00
Sunny Goyal 76e8fdc2bc Adding support for customize highlight region in preference
> Also fixing notification dots setting not getting highlighted

Bug: 184747760
Test: Manual
Change-Id: Ic9c2bfbb9750bed60afc14e824181f650c8cff33
2021-04-13 06:06:22 +00:00
Tony Wickham b87f3cdc1c Add support for having more hotseat icons in the DB than we show
Split InvariantDeviceProfile#numHotseatIcons into two variables:
numDatabaseHotseatIcons and numShownHotseatIcons. These are generally
the same, but different DisplayOptions within the same GridOption
can choose to show different numbers of hotseat icons while sharing
the same database.

numDatabaseHotseatIcons is used for all reading/writing/migrating
purposes, while numShownHotseatIcons determines how many Hotseat
icons to show in the UI.

Test: Existing tests pass, added two new migration tests
Bug: 184789479
Bug: 171917176

Change-Id: I54583504f61a47a4444b6a637ebb7e3ab31528b7
2021-04-12 16:08:15 -07:00
Steven Ng 484b34bf28 Merge "Set width & height of app icons in all widgets tray to 48dp" into sc-dev 2021-04-12 21:31:50 +00:00
Steven Ng 1d8090ef61 Merge "Add a widget conversations category for grouping widgets in the picker" into sc-dev 2021-04-12 16:38:36 +00:00
Schneider Victor-tulias 12f6419f9a Merge "Update Home settings nav bar color." into sc-dev 2021-04-09 16:35:34 +00:00
Steven Ng 3691179041 Set width & height of app icons in all widgets tray to 48dp
Bug: 184877669
Test: Change the grid size and observe app icons in all widgets
      tray stay the same.
Change-Id: I856d5fada579474fffb6296d641fb686623ca2cc
2021-04-09 11:15:50 +01:00
András Klöczl 12eeecc36b Merge "Update icon and text size for two panel home screen" into sc-dev 2021-04-08 22:48:26 +00:00
Steven Ng 833a0b9fa9 Add a widget conversations category for grouping widgets in the picker
Bug: 184878454
Test: Open the full widget picker and observe the conversation widget
      from SystemUi is listed under conversations.
Change-Id: I53cd74d80ce3c4ff77a92cd660ca9283416e9fd3
2021-04-08 22:35:55 +01:00
Steven Ng 1b5e45acae Merge "Use a separate personal/work tabs layout for the widget picker" into sc-dev 2021-04-08 18:48:52 +00:00
Andras Kloczl 6057cb9fe6 Update icon and text size for two panel home screen
Adding new field for landscape icon text size and changing
the logic for when to use landscape sizes.

Test: manual
Bug: 182796672
Change-Id: I89833e8fd90f2606937c3b95ac10229a042213ec
2021-04-08 15:27:27 +02:00
Steven Ng fd604ee7ae Use a separate personal/work tabs layout for the widget picker
1. Apps are feminine while widgets are masculine in some languages.
   We should use a different set of strings to ensure strings are
   translated with the right context.
2. We will be using a different theme for widget tabs. Let's keep
   the layout separate.

Bug: 184613311
Test: manual
Change-Id: I88df8ca6091e4b6ddf81f34f180a6ce2cada16e3
2021-04-08 11:14:24 +00:00
Schneider Victor-tulias e845463a1b Update Home settings nav bar color.
Updated the Hime settings nav bar color to match that of the wallpaper picker app.

Test: manual

fixes: 183396026
Change-Id: Id2302a553c5ddf645d497cb832608efecb3e70ad
2021-04-07 14:09:26 -07:00
TreeHugger Robot 63c169561c Merge "Some cleanup in RecentsView" into sc-dev 2021-04-07 21:06:55 +00:00
Pierre Barbier de Reuille d1bde5e6f3 Merge "Stop trying to draw a view not attached to the view tree" into sc-dev 2021-04-07 20:40:10 +00:00
Samuel Fufa 9245773737 [Search] Update specs per UX
- Moves search related resources go NexusLauncher

Test: Visual
Bug: 184369338
Change-Id: Ic466395192d1fd891aeebec93b491d453edf84aa
2021-04-07 11:54:34 -05:00
Pierre Barbier de Reuille ad41a56166 Stop trying to draw a view not attached to the view tree
The behavior of the framework when we try to do so is undefined. In our
case, it almost work, but no clipping is applied, which is a problem for
Android S (before that, widget couldn't use clipping in the first
place).

Instead of drawing the view through a drawable, this really add the view
and adds also a badge ImageView for badges instead of drawing them
indirectly.

Note that, temporarily, we have to re-allow drawing the view after it
has been attached, but the underlying framework bug being fixed, this
should be fine (I tested it and it really seems to be).

Bug: 183609936
Test: Using hand designed app (see bug)
Change-Id: I929ef8fc81c98c49406f2d940cd5efc28319886d
2021-04-07 15:51:43 +01:00
Sunny Goyal c82916fecb Some cleanup in RecentsView
> Merging overview and all-apps scrims into a single View
> Decoupling TaskMenuView from taskView

Bug: 184676497
Test: Manual

Change-Id: I49f7249eaa2a800054385ab8e73a441d6a1b5e16
2021-04-06 15:47:33 -07:00
TreeHugger Robot d69407c02e Merge "Update device padding to allocate more space to workspaceBottomPAdding." into sc-dev 2021-04-06 16:55:33 +00:00
Jon Miranda 71b954a257 Update device padding to allocate more space to workspaceBottomPAdding.
Bug: 175329686
Test: verify using DeviceProfile dump
Change-Id: I7054a49bf33e2c44bd1886a88dbed75c6807ab37
2021-04-05 16:59:15 -04:00
Samuel Fufa ee9aff9b5b [Search][Motion] Normal<->AllApps transition revamp
Preview video attached to BR

Key changes:

- SearchUiManager#getScrollRangeDelta is removed. AllApps initial vertical offset is now controlled by deviceProfile.allAppsOpenVerticalTranslate.
- ShelfScrimView is renamed to AllAppsScrimView. Scrim no longer does vertical translate with AllApps open.  Shelf/overview related code removed.
- Scrim and AllApps content transition are animated with different interpolators. Scrim color is a blend of accentColor and allAppsScrim with proportion determined by progress*TINT_DECAY_MULTIPLIER

Bug: 183001675
Test: Manual
Change-Id: Id6bde7ee65c55c83c2973fe41f458b9364d39ecd
2021-04-05 13:32:51 -05:00
Alex Chau 5bd9ba2a80 Merge "Focus running task in overview grid" into sc-dev 2021-04-02 03:57:58 +00: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 a547b781ee Overview - update UI to use solid color scrim.
Also required updates to colors and status bar icons to match with new
color.

Bug: 179922117
Test: local build and flash on two devices

Change-Id: Ibec54107f52c01f125e6d100abe32434f2067b71
2021-03-31 11:25:41 -07:00
Alex Chau 1ab1020496 Merge "Don't transpose hotseat on sw600" into sc-dev 2021-03-30 13:24:58 +00:00
Jon Miranda ec1277eec1 Migrate existing 4x5 and 4x4 grid users to a new 4x5 grid.
Due to the dogfood 4x5 grid using the wrong db, there may
be some rearranging of items.

The goal is to completely remove the old 4x4 and 4x5 grid,
but first we need to silently migrate users to the new grid.

We still  need to keep the old grids in the device profile
so we hide them from the Styles & Wallpaper app.

We also need to reset and remove the ENABLE_FOUR_COLUMN feature
flag from the UI.

- Added TODO to remove this logic in the tracking doc

Bug: 183965808
Bug: 175329686
Test: have old 4x4 or 4x5 grid set up
      install apk with these changes
      confirm that we are now using the new grid and the
      other grid options are inaccessible to the user
Change-Id: I81a91b8415effbe0bf7ba722f11ab44a4169e3df
2021-03-30 13:17:37 +00:00
Alex Chau 41a842449d Don't transpose hotseat on sw600
Bug: 178385459
Test: Manual
Change-Id: I5805b0ccb05b97b931ab99a31c31029f7066daca
2021-03-29 13:01:28 +01:00
Sunny Goyal 572aca4ce2 Moving some common functionality to IconLoaderLib
Bug: 183641907
Test: Manual
Change-Id: Icfc7ebb140e4e1678b0715beee2e0e513e707b9e
2021-03-25 10:06:53 -07:00
Samuel Fufa c699c01812 Merge "[Search] Resolve work/personal tab overlap with A-Z list" into sc-dev 2021-03-25 13:34:17 +00:00
Samuel Fufa df3fa3bfec Merge "[String][Work profile] Update work profile strings" into sc-dev 2021-03-25 13:34:04 +00:00
Alex Chau 06452a427d Merge "Move numAllAppsColumns to displayOptions" into sc-dev 2021-03-25 11:16:00 +00:00
Samuel Fufa e0b8c8396a [String][Work profile] Update work profile strings
Bug: 183517121
Test: Manual
Change-Id: I334854170dca6ecf321da0ec2094ab993404c229
2021-03-24 19:35:11 -05:00
Alex Chau 7c43972c50 Move numAllAppsColumns to displayOptions
- Allow different number of columns per screen size

Bug: 171915986
Test: Manual
Change-Id: I7b7d518289ea56624dc87512f639e92f10f6b586
2021-03-24 19:36:11 +00:00
Jon Miranda c9e69fa98d Refactor device padding to be set per grid option
- Fixes bug where devices with scaled grids were not
  getting the correct deivce padding.
- Also fix bug where device padding was invalid.
  Added validation check when processing paddings to prevent
  this from happening again.

Bug: 175329686
Test: manual, enable debug flag,
      run and verify no crash from validation check

Change-Id: I35b019c40667c08de4fad95ac4b05b2d8f8a0e74
2021-03-24 14:58:44 -04:00
Alex Chau dedbc8ac36 Remove grid scaling in Overveiw
- Grid scaling has problem that scales task icon and menu, which makes it hard to control icon size and text size in the manula
- Replaced the whole concept with dedicated Task size calculation in grid layout
- Support different icon size in TaskView in grid and removed task_thumbnail_top_margin
- Removed grid progress in TaskViewSimulator as well
- Refactored how ClearAllButton scroll and translations are calcualted to align clear all properly in grid
- Make page center calculation aware of PagedView pivot and scaling

Bug: 174464863
Test: Manual on two screens
Change-Id: I47b13ef6e55c6e16c52ea04225f5bde02ed82fc2
2021-03-24 18:46:32 +00:00
Zak Cohen 21aa7042c0 Merge "Overview - Adds first pass at making landscape layout real." into sc-dev 2021-03-24 18:44:29 +00:00
Zak Cohen 334efebaba Overview - Adds first pass at making landscape layout real.
Adds dynamic sizing to margins around task view, also creates space in the
overview actions view in landscape to make space for the proactive chips if
needed.

Bug: 182529089
Test: Local build and run on two devices
Change-Id: I447de3564a3249ede4e8e8a4d3e5d1c177f6be61
2021-03-24 14:45:48 +00:00
Yogisha Dixit 73c8a366a8 Add a button for reconfiguring widgets.
Test: manual
Bug: 183316993
Change-Id: I17bec121e3d07d65979c2b92c285e487a7d64d65
2021-03-24 13:34:29 +00:00
Alina Zaidi 305a44c935 Merge "Bug fixes for widget picker search (2/n)" into sc-dev 2021-03-24 09:47:26 +00:00
TreeHugger Robot cb6dff62d9 Merge changes I6ce23251,I56fca1b7 into sc-dev
* changes:
  Update the resize frame to use the forced radius.
  Enforce rounded corners on App Widgets.
2021-03-24 00:39:17 +00:00
TreeHugger Robot acb3cac938 Merge "Update Pin widget dialog UI according to mocks." into sc-dev 2021-03-24 00:29:41 +00:00
Jonathan Miranda 0fa5225d57 Merge "Updating deep shortcut container to new width." into sc-dev 2021-03-23 21:30:46 +00:00
Pierre Barbier de Reuille 452df2d5bb Update the resize frame to use the forced radius.
When forcing the rounded corners, the radius may be smaller than the
default one. When this happens, we should change how the frame is drawn
to only use that reduced radius, or this looks weird.

Bug: 183097166
Test: Manual tests with top 1P App Widgets
Change-Id: I6ce232515ce14059e1168e16735719ea2370132c
2021-03-23 20:57:33 +00:00
Pierre Barbier de Reuille 298526e812 Enforce rounded corners on App Widgets.
The feature is controlled by the ENABLE_ENFORCED_ROUNDED_CORNERS flag
(currently set to false).

If does not yet handle P/H flags to control its behavior.

Bug: 183097166
Test: Manual tests with top 1P App Widgets (See bug for results)
Change-Id: I56fca1b717f37ad518588115409f2144a71d4b98
2021-03-23 20:57:33 +00:00
Tony Wickham 3629b93546 Merge "Add TaskbarView as a child of Hotseat" into sc-dev 2021-03-23 18:36:53 +00:00
Steven Ng d8c2a7b2da Merge "Update title of bottom widgets tray" into sc-dev 2021-03-23 17:19:01 +00:00
Samuel Fufa c6995f3eb2 [Search] Resolve work/personal tab overlap with A-Z list
This issue was caused due to launcher falling out of sync with DEVICE_SEARCH_FLAG. This change makes AllApps views agnostic of search input type when rendering layout.

Bug: 182591985
Test: local
Change-Id: Ic015b68e110eea9ab5184325f2a3633a5c7d15cc
2021-03-23 11:09:15 -05:00
Jon Miranda e888b08b70 Updating deep shortcut container to new width.
Bug: 175329686
Test: manual, visual
Change-Id: I0487d240523ab3de4bf3e381ec359267eaa33a71
2021-03-23 12:00:38 -04:00
Alina Zaidi 6d97d893e0 Update Pin widget dialog UI according to mocks.
Test: Tested manually and RequestPinItemTest passed
Bug: 182982143
Bug: 182994819
Bug: 182929673
Change-Id: I905ea0c1860d28ee9fbb456ddf6abd728b65bac4
2021-03-23 13:36:48 +00:00
Alina Zaidi 76060eb11b Bug fixes for widget picker search (2/n)
- Dismiss keyboard when user starts to drag widget picker
- Add content description for cancel button

Test: Tested manually.
Bug: 183211445
Bug: 183106676
Change-Id: Ie620c3d50a49d8380f316d48e4ee8ebced6de5eb
2021-03-23 12:53:23 +00:00
Jonathan Miranda b40025756a Merge "Account for children margins when orienting popup container." into sc-dev 2021-03-23 09:38:37 +00:00
Tony Wickham 9ce3b25ef6 Add TaskbarView as a child of Hotseat
Instead of keeping the Taskbar window showing above the home screen,
we now integrate a copy of TaskbarView directly into Launcher's view
hierarchy. Most TaskbarController calls apply to both TaskbarViews
(mTaskbarViewInApp and mTaskbarViewOnHome), except for calls related
to Hotseat, which only apply to mTasbkarViewInApp given the real
Hotseat will be showing with mTaskbarViewOnHome.

More cleanup will follow this change.

Test: All taskbar interactions (e.g. drag and drop) continue to work
Bug: 182512211
Bug: 171917176
Change-Id: I0f0b124f652daa85f866e1df8f9e2981540331a0
2021-03-22 15:26:01 -07:00
Steven Ng 867ff5f60c Update title of bottom widgets tray
Only use the "app name" instead of "app name widgets" as title
Remove "Touch & hold to move a widget" subtitle.

Test: manual

Bug: 179797520
Change-Id: I7a5954af73aa5b480096e93ade3520cef6c93f17
2021-03-22 22:23:46 +00:00
Steven Ng d14e76867b Merge "Exact common layout from widgets bottom sheet" into sc-dev 2021-03-22 22:23:06 +00:00
Steven Ng f45f875232 Merge "Fix corner radius for single item in the widgets tray." into sc-dev 2021-03-22 18:51:41 +00:00
Steven Ng e4c0e954d3 Exact common layout from widgets bottom sheet
Test: open widgets bottom sheet and drag and drop widgets & shortcuts.

Bug: 182305634
Change-Id: I82e3e584edf64177ffa6e677f5b3f487823d3e1b
2021-03-22 17:50:49 +00:00
Lucas Dupin 8b9365d4ad Merge "Apply new color scheme" into sc-dev 2021-03-22 16:57:18 +00:00
Steven Ng f4fb4d9429 Fix corner radius for single item in the widgets tray.
If there is only one item, corner radius at 4 corners should be 28dp.

Test: Corner radius of one item is correctly shown in the widgets
      picker.

Bug: 183382610
Change-Id: Ief46af8c41ce944792d08212e93f7d68c6278d05
2021-03-22 16:30:57 +00:00
Lucas Dupin 554a1bee39 Apply new color scheme
Bug: 173553055
Test: manual
Test: atest SystemPalette
Test: atest ThemeOverlayControllerTest
Test: atest DeviceDefaultThemeTest
Change-Id: Ie06160ed322ceac2e1078c24db287dd1f26a0a65
2021-03-20 11:00:13 -07:00
Steven Ng 682af23651 Merge "Renders widget recommendations" into sc-dev 2021-03-19 23:18:22 +00:00
Jon Miranda 116e94e0a7 Account for children margins when orienting popup container.
Instead of recalculating the orientation after adding margins,
we account for the margins in the initial calls to orientAboutObject.

This ensures consistent mIsAboveIcon throughout calls to show the popup.

- Also updates the smaller radius to match the middle items.

Bug: 175329686
Test: long press on item where height and height without margins would
      result in differing mIsAboveIcon values
      eg. the 3rd item in a folder in the top middle of 5x5 workspace

Change-Id: I6132b544a89c7948339d17f219ad75c797233f55
2021-03-19 18:30:03 -04:00
Steven Ng 4235fc129c Renders widget recommendations
Update the tapl test logic to scroll a smaller distance to avoid the
search bar blocking the target touch area.

Test: Open full widgets sheet and observe the widget recommendations
      shown at the top.
      Run AddConfigWidgetTest

Bug: 179797520

Change-Id: I6d53bbb46e2cb928ed7d015aaac604be17d33178
2021-03-19 21:11:32 +00:00
Jonathan Miranda 48a2f09349 Merge "Add separate background colors to each popup container child." into sc-dev 2021-03-19 20:34:10 +00:00
Steven Ng 1e29433fc6 Merge "A11y fix for all widgets tray (Part 1 / n)" into sc-dev 2021-03-19 17:44:59 +00:00
Jon Miranda 2a58d13b9b Add separate background colors to each popup container child.
- Colors interpolate between the primary and secondary popup colors
- Removed condensed height and icon scale

Bug: 175329686
Test: visual, manual checking apps with different shortcut options
Change-Id: I064c329dc8ad3ae6f408056c74372cca3ce20b68
2021-03-19 13:41:07 -04:00
Alina Zaidi 7358069a91 Merge "Fix bugs for Widgets picker Search UI." into sc-dev 2021-03-19 16:57:11 +00:00
Alina Zaidi c4f3f49805 Fix bugs for Widgets picker Search UI.
- On orientation change, clear search bar.
- Change text and search bar color to make similar to mocks/ all apps search bar.
- Fix search recycler view visual bugs.
- If back is pressed in search mode, exit search mode instead of exiting widget picker.

Test: Manually seen widget picker on phone.
Bug: 183103133
Bug: 183103936
Bug: 183115050
Bug: 157286785
Change-Id: I056f089eada84d00133038f4a3d7b18bc51be564
2021-03-19 14:42:47 +00:00
Jonathan Miranda b0cb399d21 Merge "Update deep shortcut to new ui." into sc-dev 2021-03-19 13:31:08 +00:00
Steven Ng 8eb1f73d58 A11y fix for all widgets tray (Part 1 / n)
Mark some image view unimportant for accessibility.
Still need to update the content description for widget list
header to describe the expand / collapse action.

Test: Navigate all widgets tray with talkback enabled.

Bug: 183120145
Change-Id: I1801d8351ac7f22a0135a96a36de706377781b31
2021-03-18 23:42:56 +00:00
Sunny Goyal fa699566f5 Merge "Adding an optional QSB in hotseat" into sc-dev 2021-03-18 16:07:45 +00:00
Samuel Fufa 74bd4f32e2 Merge "[Search] Update search input hint" into sc-dev 2021-03-18 16:03:20 +00:00
Alina Zaidi cc2c8a5cb1 Merge "Improvements to widget picker search." into sc-dev 2021-03-18 15:29:16 +00:00
Jon Miranda c79316740b Update deep shortcut to new ui.
- Removed divider views, using margin to separate views
- Removed elevations
- Added a ViewGroup to hold all notification views, and applied an outline

Bug: 175329686
Test: visual
Change-Id: Iad70dcfdaeba6050c2b17c07f76bb7bfb728e544
2021-03-18 11:09:34 -04:00
Alina Zaidi cb76e7d16f Improvements to widget picker search.
-Expand clickable area on search bar.

Test: Tested prototype locally.
Bug: b/157286785
Change-Id: I70a4edb1ce207f4dae9a0909c05e0823840500dd
2021-03-18 12:13:18 +00:00
Steven Ng 66ccd29a3d Adjust bottom picker padding / margin & add a drag handle
Test: Manual
Bug: 179797520
Change-Id: I594bf2cf140a31f20d41fbb9804197724478caf9
2021-03-18 12:09:45 +00:00
Alina Zaidi 378ca5e920 Merge "Bug fixes for widget picker search." into sc-dev 2021-03-18 10:32:18 +00:00
Steven Ng 99060b30ca Merge "Adjust font, color, margin, corners for all widgets tray" into sc-dev 2021-03-18 10:25:00 +00:00
Steven Ng 08ef694509 Adjust font, color, margin, corners for all widgets tray
Test: manually
Bug: 179797520
Change-Id: Ib78aae05e021da272ef2f754c876d24a4c14bcb0
2021-03-17 22:43:12 +00:00
Sunny Goyal c373e1c642 Adding an optional QSB in hotseat
Removing sections in all-apps during transition and treating
it as a single unit

Bug: 175137718
Test: Manual
Change-Id: I55a501d80b5903f1a9d92a26b3784784fd9e50fd
2021-03-17 12:21:44 -07:00
Alina Zaidi 2e732e95d9 Bug fixes for widget picker search.
SearchBarController
- Use Extended Edit Text to handle close keyboard action well.
- On press enter while search remove focus from bar and hide keyboard.
- On cancel button press hide keyboard and also reset search targets to empty so that on next search session the previous results dont flash (show for a short time before reflecting users query).

WidgetsFullSheet
- Make sure expanded header are reset when user leaves personal/work recycler views. Search recycler view resets its expanded header on every search already.
- Show 'no search results' view if no search result present.
- Update WidgetListBaseRowEntryComparator to show personal profile widgets first.

Test: Tested prototype locally.
Bug: b/157286785
Change-Id: Ibaa208c4091783e14ac0887caf559e867185df5a
2021-03-17 14:43:04 +00:00
Alex Chau 1e024358ad Merge "Two panel & two page swipe & currentPage fixes" into sc-dev 2021-03-17 13:47:01 +00:00
Andras Kloczl 8e57cce4ee Two panel & two page swipe & currentPage fixes
- Pagespacing set to 0 to have similar design to figma
- Added padding to left side of left panel and right side of right panel to match figma
- getPageScrolls changed to support two page scrolling
- validateNewPage changed so that only even indexed pages can be switched to
- getPageWidthSize added for measurements, it returns half screen width when two panel is active
- onMeasure changed to use getPageWidthSize
- panelCount has been increased from 1 to 2 when two panel is active
- add feature flag for two panel home
- shouldConsumeTouch changed so not only currentpage is checked but currentpage+1 screen as well
- add one more extra check for setDropLayoutForDragObject for currentpage + 2, next to right panel
- using new grid option for two panel home screen

Test: manual
Bug: 174464115
Change-Id: I1bad7eecc67f65fb833608744a5aa5aca65373b4
2021-03-17 12:19:02 +01:00
Yogisha Dixit 6d593d891e Merge "Fix bug with resize frame disappearing." into sc-dev 2021-03-17 10:27:33 +00:00
Samuel Fufa fa3316e8db [Search] Update search input hint
Bug: 182927397
Test: Manual
Change-Id: I6ea7e70d0ddf3672187bd1936bc46c841a2618fb
2021-03-16 18:53:49 -05:00
Yogisha Dixit f9954cc4cc Fix bug with resize frame disappearing.
Currently, if you resize the widget to the top, bottom or right, the
resize frame disappears. This is because the AppWidgetResizeFrame code
relies on the indices of the child elements to find the drag handles.

I updated the code to instead use IDs since that is more robust.

Test: manual
Bug: 182305670
Change-Id: Iaa9d32c9190fb579101914f03d57bb48dcecb88d
2021-03-16 21:31:46 +00:00
Alina Zaidi 1632752a72 Have an interface for WidgetsSearchBar so Nexus Launcher can override the search bar.
Test: Tested prototype locally.
Bug: b/157286785
Change-Id: I263063a451862755efe3d6e4a5a2eb69f2ea29b8
2021-03-16 09:25:22 +00:00
Vinit Nayak d987a828e8 Initial commit of new split screen work.
TODO:
* Extract out common elements in TaskShortcutFactory.MultiWindowFactory
for commonalities between new and old way of
invoking split screen
* Integrate with WM APIs (b/182002789)
* Write tests for SplitSelectStateController

Bug: 181704764

Change-Id: Ice35adb4ea82897f5e2433dc9b93a549f3d511b5
2021-03-15 15:42:32 -07:00
Alina Zaidi e17f4651d0 Merge changes from topic "SEARCH_INTEGRATE" into sc-dev
* changes:
  Add a WidgetsSearchBar(Launcher3) and a WidgetsSearchController.
  Have a recycler view to show search results.
2021-03-15 13:24:20 +00:00
Alina Zaidi d07acba048 Add a WidgetsSearchBar(Launcher3) and a WidgetsSearchController.
- Make WidgetsSearchBar in Launcher3 initialize WidgetsSearchController with SimpleWidgetsSearchPipeline
- Modify SimpleWidgetsSearchPipeline to filter widgets entries on widgets/shortcut labels also.

Test: Tested prototype locally. Also added robolectric test.
Bug: b/157286785
Change-Id: I65f5fa0240ffb6d22023167e4e86d94d83bbd9f7
2021-03-15 11:25:08 +00:00
Steven Ng 53d1364e8b Better estimate the height of widget recycler view
Test: Expand and collapse apps in the widgets picker. Then, observe
      the height of the fast scroller is correctly displayed.

Bug: 181629430
Change-Id: I9efcf902f8548fc5c8a398609758d43123228e5e
2021-03-12 22:58:45 +00:00
Sunny Goyal da2ecb3095 Merge "Adding support for listening for app launch animation completion" into sc-dev 2021-03-11 21:36:43 +00:00
Alina Zaidi 334e65935b Have a recycler view to show search results.
-Have a recycler view layout for search widgets list.
-Make WidgetsFullSheet implement interface- SearchModeListener to get notified when user is using search and also when search results are ready.
-Have a WidgetsListSearchHeaderViewHolderBinder for search result headers which shows subtext in header as concatenated string of widget/shortcut labels.
-Modify WidgetsListAdapter and WidgetsDiffReporter to work well with search recycler view.

Test: Tested prototype locally. Also added robolectric test.
Bug: b/157286785
Change-Id: Ie29d9f295fddb6d727b5fc26a360f514f2f4a763
2021-03-11 21:27:51 +00:00
Steven Ng 8e5a0a71f7 Merge "Update widget toast strings" into sc-dev 2021-03-11 16:43:10 +00:00
TreeHugger Robot 2d439080dc Merge "Launcher changes to support dynamic coloring on static widgets." into sc-dev 2021-03-11 02:15:41 +00:00
Sunny Goyal b65d766d88 Adding support for listening for app launch animation completion
Bug: 181165935
Bug: 179065491
Test: Verified on device
Change-Id: Ifa6a91560cb31b4dfb72a0f582607e873d8a002d
2021-03-10 15:53:21 -08:00
Pierre Barbier de Reuille ab33b76dce Launcher changes to support dynamic coloring on static widgets.
Bug: 179783721
Test: By hand using the AppWidgetDynamicColors widget
Change-Id: I27863cac31f2f6c29f5a717ff8d4492325f936fb
2021-03-10 22:04:35 +00:00
Steven Ng d73d6e56a9 Show an empty view when there is no widget available
Test: Remove all widgets from work profile using TestDpc. Observe
      empty view is shown in the full widget tray. Add back some
      widgets to work profile and observe widgets showing up in the
      full widgets tray

Bug: 179797520
Change-Id: I2e1fcb5a0014568a4674e2bcc0a3ed3c6ec5a44a
2021-03-10 17:36:37 +00:00
Steven Ng 7ec893fb8e Update widget toast strings
Test: Tap on widgets and shortcuts in all widget tray and observe
      correct string is shown.

Bug: 179797520
Change-Id: I0e274017d4af1de506afbb819ab91f6575d7bb8e
2021-03-10 17:35:51 +00:00
Steven Ng ae6b34811b WidgetCell & LiveWidgetPreview cleanup
The fixes are:
1. For widgets shown in TableRow, aligns them center vertically.
   This is useful when widgets of different height are shown in
   the same row.
2. Remove background color from WidgetCell
3. Re-enable swipe in FullWidgetsSheet
4. Use the WidgetCell image as the single & long press area because
   1. Previews are now scaled to their default size. The touch area
      should already be larger for widgets that are bigger than 2.4
      cells
   2. WidgetCells also render description. If the user long press the
      description area, the drag view will not align in the middle of
      the user touch / drag area.

Test: Drag-n-drop widgets from FullWidgetsSheet, BottomWidgetsSheet
      and pin widget flow.
      In FullWidgetsSheet, swipe left and right to switch work /
      personal tab.

Video: https://drive.google.com/file/d/1Ur7PwF1a7iwGGRTZczfc0BSVu-Ta6-Vm/view?usp=sharing

Bug: 179797520
Change-Id: I6fe4bc88d1e1b35b1819d8d7f046105f5ed27043
2021-03-08 21:22:08 +00:00
TreeHugger Robot b6c4fd18af Merge "Update app widget resize frame UI." into sc-dev 2021-03-08 16:06:12 +00:00
TreeHugger Robot d333224f19 Merge "Convert Launcher Android.mk to Android.bp to setup RoboTests" into sc-dev 2021-03-08 08:12:53 +00:00
Hyunyoung Song 5a007fe0f6 Convert Launcher Android.mk to Android.bp to setup RoboTests
Bug: 181083996
Test: m Launcher3 && install Launcher3 and test basic things
Test: m RunLauncherRoboTests (90 tests run and 3 fails)

Change-Id: Icdc839d06413409cbd52d10a5ef9fe27b0a57baa
2021-03-07 22:42:42 -08:00
Steven Ng bcab2a808a Add shortcuts count as a subtitle in the full widgets sheet
Screenshot: https://screenshot.googleplex.com/9Ds55rsFSNajLWN.png

Test: Open full widgets sheet and observe widgets and shortcuts
      counts are correctly displayed.

Bug: 180725078
Change-Id: Ibf43c14cc06c0e9bf245c53f190095d0eaeace12
2021-03-05 09:54:56 +00:00
Steven Ng 239101c512 Merge "Remove unused widgets_scroll_container layout" into sc-dev 2021-03-04 23:22:17 +00:00
Yogisha Dixit b4c268ee28 Update app widget resize frame UI.
Mock: https://docs.google.com/presentation/d/1UxdDh8EFhPbdRWRwzjbpgL-j02ew4Ew3eG3XBCeoYdo/edit#slide=id.8YyBaHq
Implementation: https://screenshot.googleplex.com/BEFwWBmXXx8xXdS

I will update the drag handles in a follow-up CL since their specs
aren't ready yet.

Test: manual
Bug: 181774580
Change-Id: I19a99e6dbe106754da0fac56a5c2e7eb9eb90cef
2021-03-03 18:44:11 +00:00
Steven Ng ab522e85b2 Remove unused widgets_scroll_container layout
Test: Compile NexusLauncher successfully

Bug: 181701011
Change-Id: I35d1c9324990e86496c45ca6db5f32f9588c7279
2021-03-03 13:54:02 +00:00
Jonathan Miranda a9bb9394a5 Merge "More grid changes, closer to final specs." into sc-dev 2021-03-02 19:19:08 +00:00
Steven Ng c7537713ca Add widget description to WidgetCell
Full picker: https://screenshot.googleplex.com/8Dij79K8Pq2KWdm.png
Bottom picker: https://screenshot.googleplex.com/5f9TLra49dYJjLB.png

Test: Manually launch full and bottom widget pickers and observe
      description is only shown for widgets but not shortcut.

Bug: 179797520
Change-Id: I5bfde056906a4a0f4fff9bc9a488f808365173b3
2021-03-01 23:17:32 +00:00
Steven Ng 05cc458dbf Merge "Show widget previews in their expected cell sizes" into sc-dev 2021-03-01 10:10:15 +00:00
TreeHugger Robot 3be39aa0b9 Merge "Update ArrowPopup to accommodate more rounded dialogs." into sc-dev 2021-02-26 22:17:40 +00:00
Steven Ng 11773f47d2 Show widget previews in their expected cell sizes
1. Show widget previews in their expected cell sizes.
2. Update the bottom picker to use a table layout rather than
a horizontal scrollbar.
3. Move the title and cell size description to the bottom of
the preview.

Test: Run AddConfigWidgetTest
      Manually open full and bottom widgets picker and observe
      widget previews.
      Video: https://drive.google.com/file/d/1K8A8hK5B4FgPTsX3cb-Yt4a_VjI0pk-w/view?usp=sharing
Bug: 179797520
Change-Id: I938612cb2e2477ce4a3a2d6c8891a0a36fc0978c
2021-02-26 17:47:32 +00:00
Steven Ng 167f81b931 Add a header container view to the widgets full sheet
A header container view will contain
1. A horizontal bar: for indicating the popup view can be dragged
   to dismiss:
2. A title view: a title of the widgets full sheet popup view.
3. A search bar: for widgets / shortcut search. Since we will be
   making the fallback search algorithm available in AOSP, the
   search bar will now live in the Launcher3 codebase.
4. Recommended widgets (coming soon...)

This CL also added a scroll effect which gradually collapses the
title view when the user scrolls down the recycler view. The title
view will gradually restore its height when the user scroll to the
top of the recycler view.

Test: Manually test widgets pickers in work profile and non work
      profile setup. Verified the fast scroll bar works well in
      both setup.
      With searchbar: https://drive.google.com/file/d/19grUHL_LspLhMD_5p6-i0CiMW1FpflmD/view?usp=sharing
      Without searchbar: https://drive.google.com/file/d/1KRPgEAESHUhJDo1UJsQN80JO1c9Y8Nhl/view?usp=sharing

Bug: 179797520

Change-Id: If0016e3b3c693414897140e7912531ed9bd5deef
2021-02-26 10:03:36 +00:00
Zak Cohen 452005a14e Update ArrowPopup to accommodate more rounded dialogs.
Adjusts layouts to accommodate more rounded dialogs, includes adding a
new rounded triangle drawable that can be clipped by a rounded rect.



Bug: 179922117
Test: checked all instances and RTL
Change-Id: I4c2f0ead0fd56eba14ffd9b82f0c100f7d92ef5b
2021-02-25 16:59:55 -08:00
Jon Miranda e126d72fa8 More grid changes, closer to final specs.
* Added isScalable, minCellWidth, minCellHeight, and borderSpacing attrs

When isScalable is true, we use set workspace cell values to
minCellWidth/minCellHeight and then scale the cell values to
fit the available space. This allows us to have consistent
aspect ratios when two devices match the display/grid options.

This is different from the dynamic grid, which calculates
cell values based on iconSize/textSize/etc and then allows
the cell width to be as wide as space allows.

I adjusted some variables so that they will auto adjust
based on another value, indepenent from whether the
grid isScalable or not. An example of this is the folder
label text, where it's always set to be 1.14x of whatever
the workspace icon text size is. This is so we don't need
to add a bunch of more variables to DisplayOption/GridOption.

Bug: 175329686
Test: - switching between device profiles,
      - testing folder open/close
      - testing in multiwindow
      - testing in landscape
Change-Id: Ia469ae0d65b518469ef264b726db46f4a3210056
2021-02-25 17:34:56 -05:00
Steven Ng e8d92342fa Replace horizontal ScrollViews with tables in the full widgets picker
Test: Run gnl test, AddWidgetTest
      Run Robolectric tests for widgets
      Manual test video: https://drive.google.com/file/d/1uwCtVNIlC9150kv5eEfILfP5r5M7ARYm/view?usp=sharing

Bug: 179797520
Change-Id: I2f4cdf84338a91b63967879d0c9268c312ace19b
2021-02-24 19:49:15 +00:00
Lucas Dupin 85df1c291f Merge "Overlay property instead of style" into sc-dev 2021-02-23 19:10:12 +00:00
Lucas Dupin 3cdc6f86af Overlay property instead of style
Overlaying the whole style with sw720dp will override dark theme styles.
Let's instead define the attribute that needs to be different and put it
in a config xml.

Test: set smallest width to 720, flip to dark theme
Fixes: 180003967
Change-Id: I423f3401b612e7e87a63f3f14f972b9d863d8a17
2021-02-22 16:34:51 -08:00
Steven Ng 391404fcb7 Add personal / work tabs for work profile widgets
Video: https://drive.google.com/file/d/1TORRNcvVM7fIvNd_WZaajLbI7D9z4VFA/view?usp=sharing


Test: Main profile only: run AddConfigWidgetTest.
      With work profile: manually launch the full widgets sheet.
      Go to the personal tab: only personal widgets are shown.
      Go to the work tab: only work widgets are shown
      Successfully add personal / work widgets from the full widgets
      sheet.

Bug: 179797520

Change-Id: Iad8b90c2af35e0580319d7a05510ec88e4f8b86c
2021-02-22 16:10:09 +00:00
Hyunyoung Song dfdeddc66a Merge "Add group highlighting to AA+ result" into sc-dev 2021-02-19 20:48:37 +00:00
TreeHugger Robot aa14b19725 Merge changes Id68b6c37,I16d39d3e into sc-dev
* changes:
  Fix a couple of crashes when taskbar isn't yet attached
  Subtract taskbar size from DeviceProfile#availableHeight
2021-02-19 19:01:38 +00:00
Steven Ng 4236451069 Merge "Extract common codes for personal / work profile tabs" into sc-dev 2021-02-19 18:10:48 +00:00
TreeHugger Robot fed6b8cb5c Merge "Update popup container to match spec." into sc-dev 2021-02-19 17:40:01 +00:00
Steven Ng 36322d8621 Merge "Render preview layout in full widgets sheet and bottom widgets sheet" into sc-dev 2021-02-19 10:31:19 +00:00
Tony Wickham 15883891ea Subtract taskbar size from DeviceProfile#availableHeight
Normally availableHeight excludes system insets, but taskbar is added
after availableHeight is calculated. This discrepency causes some bad
calculations such as TaskView size.

Test: touch nav bar when in an app with taskbar present, ensure the
task doesn't jump due to incorrect calculation

Fixes: 179478728
Bug: 171917176
Change-Id: I16d39d3e1d9708e2a64c81b1ac24466f9567d1b9
2021-02-18 11:39:10 -08:00
Jon Miranda cabc13a376 Update popup container to match spec.
Bug: 175329686
Bug: 178935485
Test: manual
Change-Id: Ia7507bd4dd6c6db0cdd6a29a0c1d0695aae7d488
2021-02-18 14:11:41 -05:00
Hyunyoung Song db9a53d9aa Add group highlighting to AA+ result
Bug: 180071886
Test: manual
Change-Id: Id1cc3d7400e1a7fe41af272d689aa9315030b420
2021-02-18 02:19:27 -08:00
Jonathan Miranda 26311d9850 Merge "Update folder to new specs." into sc-dev 2021-02-18 03:14:50 +00:00
Lucas Dupin 2db3ded7f9 Merge "Conform to new naming" into sc-dev 2021-02-17 23:25:02 +00:00
Jon Miranda 22679f8804 Update folder to new specs.
- Fix folder animation not lining up perfectly with foldericon.

Bug: 175329686
Test: manual check that the animation works as expected
Change-Id: I5c35525102e2ab7ca542bc08568706531e531890
2021-02-17 17:44:03 -05:00
Sunny Goyal 3c5e748b36 Merge "Removing menu and dialog for custom actions hanlding. These do not work well with gesture-nav and can potentially block the Launcher UI." into sc-dev 2021-02-17 21:40:26 +00:00
Steven Ng b686972b7d Extract common codes for personal / work profile tabs
These codes can be reused in the FullWidgetsSheet which we will be
adding tabs for personal / work profile.

Test: Set up work profile and then switch person / work profile tabs
      in the AllAppsContainerView.

Bug: 179797520

Change-Id: Ib7eb1190e1384a664cbe3e34411c9362f1f6db03
2021-02-17 16:22:42 +00:00
Lucas Dupin 2cdc6bae39 Conform to new naming
Resources were renamed from main/accent to primary/secondary.

Test: make
Bug: 171916625
Change-Id: Ic71cf716eba9f57d27869dffa501219c41c999ec
2021-02-16 17:47:33 -08:00
Steven Ng 0be3a615d9 Render preview layout in full widgets sheet and bottom widgets sheet
Video: https://drive.google.com/file/d/1gRE0axaq6tm3R_gjSon0RR5lC8HCmwee/view?usp=sharing

Test: Install a sample app which provides a preview layout.
      Go to full widgets sheet to observe widget previews are correctly
      displayed for bitmap previews, layout previews and placeholder
      previews. Repeat the same for bottom widgets picker.
      Pin a widget from a sample app which provide a custom RemoteViews
      preview, observe the custom RemoteViews is correctly rendered.

Bug: 179797520
Change-Id: I2ccd1f77b54a2430d842ee25349fa6e54b9159dc
2021-02-16 19:34:03 +00:00
Sunny Goyal 384b578ab2 Removing menu and dialog for custom actions hanlding.
These do not work well with gesture-nav and can potentially
block the Launcher UI.

Instead exposing on custom actions with keyboard accelerator and
using thee internal arrowPopup for resize options
Fixing SecondoryDropTarget not sending appropriate stats log

Bug: 179854703
Test: Verified on device
Change-Id: I268690f8a937896e4350496128a38959003f8939
2021-02-16 10:45:06 -08:00
Jonathan Miranda 8dd4ddc7ae Merge "Add border spacing and fixed cell height to grid." into sc-dev 2021-02-16 18:38:38 +00:00
Steven Ng e92bc55d12 Make all widgets collapsed in the full widget picker by default
Changes:
1. Add a WidgetListHeader view for showing icon, app name and a subtitle.
2. Only WidgetListHeaders are always visible to users in the full widget
   picker.
3. Only one widgets list from an app is visible in the full widget picker
   at any one time.

Test: Auto: run add robolectric tests under widget/picker
      Manual: Open full widgets picker. Then, expand and collapse apps.
      Video: https://drive.google.com/file/d/1gzfeEm5IOAu0qHsO77OTS2eMfU7CHJiL/view?usp=sharing

Bug: 179797520
Change-Id: Idac58be23dfeafcb79b3c61b4972d3addb462de1
2021-02-15 17:46:38 +00:00
Jon Miranda 228877d37c Add border spacing and fixed cell height to grid.
- Border spacing is the spacing between the cells.
- Workspace cell height is now fixed, and we allocate
  all the "extra" space to three different variable height
  areas.

* Built behind ENABLE_FOUR_COLUMNS flag because it hinders the
default grid.

Bug: 175329686
Test: - set border spacing to 0 and confirm matches prior layout
      - test drag and drop still worked
      - test reordering
      - test widgets
      - test folders
      - test multiwindow

Change-Id: Ic6f3dff577d28ff214bda4b0a787ec7fd08c108b
2021-02-10 17:22:37 -05: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
Sunny Goyal 3186fbaed4 Merge "Adding support for keyboard based drag and drop" into sc-dev 2021-02-06 02:55:06 +00:00
Sunny Goyal a4647b681f Adding support for keyboard based drag and drop
For keyboard DnD, we use Accessible DnD implementation.
A placeholder FloatingView draws the focus indicator
for the virtual views

Test: Visible
Bug: 178781566
Change-Id: I632fc7377dffa1e05e3f0a9c3ad18641deb5a1a4
2021-02-05 13:05:24 -08:00
Lucas Dupin 468646cad7 Merge "Style updates" into sc-dev 2021-02-05 17:57:20 +00:00
Lucas Dupin 993fed2346 Style updates
- Make pop ups use system colors
- Text colors in dark theme should also use system colors

Test: visual
Bug: 179427049
Change-Id: I9c0eb2b6970ff9bf66fe1d5c0040b10bfa2087b0
2021-02-04 17:16:08 -08:00
Tony Wickham 794fe4f58e Add Hotseat items to Taskbar
- Currently supports WorkspaceItemInfo (e.g. normal app icons
  including hotseat predictions and pinned deep shortcuts).
- Currently doesn't support Folders, Notification dots, or
  long press.

Some technical details:
- Always allow HotseatPredictionController updates given the
  Hotseat is always showing even when Launcher is stopped.
- Represent Taskbar Hotseat items as BubbleTextViews, to
  allow for normal click handling etc. When the hotseat is
  updated, we reuse the same BubbleTextViews that were
  initially inflated, and just reapply the new info.
- Add new BubbleTextView iconDisplay for Taskbar, to allow
  for different treatment such as icon size.

Bug: 171917176
Change-Id: I325eb39051f2dc69228b39b5c40ed0cbdad8e200
2021-02-01 18:29:06 -08:00
Schneider Victor-tulias 5f7f4cb35d State download information in content description whether or not there was an update.
Talkback wasn't announcing the incremental download/install progress if the progress wasn't updated. Updated BubbleTextView to update the content description with the incremental download/install info if the progress bar should be shown.

Fixes: 149444435

Test: manual
Change-Id: I3efe6e31cec389da4119a2179a341aedd074a0b7
2021-02-01 19:01:11 +00:00
Lucas Dupin 29cd327066 Inherit theme colors on app drawer and folder
This way, changes on Theme.DeviceDefault will be reflected on launcher
as well.

Bug: 173561945
Test: visual
Change-Id: I297560253242476f34c47fcd845c44e96873a8b2
(cherry picked from commit fc82c5a92076116b16d0b1b6c4eb6acf5120b8bb)
2021-01-27 16:24:58 +00:00
Sunny Goyal b18501402c Merge "Fixing preview rendering in device search mode" 2021-01-15 19:20:26 +00:00
Sunny Goyal e733e79946 Fixing preview rendering in device search mode
When the flag is disabled, search box may not show in preview

Bug: 177500166
Test: Presubmit
Change-Id: I064ba6ca22e71030056a4ceafea27e6ef0517d01
2021-01-14 14:17:13 -08:00
Samuel Fufa fd58d23cdf Migrate from Plugin SearchTarget to API search Target [1/3]
Setup architecture for separation between aosp and quickstep search as setup for switch to android.app.SearchTarget

Bug: 177223401
Test: manual
Change-Id: Iefd069a34d5e5551bf731e9171958e93377774aa
2021-01-12 19:46:25 -06:00
Schneider Victor-tulias da5e714ca1 Fix homescreen deep shortcuts text spanning two rows.
Deep shortcut text can span two lines on certain languages. Set translation character limits and increased options popup width.

Fixes: 175698383

Test: manual

Screenshot: https://screenshot.googleplex.com/4BArwKVSFg3VbTc.png
Change-Id: I263b859246fa6475591a65f92189e41a920beefe
2021-01-06 16:39:58 -05:00
Sunny Goyal 9b1e77377b Removing shelf from 2-button gesture mode
Test: Manual
Bug: 175137718
Change-Id: Ifb64b4dcac53252aefa8ee0bd6434f90f1d868b7
2021-01-05 19:07:21 +00:00
Schneider Victor-tulias 20bbaa3390 Add additional fake task views on overview gesture completion.
Added motion pause listening to animate an additional fake task view on overview gestures in the sandbox.

Test: manual

Demo: https://drive.google.com/file/d/1EpewbIAxiMUEz0Fqdfbok5q9xpWS6NWz/view?usp=sharing
Change-Id: Ifd0aed0a2bbb3204ae32c833b8466952679700e3
2020-12-22 16:10:09 -08:00
Samuel Fufa 2ea01e4871 Separate QSB from on device search
Bug: 175125073
[Preview attached to BR]

Change-Id: If967d95e32b58263ede5eb8a3c1b773cef789f28
2020-12-09 12:46:30 -06:00
Sunny Goyal 54834b0909 Merge commit '2cd8dd628268a177357afcccfeb7da8639e3a061' into merge_ub-launcher3-master_6976145
Test: manual, presubmit on the source branch
    x20/teams/android-launcher/merge/ub-launcher3-master_master_6976145.html

Change-Id: Ic13b1a20cc3d555e8e86717ca0da97103ff09c85
2020-11-16 14:40:43 -08:00
Samuel Fufa 9ee4e86cf8 Merge "Search support for widgets with config activity" into ub-launcher3-master 2020-11-11 16:21:01 +00:00
Hyunyoung Song 5278e85c4c People row text size fix
Change-Id: I912f8d41bf49215988f37a2405086bf4d737af99
2020-11-10 10:39:54 -08:00
Samuel Fufa ffd2b6d25e Search support for widgets with config activity
Shows widget preview in search if widget requires config.

preview: https://drive.google.com/file/d/1q1ROu7-OUGfskDMRxXPNQMdr3T-WMMkv/view?usp=sharing
Bug: 168321831
Test: Manual
Change-Id: I6c1c168ebac4ce33a4234e8a417eba789f664f43
2020-11-10 10:16:02 -06:00
Samuel Fufa 3116dc918f Resolve search scroll hightlight issue
After getting the index of the first item that should be highlighted, Section decorator should not assume getChildAt(index) will return item at position. Instead use findViewHolderForAdapterPosition.

Bug: 170665892
Change-Id: Id81d021bde8868184013e8d51e49af7842b64125
2020-11-09 16:35:43 -06:00
Samuel Fufa a204de7d12 Merge "Initial setup for widgets in Search" into ub-launcher3-master 2020-11-09 18:33:51 +00:00
Hyunyoung Song 003859cdd0 Show remote action's description in SearchResultIconRow
Validated against Pixel Tips corpus

Change-Id: I3c3f8eb69007a97e55e2ef08e7f4e0b800bfe247
2020-11-09 01:38:20 -08:00
Samuel Fufa 37432444fc Initial setup for widgets in Search
LiveSearchManager creates AppWidgetHost when user starts a new search session and destroys it when user returns to home. In addition, it also manages the creation and caching of PlaceholderSearchWidget which can be used to create AppWidgetHostViews.
Bug: 168321831
Test: Manual

Change-Id: I06a893028e55aa6e0702a4f1cd7a2edbb1f61671
2020-11-07 10:07:33 -06:00
Samuel Fufa 984e0d0a63 Show settings icon at start of settings results
Bug: 170792963
Test: Manual
Screenshot: https://screenshot.googleplex.com/MVBtDZGtQ3aChwU
Change-Id: I16a28a7bd9e3129b40102e020cd7c0111e6fe29b
2020-11-06 10:14:41 -06:00
Samuel Fufa 6e5efb0929 Consolidate Hero search result with SearchResultIconRow
With this, we can now show app title and support drag/drop for shortcut results.

Bug: 172245107
preview: https://drive.google.com/file/d/1A4eKKTDPht-MDbfA2VFI3OuAO36fc3AS/view?usp=sharing
Change-Id: Icf94a2d23b44bfe5527aea71e27178906e5deb3e
2020-11-05 11:57:35 -06:00
Tracy Zhou ae567f96f6 Merging from ub-launcher3-master @ build 6952418
Test: manual, presubmit on the source branch
x20/teams/android-launcher/merge/ub-launcher3-master_master_6952418.html

Change-Id: Id8ec665ff7be486b794807f6524e385728ea7717
2020-11-04 12:33:10 -08:00
TreeHugger Robot a90ddeea57 Merge "Settings/Play/Suggest layout polish" into ub-launcher3-master 2020-10-28 22:12:52 +00:00
Joshua Trask b0f897cda8 Merging from ub-launcher3-master @ build 6934851
Test: manual, presubmit on the source branch
x20/teams/android-launcher/merge/ub-launcher3-master_master_6934851.html

Change-Id: Ie082cfabfc07e26db9d0bbb563376291b2b30491
2020-10-28 12:13:40 -04:00
Sunny Goyal b694a69f53 Integrating snapshot logging in Launcher
> Workspace snapshot is logged when the workspace loads (at most once a day)
> Removing unnecessary thread jumping when logging folders
> Preference snapshot is logged on process start and whenever something changes

Change-Id: I93767de89b11522d843c0e8300d1f108c78f6d90
2020-10-27 11:25:43 -07:00
Hyunyoung Song 9fc27da5f8 Settings/Play/Suggest layout polish
Bug: 170792963
Bug: 170750779
Change-Id: I69b09f5360e165c3b1b33e259cdd0f390ce6fa60
2020-10-27 16:45:54 +00:00
Winson Chung 87f2b09072 Merging from ub-launcher3-master @ build 6925377
Test: manual, presubmit on the source branch
x20/teams/android-launcher/merge/ub-launcher3-master_master_6925377.html

Change-Id: I928b100c8f41abff34047df69d988622123f9939
2020-10-23 10:16:50 -07:00
Winson Chung f99351888c Revert "Revert "Merge commit '8d14dbe041199d611839140f1c9285fd4174e9f4' ...""
This reverts commit 087a9e39b6.

Change-Id: I05b17a6e4aaaef6de3c2fa26aad45a39eb2833f9
2020-10-23 09:27:48 -07:00
Andy Wickham 1027468233 Makes Plugin Settings gear adjust to dark mode.
It wasn't visible in dark mode before because it was
black on black. This makes it adjust automatically.

Change-Id: I5176cffc01842509ddafc4f30ff5029a0c4b8050
2020-10-19 19:06:52 -07:00
Samuel Fufa 314761a808 Setup SearchResultIcon for single cell results
SearchResultIcon will be able to render apps, shortcuts and remote actions. It can also handle its own focused state drawing.

Screenshot: https://screenshot.googleplex.com/C3KgjJtLQTBPgaf

Bug: 170752716
Test: Manual
Change-Id: I460a9c128ea3f5814784e342c5d5fa5b7e310882
2020-10-15 14:32:19 -07:00