Commit Graph

3510 Commits

Author SHA1 Message Date
Tony Huang
4d8ce499cb Merge "Avoid NPE while drag divider bar" into sc-v2-dev am: fcfa227cf7 am: 1343931512
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16602936

Change-Id: I4345e35c7a7b2b8a56cff04e9c7dc337d55beb00
2022-01-12 01:58:39 +00:00
Tony Huang
1343931512 Merge "Avoid NPE while drag divider bar" into sc-v2-dev am: fcfa227cf7
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16602936

Change-Id: I3fe73e84b92c87ec6f009bc7b671d529a857820f
2022-01-12 01:41:24 +00:00
Tony Huang
fcfa227cf7 Merge "Avoid NPE while drag divider bar" into sc-v2-dev 2022-01-12 01:21:28 +00:00
Mady Mellor
f4d2b4d416 Merge "Fix possible NPE" into sc-v2-dev am: d76f9c199c am: 04b46aed49
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16603090

Change-Id: I28c9bf16b1754aabd5c0ee423a610d44d8923863
2022-01-11 18:51:00 +00:00
Mady Mellor
04b46aed49 Merge "Fix possible NPE" into sc-v2-dev am: d76f9c199c
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16603090

Change-Id: I50140f087019333fc4ca5b3668cddc20a2ead3b9
2022-01-11 17:53:27 +00:00
Mady Mellor
d76f9c199c Merge "Fix possible NPE" into sc-v2-dev 2022-01-11 17:36:43 +00:00
Tony Huang
f0d69e7d47 Avoid NPE while drag divider bar
Task topActivityInfo is nullable, we should check it is null or
not before access it.

Bug: 213894166
Test: pass existing tests
Change-Id: Iedda57145586b6d5c2e151308ddca1e2e36035c0
2022-01-11 14:58:17 +08:00
Winson Chung
398d740004 Merge "Ensure only single pip dismiss magnetized target exists" into sc-v2-dev am: f92999a5e1 am: 049cf6bb1e
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16602749

Change-Id: I017f40d8b236de6e75afce5b28e8a4049396239f
2022-01-11 06:49:09 +00:00
Winson Chung
049cf6bb1e Merge "Ensure only single pip dismiss magnetized target exists" into sc-v2-dev am: f92999a5e1
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16602749

Change-Id: Ibe881d27475564731817bd7b868118e6333d9614
2022-01-11 06:21:52 +00:00
Winson Chung
f92999a5e1 Merge "Ensure only single pip dismiss magnetized target exists" into sc-v2-dev 2022-01-11 06:08:29 +00:00
Chris Li
b258c0fd58 Merge "Fix ExitPipWithDismissButtonTest with Shell transition" 2022-01-11 02:30:08 +00:00
Chris Li
9131c6a128 Merge "Fix WallpaperWindowToken visible update with Shell transition" 2022-01-11 02:29:29 +00:00
Winson Chung
b5e0878776 Ensure only single pip dismiss magnetized target exists
- If init() is called multiple times, the previous magnetized targets
  can cause the wrong target position to be calculated when trying (or
  not trying) to dismiss

Bug: 213348722
Test: Manual
Change-Id: Ic1f972cc60eafca2302ad168065c974c8a0ee924
2022-01-11 00:22:42 +00:00
Mady Mellor
0be1b45d64 Fix possible NPE
Test: manual - make sure dot works normally / no regression
Bug: 213027822
Change-Id: I819f73cb8c7d613796c3d3bb4b55b80b337c6126
2022-01-10 21:07:31 +00:00
Ats Jenk
5bf2bc35a8 Merge "Use a separate icon factory for app badge icons" 2022-01-10 19:55:51 +00:00
Bill Yi
7b3ea9bc04 Merge "Import translations. DO NOT MERGE ANYWHERE" 2022-01-10 04:00:15 +00:00
Bill Yi
042719f4df Merge "Import translations. DO NOT MERGE ANYWHERE" 2022-01-10 03:59:18 +00:00
Chris Li
2490b439d0 Fix ExitPipWithDismissButtonTest with Shell transition
Fix: 210965692
Test: atest WMShellFlickerTests:ExitPipWithDismissButtonTest
Change-Id: I828095f55e7400b661513b853372a3bef5466663
2022-01-09 22:59:36 +08:00
Chris Li
c8a3d88def Fix WallpaperWindowToken visible update with Shell transition
With Shell transition, when mVisibleRequested is changed, it will wait
until the transition finish to update the isVisible(). As a result, if
there is a visible change before the previous transition is finished,
it will be skipped.

For example, when we first open a fullscreen app and then immediately
enter pip:
1. TRANSIT_OPEN will call to hide wallpaper and set mVisibleRequest to
false, but not commit visible until transition animation is finished.
2. TRANSIT_PIP will call to show wallpaper, but if it is started before
the OPEN transition is finsihed, it will not update the wallpaper
mVisibleRequested, which will leave the wallpaper hidden.

Fix: 210965575
Bug: 210965692
Test: atest WMShellFlickerTests:ExpandPipOnDoubleClickTest
Change-Id: I2578aafd024a3c9a6ec96079d4dc6cb740c890d2
2022-01-09 19:35:16 +08:00
TreeHugger Robot
581ad142f9 Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-v2-dev 2022-01-09 05:21:03 +00:00
TreeHugger Robot
34171e053d Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-v2-dev 2022-01-09 05:20:12 +00:00
Bill Yi
9f612755b6 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: Ifab08e6f5047b918b9d9eb318085f9e281b7fb4a
2022-01-08 05:06:10 +00:00
Bill Yi
fbe8128ea1 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: Ie9444c2d04adc95f33300624391b888094c38422
2022-01-08 05:02:23 +00:00
Bill Yi
301d5c5963 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I97d5ca669c13fda5f3c25b97f42ee359953fe172
2022-01-08 05:00:53 +00:00
Bill Yi
664ed31d10 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I17b0b00359d964dce6474934b5b0bc97a117025d
2022-01-08 04:57:14 +00:00
Sergey Serokurov
9ea6fc5541 Merge "Make only top bubble clickable when stack is collapsed" 2022-01-07 23:25:26 +00:00
Sergey Serokurov
79623ef98d Make only top bubble clickable when stack is collapsed
Bug: 157934340
Test: atest SystemUITests
Test: manual, screen recording https://drive.google.com/file/d/12itDLsVQZrCQVYMjgJhuWlTslOJdyGqy/view?usp=sharing
Change-Id: I865a8d508965e88e78e516143915fd895d4f3782
2022-01-07 12:29:27 -08:00
Ats Jenk
71d2ccffc7 Use a separate icon factory for app badge icons
We were reusing the same BubbleIconFactory for bubble icons and app
badge icons. BubbleIconFactory extends BaseIconFactory and resizes all
created icons to one size. BubbleIconFactory was configured to resize
icons to the size of bubbles as defined by bubble_size dimensions,
currently at 60dp.
Badge icon size is defined by bubble_badge_size and is currently at
24dp. Using the same BubbleIconFactory for both icons meant that we were
resizing all badge icons to be the same size as bubbles, at first. And
then, when actually using them, sizing them down again.
This change introduces a separate BubbleBadgeIconFactory with relevant
code moved from BubbleIconFactory. And mainly, it defines the icon size
as the size of the badge. Avoiding resizing.

Test: visually verified that the badge icon looks the same
Bug: 189173831
Change-Id: Ie032bbc15eb0fd3e78636796bafb05149e262850
2022-01-07 10:44:17 -08:00
TreeHugger Robot
f7714c7271 Merge "Set cutout mode to shortEdges on flicker" 2022-01-07 18:25:19 +00:00
Nataniel Borges
dd1d5b61b1 Set cutout mode to shortEdges on flicker
Use short edges on the flicker tests so that the test apps cover the full screen in both raven and in flame devices. With default cutout, some assertions will need to be updated to consider the letterbox layers, as well as app windows not covering the entire display

Bug: 209935473
Test: atest FlickerTests WMShellFlickerTests
Change-Id: Iaeabe2033adc2890605bbef7bce139569f402c4b
2022-01-07 16:22:46 +01:00
Chris Li
ceabc8c201 Merge "Enter PIP when exiting prev PIP with Shell transition" 2022-01-07 13:46:22 +00:00
Mariia Sandrikova
d2ccf6edac Merge "[5/n] Camera Compat UI: Unify margins logic for camera and size compat controls." into sc-v2-dev am: b6c52ec273 am: 0cb2c45802
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16527687

Change-Id: I0cf5f6fa171d2cd9f402cd1439c3418631718cc9
2022-01-07 11:23:05 +00:00
Mariia Sandrikova
0cb2c45802 Merge "[5/n] Camera Compat UI: Unify margins logic for camera and size compat controls." into sc-v2-dev am: b6c52ec273
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16527687

Change-Id: Ib282c2fc1fd01d26841ee2003cd604d4150e569f
2022-01-07 11:02:56 +00:00
Mariia Sandrikova
b6c52ec273 Merge "[5/n] Camera Compat UI: Unify margins logic for camera and size compat controls." into sc-v2-dev 2022-01-07 10:49:20 +00:00
Chris Li
5f59127cb3 Enter PIP when exiting prev PIP with Shell transition
Before, the dismissPip() is not collected in the enter PIP transition.
Now, the Task that leaving PIP windowing mode will also be part of the
TRANSIT_PIP transition.

Fix: 213300721
Test: manual test with two Pip apps
Change-Id: Iaab34a7969ff4cb5d9768754d643d5f32913f57a
2022-01-07 18:38:28 +08:00
Riddle Hsu
320dfd646e Fix layer order of wallpaper with counter-rotator in default handler
The layer of wallpaper should always be at the bottom. Otherwise other
windows below it will be invisible during a transition animation.

Also put the same usages of CounterRotator to a new helper class.

Bug: 206094140
Test: adb shell setprop persist.debug.shell_transit 1; reboot
      atest com.android.server.wm.flicker.launch.OpenAppWarmTest
      Or use shell command "am start" to launch a landscape
      activity while wallpaper is visible in portrait.

Change-Id: Ia78450af45185782ce2268393e2a8b6bb8b4c794
2022-01-07 02:24:57 +00:00
Chris Li
6ecdc3894b Merge "Fix SetRequestedOrientationWhilePinnedTest with Shell transition" 2022-01-07 02:06:10 +00:00
Bill Lin
88f11a9f48 Merge "2/ Instrument jank of One-handed mode trigger and exit transition" 2022-01-07 01:14:30 +00:00
Sergey Serokurov
62d314414f Merge "Adjust dismiss view position when one handed mode is switched on/off" 2022-01-06 23:55:27 +00:00
TreeHugger Robot
787445d9ba Merge "Include app badge without markings in bubble data" 2022-01-06 21:26:26 +00:00
Sergey Serokurov
aebd901c8f Adjust dismiss view position when one handed mode is switched on/off
Bug: 198403767
Test: atest SystemUITests
Test: Manual, screen recording: https://drive.google.com/file/d/1CvoTt_BlKFHQI0H15QJ8M-M7zJMq3hfU/view?usp=sharing

Change-Id: I3d757909f4e01fcde11f3377caa83e7cf3a73b5b
2022-01-06 08:29:55 -08:00
Chris Li
85e4cc2e6e Fix SetRequestedOrientationWhilePinnedTest with Shell transition
Fix: 210965919
Test: atest WMShellFlickerTests:SetRequestedOrientationWhilePinnedTest
Change-Id: Ib59300e1d3af8fbcc02a5a85964a1d2ffdaaaf4f
2022-01-06 19:53:06 +08:00
Chris Li
f413c13078 Handle enter PIP during a display rotation transition
When entering PIP while there is an ongoing collecting transition, the
PipTransition won't set the PIP window to the correct state.

Bug: 210965919
Test: atest WMShellFlickerTests:SetRequestedOrientationWhilePinnedTest
Change-Id: I3a68dc16886f239434e2b5ff220f83a6079140ee
2022-01-06 19:43:10 +08:00
Ats Jenk
4311ec42bf Include app badge without markings in bubble data
Sometimes we need to show the app badge without any markings for
priority conversations. For example in case of the manage menu.
As we include the priority ring in the app badge icon itself, add
another app badge icon to bubble data that does not include the priority
ring - raw app badge.

Change-Id: Ib472519d9bec5cdd09d7559e4dad2ee5e5f71b50
Test: verified that priority conversation bubble has ring around app
badge and no ring in manage menu
Bug: 189173831

Change-Id: I276e110ece40bf394f58da9acc3d0ecd09cf5afc
2022-01-05 18:41:14 -08:00
Chris Li
bf60dcab43 Implement PIP to fullscreen in different orientation animation
Rotate and expand the PIP window for Shell transition.
Use CounterRotator to show the windows behind in their previous
orientation.

Bug: 210965919
Test: test a pip fix-orientation app with Shell transition
Change-Id: I5de7751a47a06ad2b73137e1e85ca756983c9612
2022-01-06 00:22:43 +08:00
Chris Li
d380769503 Set windowing mode when exit PIP to fullscreen
Before, we only setActivityWindowingMode when exit PIP. It won't
request display rotation nor update the visibility of other activities
behind, which will result the EXIT_PIP transition won't actually rotate
the display, and will follow by another CHANGE transition for the
rotation.

Bug: 210965919
Test: pass existing
Change-Id: I402449fddc1ddcd4c876489b5fb96a2a599baa1d
2022-01-06 00:13:31 +08:00
Bill Lin
40fa9bf6fb 2/ Instrument jank of One-handed mode trigger and exit transition
Add 2 CUJs for one handed mode transition
1. ONE_HANDED_ENTER_TRANSITION
2. ONE_HANDED_EXIT_TRANSITION

- [STATE_ENTERING] Detect swipe down gesture: Begin of enter CUJ
- [STATE_ENTERING] Tap shortcut to trigger: Begin of enter CUJ
- [STATE_ACTIVE] Transition end of enter: End of enter CUJ
- [STATE_EXITING] Detect swipe up gesture: Begin of exit CUJ
- [STATE_EXITING] Tap shortcut to exit: Begin of exit CUJ
- [STATE_NONE] Transition end of exit: End of exit CUJ

Test: see trace in comment
Bug: 201032904
Change-Id: I29258a1bbbe567c935d467621a85fbdfe2397d54
2022-01-05 13:31:02 +08:00
Tony Huang
c015533563 Merge "Fix updateRecentTasksSplitPair unexpectly" into sc-v2-dev am: 588771a9de
Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/16564588

Change-Id: Iee0b86019c26a215834b0d34b9778083c38f3dec
2022-01-05 04:13:13 +00:00
Tony Huang
588771a9de Merge "Fix updateRecentTasksSplitPair unexpectly" into sc-v2-dev 2022-01-05 03:58:53 +00:00
Chris Li
1d35d293f3 Merge "Draw PipContentOverlay when enter PIP with Shell transition" 2022-01-05 03:38:35 +00:00