Commit Graph

12092 Commits

Author SHA1 Message Date
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
Hyunyoung Song
a907a995c9 Hide keyboard only when scrolling happens
Bug: 179307221
Test: see attached video

Change-Id: I9b13c8f62122a6d7bf56a28c830be9a9dbfee52a
2021-03-16 00:05:04 -07:00
Vinit Nayak
2b30076aba Merge "Initial commit of new split screen work." into sc-dev 2021-03-16 01:01:08 +00:00
Steven Ng
0226d1ad79 Replace DragView bitmap with drawable
This is a preliminary work for local color extraction. In order to
apply local colors extracted from wallpaper to AppWidgetHostView
during drag, we need to hold a reference of the dragging
AppWidgetHostView.

In this CL, the following changes are made:
1. Instead of using bitmap image directly for icons, folders, shortcuts,
   legacy widget drawable preview, a BitmapDrawable wrapper is
    introduced.
2. Introduce a WidgetHostViewDraggableDrawable which draws
   LauncherAppWidgetHostView directly to canvas. No more bitmap
   generation overhead.
3. Remove drag outline from the drag logic because this will be replaced
   by a new grid color hint UI: https://screenshot.googleplex.com/7jBEVeuxFecFKKT.png

Test: Add: add widgets, shortcuts from widgets tray.
           add icons from all apps.
           create folder.
      Drag: drag existing widgets, shortcuts, folders and icons around

Bug: 182282587
Change-Id: Ia45ff756ea5bb80cf0761f0727a9453d50c204c0
2021-03-16 00:02:38 +00:00
Tony Wickham
9f9787ad76 Merge "Remove insets due to Taskbar, except on workspace elements" into sc-dev 2021-03-15 23:41:55 +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
Samuel Fufa
6547d098c6 Merge "[Search]Implement search session cache in AllApps" into sc-dev 2021-03-15 19:23:06 +00:00
Hyunyoung Song
1b56eb4e6f Merge "Fix AA+ decorator drawing out of bounds issue / Make AA+ opaque" into sc-dev 2021-03-15 18:18:21 +00:00
Samuel Fufa
342e9df03c [Search]Implement search session cache in AllApps
- Skips SearchTarget reapplication if the id has not changed
- Resolves Incessant  subtitle on short row

Bug: 181510793
Test: Manual
Change-Id: Ic10ef9682fd3700616b7b1b7a60e82b5f2250fd3
2021-03-15 11:31:51 -05:00
Yogisha Dixit
27cdff4153 Merge "Do not launch configuration activity if CONFIGURATION_OPTIONAL." into sc-dev 2021-03-15 14:36:31 +00: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
Yogisha Dixit
2560077478 Do not launch configuration activity if CONFIGURATION_OPTIONAL.
Test: Created a placeholder widget with CONFIGURATION_OPTIONAL and checked
that configuration activity was not launched.
Bug: 177977976

Change-Id: I854c9b3fb6007fd98009182f68fbf36d4571a81f
2021-03-15 12:24:52 +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
5e7c89c36e Merge "Better estimate the height of widget recycler view" into sc-dev 2021-03-15 10:01:27 +00:00
Hyunyoung Song
133a5d5eb6 Merge "Do not reset workprofile when on search result page" into sc-dev 2021-03-14 20:30:18 +00:00
Hyunyoung Song
f5767cf928 Do not reset workprofile when on search result page
Bug: 182443195
Test: Manual
Change-Id: I2cb1d11949233273881dc9d387e68c9878d49096
2021-03-12 21:29:29 -08:00
Hyunyoung Song
f72f513e6c Fix AA+ decorator drawing out of bounds issue / Make AA+ opaque
Bug: 182425322
Bug: 182305279

Test: manual

Change-Id: Ib9fbd09613e8e1c50a9d75fb2ab9546d2f5230b7
2021-03-12 21:23:47 -08:00
Tony Wickham
8ecb59189f Merge "Make ENABLE_TASKBAR and ENABLE_OVERVIEW_GRID DebugFlags instead of DeviceFlags" into sc-dev 2021-03-13 02:35:49 +00:00
Jonathan Miranda
1a8a20b3c9 Merge "Do not add arrow to OptionsPopupView." into sc-dev 2021-03-13 02:29:06 +00:00
Tony Wickham
e2ed4b37cc Merge "Replace taskbar hotseat with real hotseat when folder is open" into sc-dev 2021-03-13 02:17:49 +00:00
Tony Wickham
145b7fd68c Remove insets due to Taskbar, except on workspace elements
Test: go to all apps, ensure no bottom insets/limited nav bar
protection; go to overview, ensure no extra bottom padding

Bug: 171917176
Change-Id: I09dc589e1cb8d3b673bf2b38e42284557413e011
2021-03-12 16:46:54 -08: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
Jon Miranda
e92a4add99 Do not add arrow to OptionsPopupView.
Bug: 175329686
Test: open home menu, notice no arrow
      open long press menu, notice arrow still visible
Change-Id: I3f480d570b5134376324d4b8051da639ee8d8b27
2021-03-12 16:46:08 -05:00
Tony Wickham
647baded97 Make ENABLE_TASKBAR and ENABLE_OVERVIEW_GRID DebugFlags instead of DeviceFlags
Test: reinstalled and flag values stayed the same and work
Change-Id: Icd3d6a5333de29d0e054a7a2eed512bfbfa9d4e3
2021-03-12 12:51:37 -08:00
Hilary Huo
b3545651e2 Merge "[settings-pixel-search] Add slice timeout to avoid showing empty slice view" into sc-dev 2021-03-12 19:58:38 +00:00
Tony Wickham
ae72b46b2c Replace taskbar hotseat with real hotseat when folder is open
- Seamlessly show real hotseat and hide taskbar hotseat, while
  keeping rest of taskbar visible
- Update MultiValueAlpha to allow for taking max alpha instead
  of blending, and use that for Hotseat
- Fix folder open bounds on home screen when taskbar is present

Test: Open folder from taskbar on home, can drag out items
Bug: 182079330
Bug: 171917176
Change-Id: I7c1983e3219b1341cf233260f0ccac9051c4dc14
2021-03-12 11:05:43 -08:00
Jon Miranda
c1e66b523e Fix folder outline not matching the v28 radius.
Bug: 175329686
Test: manual, open folder and verify no visual artifacts
Change-Id: If7cfaf6f95e43ad6f2636b136bc98961554ebf36
2021-03-11 19:05:45 -05: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
Hilary Huo
20a7cfbd3c [settings-pixel-search] Add slice timeout to avoid showing empty slice view
Bug: 181810946

Test: m
Change-Id: Icd83bbf428bf7d87e3957a6f6d888142c6008da3
2021-03-11 20:07: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
Alina Zaidi
c322510b2a Merge "Implement pipeline for a simple search based on query string matching on app names in WidgetsListBaseEntries." into sc-dev 2021-03-11 00:18:00 +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
Jonathan Miranda
970a410bd7 Merge "Register setStartingWindowListener so launcher can defer icon drawing/crop correctly." into sc-dev 2021-03-10 21:12:57 +00:00
Jonathan Miranda
fb7b9fd8c3 Merge "Fix icon text size being calculated in DP instead of SP." into sc-dev 2021-03-10 19:09:29 +00:00
Steven Ng
a061cf3387 Merge "Show an empty view when there is no widget available" into sc-dev 2021-03-10 18:57:07 +00:00
Jon Miranda
fb05759bab Register setStartingWindowListener so launcher can defer icon drawing/crop correctly.
Bug: 177264697
Test: manual
      close all tasks
      launch app, note that shell is drawing icon & launcher correctly crops
      return home
      launch same app, note that launcher draws the icon

Change-Id: Id320eb9e3e03f861cc8e4adec739b8faf29adda0
2021-03-10 13:07:26 -05: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
Sunny Goyal
43b9310197 Merge "Revert "Revert "Removing insets controller animation as part of ..."" into sc-dev 2021-03-10 17:04:58 +00:00
Jon Miranda
378c11f041 Fix icon text size being calculated in DP instead of SP.
Bug: 175329686
Test: manual, change font/display size
Change-Id: Ic8c6260444d18df64ccee4c2bcfbc2332a327da9
2021-03-10 10:29:35 -05:00
Sunny Goyal
b5181c8c39 Revert "Revert "Removing insets controller animation as part of ..."
Revert "Revert "Moving insets animation to StateHandler so that ..."

Revert submission 13823490-revert-13810332-insetcontroller-CLXXLCZAUM

Reason for revert: Fixed original error in ag/13823726
Reverted Changes:
Ie19a3fd90:Revert "Moving insets animation to StateHandler so...
I4eb33772a:Revert "Removing insets controller animation as pa...

Change-Id: I7fb395c51ea99081913bc99515257e98c0a32754
2021-03-10 07:39:12 +00:00
Pasty Chang
ea39d1603f Merge "Revert "Removing insets controller animation as part of all-apps..."" into sc-dev 2021-03-10 07:01:25 +00:00
Pasty Chang
13358f65ab Revert "Removing insets controller animation as part of all-apps..."
Revert "Moving insets animation to StateHandler so that it can b..."

Revert submission 13810332-insetcontroller

Reason for revert: QsbLayout#getEditText() return object is changed, but extended class HotseatQsbWidget wasn't updated.

https://android-build.googleplex.com/builds/submitted/7197042/aosp_crosshatch-userdebug/latest/view/logs/build_error.log

Reverted Changes:
If6a088d14:Removing insets controller animation as part of al...
I296415604:Moving insets animation to StateHandler so that it...

Change-Id: I4eb33772acd887d6e1d92a9ecde41cf1e0687896
2021-03-10 06:58:51 +00:00
Sunny Goyal
c668a2a5bb Merge "Removing insets controller animation as part of all-apps opening" into sc-dev 2021-03-10 01:58:06 +00:00
Sunny Goyal
de18647f91 Merge "Removing unused keyboard handling code" into sc-dev 2021-03-10 00:13:27 +00:00
Samuel Fufa
dc016f37a2 Fix QSB tap crash
Launcher should use LCM of supported getSupportedItemsPerRowArray instead of product.

Bug: 182236647
Test: Manual
Change-Id: Ia0ad1158a841068c29ed09bf7f598f14c410092f
2021-03-09 10:00:05 -06:00
Hyunyoung Song
c2b750797c Merge "Instrumenting flinging all apps for jank" into sc-dev 2021-03-09 13:55:02 +00:00