Commit Graph

16456 Commits

Author SHA1 Message Date
Holly Jiuyu Sun ae1c56e34d Merge "[play] Add debug config flag to GMS Play." into udc-dev 2023-05-05 06:55:43 +00:00
Brandon Dayauon 017e7a2e06 ENABLE_TWOLINE_ALLAPPS default true (only in teamfood)
- modified test so enabling two line all apps work
- have appIconSelector() select from content description

bug: 275116822
test: manual
Change-Id: Id3ccc6859b55d6b8a80ca509d420409d484207cf
2023-05-04 19:37:48 -07:00
Fengjiang Li 1ecbfe153c [3/n] Update StartupLatencyLogger's @VisibleForTesting
Change to use (otherwise = VisibleForTesting.PROTECTED)

Bug: Bug: 278092752
Test: print launcher startup latency logs locally
Flag: not needed
Change-Id: I19630cc3436370e4d6a846e58dee002e5d28d5d7
2023-05-04 16:13:24 -07:00
Brian Isganitis 64ee67c6b5 Merge "Add header protection for Taskbar All Apps search bar." into udc-dev 2023-05-04 22:20:46 +00:00
Sunny Goyal db19958b82 Removing unused wallpaper-scrim feature
Bug: 270393604
Test: Presubmit
Flag: N/A
Change-Id: I10df3a96eb26b9871eb1b330ea5b2c0797d0668d
2023-05-04 14:02:41 -07:00
Josep del Río 229d11892a Merge "Close floating panels on Launcher when using Escape" into udc-dev 2023-05-04 20:50:28 +00:00
Charlie Anderson 178802d35c Merge "Revert "Changing GridMigrationTask to use ModelDbController directly"" into udc-dev 2023-05-04 17:58:01 +00:00
Treehugger Robot c2dca5fec4 Merge "Always insetting the widget by a minimum of 6dp" into udc-dev 2023-05-04 17:48:48 +00:00
Josep del Rio 1d976c6702 Close floating panels on Launcher when using Escape
This change will make the Escape key close floating panels in
Launcher.

Bug: 280801803
Test: Flashed on device, tried with physical keyboard and panels
will close.

Change-Id: Ie09e57716a7be74638037abe6272b47eec1b8a6c
2023-05-04 16:07:50 +00:00
Charlie Anderson 30bb3a247a Revert "Changing GridMigrationTask to use ModelDbController directly"
This reverts commit 9ef41413e0.

Reason for revert: This was the only launcher CL during the time  b/280669657 and 280680602 occurred

Change-Id: Id7107f0935f84908ca87e1ae4c62ab05efe41a24
2023-05-04 15:19:58 +00:00
Fengjiang Li efb0c4e98c Merge "[2/n] Refactor StartupLatencyLogger 1. Use kt stirng's $substitutions for StartupLatencyLogger 2. Add "otherwise =" for @VisibleForTesting" into udc-dev 2023-05-04 13:39:08 +00:00
Nick Chameyev 1aa2383d26 Merge "[Unfold animation] Start Launcher animation preemptively to synchronize the first frame" into udc-dev 2023-05-04 09:36:04 +00:00
Fengjiang Li 91503ecbd6 [2/n] Refactor StartupLatencyLogger
1. Use kt stirng's $substitutions for StartupLatencyLogger
2. Add "otherwise =" for @VisibleForTesting

Bug: 278092752
Test: tested on phone, foldable and tablet, print latency logs in logcat
Change-Id: If56b90dafbff0e0b1f7ea076581d71a0b5271d71
2023-05-03 15:51:53 -07:00
Sebastián Franco db982003b2 Merge "Adding unit test to ReorderAlgorithm" into udc-dev 2023-05-03 20:13:15 +00:00
Sunny Goyal 6c304b157d Always insetting the widget by a minimum of 6dp
Removing default widget padding logic. Also widget padding it applied
at ShortcutAndWidgetContainer so that the widgetView always has the
correct size.

Bug: 274826296
Bug: 257589413
Test: Verified using screenshots
Flags: N/A
Change-Id: Id4b5e94db6ec7b2aa3dca87b1e9ccc831b608cac
2023-05-03 12:18:33 -07:00
Sebastian Franco 45b39b50e5 Adding unit test to ReorderAlgorithm
Adding 100 different test cases for the ReorderAlgorithm.
The test cases are randomly generated using generateRandomTestCase()
the boards are generated once and then written in the file
reorder_algorithm_test_cases. I will leave the code to generate
the boards in the Test even though is not used anymore in case
we need to generate more boards later on.

Also, I found that the ReorderAlgorithm was not deterministic,
meaning that it could generate two different results with the same
inputs (views positions and view being drag positions), because
it was traversing a map whose has was the object id which is
random. So I sort the views before traversing them.

Bug: 229292911
Test: atest ReorderAlgorithmUnitTestCase

Change-Id: I196eb8f1dafcb57d5259969268c458129ae4f46b
2023-05-03 11:22:09 -06:00
Sunny Goyal 9ef41413e0 Changing GridMigrationTask to use ModelDbController directly
instead of using content uris

Bug: 277345535
Test: Updated tests
Flag: Presubmit
Change-Id: Ib62db3334c01d9e7d27ae7b02ea703d046e2bcaa
2023-05-03 08:54:14 -07:00
Nick Chameyev 705c665c06 [Unfold animation] Start Launcher animation preemptively to synchronize the first frame
Starts unfold animation in Launcher right after receiving
configuration change for the unfolded screen.
This makes sure that before we unblock the screen we
have the first frame of the unfold animation ready
in Launcher (transformations are applied).

Bug: 271099882
Test: atest com.android.systemui.unfold.util.PreemptiveUnfoldTransitionProgressProviderTest
Test: manual testing fold/unfold, checking perfetto traces
Test: test with flag enabled/disabled
Change-Id: Icb8f91f9264248600d4bed14811445f50aac99c7
2023-05-03 11:35:03 +01:00
Fengjiang Li c15679d512 Merge "[1/n] Launcher Startup Latency: add StartupLatencyLogger to launcher3 and log startup latency" into udc-dev 2023-05-03 03:18:46 +00:00
Fengjiang Li 5a36c17a32 [1/n] Launcher Startup Latency: add StartupLatencyLogger to launcher3 and log startup latency
More details at "Log Startup Latency" section in go/launcher-startup-latency

Test: tested on phone, foldable and tablet, print latency logs in logcat
Bug: 278092752
Change-Id: Ibf269b0ecd6007d29b95e36f65ab6f02c45deb3a
2023-05-02 17:08:05 -07:00
Jeremy Sim 7f169c7c6d Fix animation canceling crash bug (short swipe during split select)
This patch fixes a bug where the user could cause a crash by making a gesture during the Overview > OverviewSplitSelect animation.

Within Overview, the user is able to make an upward gesture from the bottom of screen to return to Home. However, if the gesture is very short, the user doesn't go back to Home and instead stays in Overview. Under normal situations this doesn't cause any problems. But if we are in the middle of an animation, the short gesture actually triggers an animation cancel followed by an immediate goToState() to the same state that it was already in. This causes problems with the OverviewSplitSelect transition because reset() is called in the middle, clearing important split select data and causing a crash.

Fixed by changing a conditional to detect if we are this type of situation, and allowing the animation to play out in these cases.

Fixes: 272793237
Test: Manual
Change-Id: I4426204b9c8fc55853cf7df31a336ccaee2f5885
2023-05-02 15:18:00 -07:00
Jordan Silva 567372fbda Fix text sizes and alignment in drop target
Drop target button texts are being resized incorrectly.
When both buttons are visible, the text is considerably smaller compared
to only one visible button. This happens even for the default display and font scale 1.

Fix: 271279172
Test: manual. test all combinations of display size and font size.
Test: HomeScreenEditStateImageTest
Change-Id: Ib001dcf8b096c65b138946bdad49cf8199fb5b1d
2023-05-02 14:57:49 +02:00
Vinit Nayak 90dce8b8b2 Merge "Refactor handling data launching split screen to separate class" into udc-dev 2023-05-01 19:55:21 +00:00
Sebastián Franco c9cc7ea612 Merge "Set start time for open folder animation before starting the animation" into udc-dev 2023-04-29 02:39:01 +00:00
Vinit Nayak 2a014d4c0d Refactor handling data launching split screen to separate class
* SplitSelectDataHolder contains logic for knowing how
to launch split, separate from the actual API calls to launch split

Flag: ENABLE_SPLIT_LAUNCH_DATA_REFACTOR
Bug: 279494325
Test: Tested w/ all 6 types of launches noted in
SplitSelectDataHolder#@SplitLaunchType.
Also checked to make sure most-recent running tasks are
still being used where applicable.

Change-Id: I8114f87e9956b100622c80f578e291937ed4eeac
2023-04-28 18:00:22 -07:00
Stefan Andonian 5961d96235 Merge "Move Wallpaper RPC call to background thread." into udc-dev 2023-04-28 20:13:40 +00:00
Stefan Andonian efcff6ceb6 Move Wallpaper RPC call to background thread.
Bug: 251502424
Test: Used logs to time it. This was taking anywhere from 3ms to 19ms on my Pixel 7 Pro device.
Change-Id: I4e9ce55c1269a31f15e910628153c3dfdfd26649
2023-04-27 21:29:39 +00:00
Schneider Victor-tulias 8c1bffb24f Merge "Remove unused debug logs" into udc-dev 2023-04-27 17:44:42 +00:00
Luca Zuccarini 0c856a0c94 Merge "[Toast] Enable background drawables by default in Teamfood." into udc-dev 2023-04-27 15:29:02 +00:00
Holly Sun 48d0645a2e [play] Add debug config flag to GMS Play.
Bug: 274633778
Flag: ENABLE_SEARCH_UNINSTALLED_APPS. Off
Test: manual. adb shell setprop log.tag.GmsPlay VERBOSE
Change-Id: Ic2232011f039893998adbad2fb93f34e8f6bd85c
2023-04-26 17:22:44 -07:00
Vinit Nayak af55572713 Merge "Add logs for PackageUpdatedTask" into udc-dev 2023-04-26 23:05:42 +00:00
Andy Wickham a4627d2235 Merge "Add long swipe from app to overview gesture (with flag)." into udc-dev 2023-04-26 21:30:53 +00:00
Vinit Nayak 6106ae9ac7 Add logs for PackageUpdatedTask
* That's the bit that updates new packages for work profile,
at least from command line.
* There is variability in how long it could take work profile
apps to show up, from 2-8 seconds.

Bug: 243688989
Change-Id: I710befc5f17b4a16bff523eb03f1e88975cafd43
2023-04-26 13:21:57 -07:00
Andy Wickham 830e4b7ce0 Add long swipe from app to overview gesture (with flag).
High level:
 - As you swipe up from an app (OtherActivityInputConsumer),
   a state transition animation to All Apps is created in
   AnimatorControllerWithResistance. The animation is played
   alongside the Recents resistance animation (i.e. past the
   settling point of Overview, which is at mCurrentShift 1).
 - The actual state transition to All Apps only happens if you
   release your finger in the "all apps region." This is set to
   mCurrentShift 2, so double the distance that Overview rests.
 - A haptic plays whenever you enter or exit this region, and
   the all apps animation is set to 0 until the region is
   active. This is so it's clear that something different is
   happening.
 - The panel that was previously used for tablets is now used
   for phones during this transition. It comes in at full
   opacity when you enter the region, and the contents (apps
   and search suggestions) fade in as you continue swiping.
 - The only gesture that is recognized in the all apps region
   is a fling downwards, which will return you to the previous
   app. Otherwise a left/right/up fling or slow release will
   finish the all apps transition.
 - The threshold is ignored if the flag is disabled (default)
   or if FallbackActivityInterface is active.

Flag:
The threshold is ignored if ENABLE_ALL_APPS_FROM_OVERVIEW is
disabled (default).

Bug: 259619990
Bug: 275132633
Test: Manual with and without the flag enabled
Change-Id: Ie311b77252416d97677b2c56fad61dfd392b6fe8
2023-04-26 10:52:04 -07:00
Fengjiang Li 216ae0f7ec Merge "Fix NPE of predictive back in TaskbarAllAppsSlideInView" into udc-dev 2023-04-26 05:15:33 +00:00
Treehugger Robot 826a5c8e71 Merge "Move Block 23 flag back into its section" into udc-dev 2023-04-26 02:37:32 +00:00
Sebastian Franco 57fc157e25 Set start time for open folder animation before starting the animation
The start time of the animation was being set after the animation started
causing the animation to jump to an start time after it already
started wich was very obvious when setting the animation speed to 0.

To test set the aimation speed to zero like so:

  adb shell settings put global animator_duration_scale 0
  adb shell settings put global transition_animation_scale 0
  adb shell settings put global window_animation_scale 0

Fix: 279662507
Test: explained above
Test: FolderScreenShootTest will test it in the future
Change-Id: Id6e10720ffdf64e062e533cd3187f386f57ae906
2023-04-25 16:42:03 -07:00
Vinit Nayak 4549e2c851 Merge "Add link to block directory" into udc-dev 2023-04-25 23:21:16 +00:00
Vinit Nayak 80a3213d6b Merge "Route PredictedAppIcon clicks through launcher" into udc-dev 2023-04-25 23:20:41 +00:00
Vinit Nayak 1bb594c72b Route PredictedAppIcon clicks through launcher
* This allows us to intercept launching predicted apps for
split-screen if user is in split selection flow
* Defaults to existing behavior of ItemClickHandler.INSTANCE
if we do not need to intercept the click

Bug: 276361926
Flag: ENABLE_SPLIT_FROM_WORKSPACE_TO_WORKSPACE
Test: Launches as expected when not in split, launches in
split when selected as second app to initiate split with

Change-Id: Ieb45137ae89da340d314e995f4f6eb1f8b49a42f
2023-04-25 12:31:56 -07:00
Vinit Nayak c91053e9af Move Block 23 flag back into its section
* Seems like with the recent atmospheric river
this feature flag may have slipped out from it's block.

Bug: 278771275
Flag: not needed
Change-Id: I3aa8e70207ea29319b8854ff5d995dc61bc41ef2
2023-04-25 12:17:07 -07:00
Vinit Nayak a85b629d12 Add link to block directory
Flag: not needed
Bug: 278771275
Test: ran launcher
Change-Id: I6fc37d73a73265520c62c95167fd730095dd81e6
2023-04-25 12:17:07 -07:00
Tracy Zhou eb55f83d88 Merge "Support 4-finger gesture to quick switch" into udc-dev 2023-04-25 18:21:37 +00:00
Schneider Victor-tulias fff7cef9f1 Remove unused debug logs
Removing debug logs for bugs that have already been closed. These logs are filling up the logcat buffer and impeding in other test investigations.

Flag: not needed
Test: Tapl tests
Bug: 260260325
Change-Id: I4d69b904f2ea79d758cf6bef7d90d172f2eb2a91
2023-04-25 11:00:37 -07:00
Luca Zuccarini fc04ea4073 [Toast] Enable background drawables by default in Teamfood.
Bug: 262778448
Test: manual
Change-Id: I36e64b846f8d21b8e1f5f4bd898865af2342942f
2023-04-25 13:51:00 +00:00
Jeremy Sim 6e0f34cc0a Merge "App Pairs (behind flag): Add new ItemInfo types and DB save functionality" into udc-dev 2023-04-22 03:21:17 +00:00
Jeremy Sim 7cf0dd9e03 App Pairs (behind flag): Add new ItemInfo types and DB save functionality
This is the second of several patches implementing the App Pairs feature behind a flag.

This patch includes:
- AppPairsController, a new controller that will handle creation, launching, and deletion of app pairs
- ITEM_TYPE_APP_PAIR is a new type of FolderInfo (FolderInfo now can be either a folder or an app pair, and should probably be renamed to CollectionInfo or something more generic in future)
- Necessary plumbing for these new types
- Database code that handles saving a new app pair to the database with the correct schema

Flag: ENABLE_APP_PAIRS (set to false)
Bug: 274189428
Test: Not included in this CL, but will follow
Change-Id: Ie3aefd4eb9171f471789f54876de742849d3013b
2023-04-21 14:23:54 -07:00
Fengjiang Li 5068718fe8 Merge "Check build version before using predicitve back API" into udc-dev 2023-04-21 20:22:09 +00:00
Fengjiang Li 55e648f682 Fix NPE of predictive back in TaskbarAllAppsSlideInView
Fix: 278597104
Test: tested predictive back in taskbar all apps view
Change-Id: I32e3cba5d26b3d05e9b7af584598bf04e512a684
2023-04-21 11:12:40 -07:00
Holly Jiuyu Sun 7c836923b9 Merge "Override INTERPOLATOR_WITHIN_ALL_APPS when app restarts." into udc-dev 2023-04-21 17:13:03 +00:00