Commit Graph

990 Commits

Author SHA1 Message Date
TreeHugger Robot
0540a18e26 Merge "Add permission check for TvPipNotification" into sc-dev 2021-04-19 16:55:21 +00:00
Wei Sheng Shih
9dea87c0d1 Merge "Starting window performance tuning for binder block." into sc-dev 2021-04-19 01:33:24 +00:00
Bill Yi
9234f7086d Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: If4d473b60d373922663727fc2bca6bf73ac9cff7
2021-04-17 18:04:51 -07:00
Jason Chang
7833cf0af4 Merge "Fix screen will flicker when swipe-down around NavigationBar to trigger One-Handed mode many times quickly in a short time" into sc-dev 2021-04-17 10:23:09 +00:00
Jason Chang
3a77d720e9 Fix screen will flicker when swipe-down around NavigationBar to
trigger One-Handed mode many times quickly in a short time

To prevent entering or exiting OHM quilcky in a shot time.

Bug: 185304468
Test: manual
Test: atest WMShellUnitTests
Change-Id: Ibc5ade564da241d5871b3b037c97bd68a6b03a5d
2021-04-17 01:50:18 +08:00
TreeHugger Robot
db9210da53 Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev 2021-04-16 17:06:51 +00:00
TreeHugger Robot
7c21c82dcb Merge "Import translations. DO NOT MERGE ANYWHERE" into sc-dev 2021-04-16 16:27:54 +00:00
Jason Chang
fbe969c925 Merge "Fix metrics didn't log ONE_HANDED_TRIGGER_GESTURE_OUT logs when NavigationBar type is Gesture Navi" into sc-dev 2021-04-16 14:26:03 +00:00
Bill Yi
278e113140 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: I2d14138a84252d40e8d297f6e88a94c7be25f7da
2021-04-16 12:28:00 +00:00
Bill Yi
d3588352d6 Import translations. DO NOT MERGE ANYWHERE
Auto-generated-cl: translation import
Change-Id: Ic6c358da64628996d3ca72f3837ba1cf2345f9e8
2021-04-16 12:09:21 +00:00
Jason Chang
6cb7c9515f Fix metrics didn't log ONE_HANDED_TRIGGER_GESTURE_OUT logs when
NavigationBar type is Gesture Navi

Write metrics gesture out event in stopOneHanded() callback.

Bug: 178445384

Test: manual
Test: Westworld metrics logger
Change-Id: Ifd358d2aeda1a518f184216674a304511e251100
Merged-In: Ifd358d2aeda1a518f184216674a304511e251100
(cherry picked from commit 688e89c65d)
2021-04-16 19:38:15 +08:00
TreeHugger Robot
502c75489d Merge "Remove quicksearchbox from home window list" into sc-dev 2021-04-16 10:22:35 +00:00
wilsonshih
6298f2c046 Starting window performance tuning for binder block.
- Pass TaskSnapshot to Shell directly.
- Parallel process: create a splash screen worker thread to create the
splash screen view and pre-draw the icon drawable, and use splash
screen thread to do stuff about window's lifecycle like add/remove
window. We don't use shell main thread here so the starting window
won't blocking any task execute on main thread.
- Trigger addStartingWindow directly when startActivity, also
removeStartingWindow directly without post the animation thread.
- Do not defer addStartingWindow for prepare surface, on the contrast
it should be execute before prepare surface.
- Remove ActivityRecordTests#testAddRemoveRace, it wasn't been test as
expected because in original logic the add and remove starting window
are post to animation thread, so the test was actually testing on
handler#postAtFrontOfQueue and handler#removeCallbacks.
For now it will only cause OutOfMemoryError.

Bug: 183665220
Bug: 182836977
Test: atest StartingSurfaceDrawerTests SplashscreenTests
Change-Id: Ie9a529c7d81f07f923394eb69944518f3e9010ce
2021-04-16 11:04:38 +08:00
Jason Chang
97bf5c62e1 Merge "Fix One Handed Feedback gesture's animations are quite jarring" into sc-dev 2021-04-16 00:29:30 +00:00
Nataniel Borges
f226bc0878 Remove quicksearchbox from home window list
Previously Winscope considered only the `isVisible` property to determine if the window was visible or not. This failed in cases such as `com.google.android.googlequicksearchbox/android.app.ContextImpl` when launching apps, where `isVisible=true` and `alpha=0`

Bug: 181630910
Bug: 182720234
Test: atest FlickerTests WMShellFlickerTests
Change-Id: I75fab0c6de02e43265002986901353f8e230baa5
2021-04-15 17:50:34 +02:00
Orion Hodson
56b6ff07c3 Merge "Revert "Change PlaybackState#isActiveState to isActive"" into sc-dev 2021-04-15 15:07:24 +00:00
Winson Chung
e5bb44a832 Merge "Fix issue with callback not being made on the sysui main thread" into sc-dev 2021-04-14 19:44:42 +00:00
Jorge Gil
ebc500ced4 Merge "Fix race when rotating the display during an entry into PIP" into sc-dev 2021-04-14 15:42:21 +00:00
Sahana Rao
d077dbf438 Revert "Change PlaybackState#isActiveState to isActive"
Revert "Change PlaybackState#isActiveState to isActive"

Revert submission 14124578-playbackstate_isactive

Reason for revert: b/185343312
Reverted Changes:
I4757038d6:Change PlaybackState#isActiveState to isActive
If7753e8e9:Change PlaybackState#isActiveState to isActive

Change-Id: I7c890c65ecb955860d31db6c926ad2d6ded514dc
2021-04-14 12:14:49 +00:00
Nataniel Borges
6788d2b5d6 Merge changes from topics "3button-runner", "re-enable-flicker" into sc-dev
* changes:
  Disable some trace assertions
  Fix use of NavigationModeRule on flicker
2021-04-14 08:35:07 +00:00
Jason Chang
dcecfcf76f Fix One Handed Feedback gesture's animations are quite jarring
To provide a new Interpolator formula for One-Handed transition
animation.

Bug: 178355565
Test: manual
Test: atest WMShellUnitTests
Change-Id: I78d998569618dc52c8b6fce6cb4a71f13ad01ba8
2021-04-14 14:50:44 +08:00
Kyunglyul Hyun
90e33e72cb Merge "Change PlaybackState#isActiveState to isActive" into sc-dev 2021-04-14 03:18:06 +00:00
Ben Lin
724e13196b Merge "PiP: Add rounded corners to the menu." into sc-dev 2021-04-13 23:30:40 +00:00
Nataniel Borges
c258d7f4ca Disable some trace assertions
Previously some assertions didn't run on the whole trace because of a missing `forAllEntries` statement in the library. When activating this statement these tests fail and should be disabled.

Test: atest FlickerTests WMShellFlickerTests
Bug: 183547024
Bug: 181630910
Change-Id: I28f92e2d9de1a5465a4da5971c438bc4c0b311f9
2021-04-13 20:55:39 +02:00
Pedro Loureiro
d34f536b59 Add lint baseline to address NewApi errors
We are enabling a new lint check where the min sdk != compile sdk.
It has produced a lot of errors and adding the baseline file(s)
allows us to continue work without introducing more problems.

Bug: 150847901

Test: m lint-check
Change-Id: Ide8a8fe80ba31396f23853ab266afcbcc33af9a6
2021-04-13 10:51:51 +01:00
Riddle Hsu
a77a0600cf Merge "Remove obsolete test APIs of split screen" into sc-dev 2021-04-13 02:20:37 +00:00
Ben Lin
7366a4b1b9 PiP: Add rounded corners to the menu.
Bug: 184972396
Test: Manual. Enter PiP, see rounded corners on the menu when showing
the menu.

Change-Id: I4af6a48ecb07fce8b96acd775ab6538d9f6cb198
2021-04-12 17:07:34 -07:00
jorgegil@google.com
bf5d97ba93 Fix race when rotating the display during an entry into PIP
Rotating the display while the PIP task had just appeared caused
a race between the alpha entry animation starting and the rotation
controller handling that changes the PIP bounds, resulting in
a bounds mismatch between the surface that was animated and the
PipBoundsState.mBounds

This CL tracks whether we're still waiting for the alpha entry
animation to start when a rotation callback comes in, and
restarts the fade in after adjusting to the rotation.

Bug: 184664409
Test: In gesure nav, open YT go to fullscreen landscape mode and
launch another an activity from a notification - verify PIP fades
in and its bounds match the ones in PipBoundsState

Change-Id: I339d5088fb5f23f08fe8d548b9d02a34c16779d6
2021-04-12 14:20:03 -07:00
Evan Rosky
a2170c2b71 Merge "Add shell transition handling for staged split-screen." into sc-dev 2021-04-12 16:57:55 +00:00
Mady Mellor
02b75bb425 Merge "API Update: extra_is_bubbled -> Activity#isLaunchedFromBubble" into sc-dev 2021-04-12 14:53:01 +00:00
Nataniel Borges
e852b071ff Fix use of NavigationModeRule on flicker
The method was ignored before and now should be activated to enable 3 button mode. Some tests become flaky in 3-button mode and should be disabled for the moment.

Test: atest FlickerTests WMShellFlickerTests
Bug: 162925924
Change-Id: Ife24ad85c302da6fc193f1a5a226722cfed51b2b
2021-04-12 15:15:56 +02:00
Riddle Hsu
f6da995b05 Remove obsolete test APIs of split screen
The methods setTaskWindowingMode and resizePrimarySplitScreen
can be replaced with the methods of WindowContainerTransaction
and TaskOrganizer.

Bug: 174040691
Test: CtsWindowManagerDeviceTestCases

Change-Id: I975457887a87464456675010c7531738fa5f62f4
2021-04-12 17:47:37 +08:00
Tony Huang
5ebb9672f2 Merge "Add callback of TaskStackChangeListener" into sc-dev 2021-04-12 09:29:32 +00:00
Winson Chung
35264cb754 Fix issue with callback not being made on the sysui main thread
Bug: 182705044
Test: atest SystemUITests
Change-Id: I83457f75a35e22f6e06c94e18b807ab88f59dd09
2021-04-09 13:44:24 -07:00
Evan Rosky
2bc5bd5168 Add shell transition handling for staged split-screen.
This makes StageCoordinator implement the TransitionHandler
interface.

In general, this currently expects 'enter' transitions to
contain 2 tasks (one in each split). The current UX is undefined
when one only one of the splits is occupied, so for now it will
throw an exception if that case is hit.

There is a split-screen API called startTasks which takes a list
of tasks (currently only supports 2) and associated options and
creates a transition to both enter split-screen and launch those
tasks into their respective stages.

These are the currently accounted-for entrypoints into
the handler interface:

- Core-initiated (handleRequest)
  - in split: trigger=HOME that is opening -> full dismiss.
  - in split: trigger=task with a stage parent that is last closing in
                    that stage -> dismiss with other stage onTop
  - NOT split: trigger=task with stage parent -> exception
- Shell-initiated
  - NOT split: startTasks -> enter split with 2 tasks
  - in split: snap-to-dismiss -> dismiss with other stage on top

Bug: 182002789
Test: atest SplitTransitionTests
      Or use the experimental pair-launch split-screen and observe
      protologs to see clean transition-infos.
Change-Id: I4f4dd431ad5642cf98b4a01c32eb1d09e5b9a11e
2021-04-09 13:13:56 -07:00
Mady Mellor
3c0890601d Merge "API feedback: setSuppressableBubble/setSuppressBubble" into sc-dev 2021-04-09 17:49:12 +00:00
Robin Lee
3ebb323fe4 Add permission check for TvPipNotification
Bug: 174493596
Change-Id: I110a8db90557eaf72fd4a6c3fe18c1b179bb27fd
2021-04-09 06:58:47 +00:00
Kyunglyul Hyun
4879480b99 Change PlaybackState#isActiveState to isActive
Rename PlaybackState#isActiveState() to #isActive()
and make it public.
This is according to API review.

This CL also includes STATE_SKIPPING_TO_QUEUE_ITEM
as an active playback state.

Bug: 184612506
Test: build successful && atest PlaybackStateTest

Change-Id: I4757038d63adc3478f19f177265ebd198fb5f424
2021-04-09 05:48:31 +00:00
Winson Chung
4cfadfd806 Merge "Fix issue with lagging pip movement after entering/exiting dismiss" into sc-dev 2021-04-09 03:08:41 +00:00
Jason Chang
c16a826d85 Merge "Fix Talk back announces "Exit one handed mode" on every orientation change though one-handed mode is off" into sc-dev 2021-04-08 23:46:39 +00:00
Mady Mellor
4da856e1ef API feedback: setSuppressableBubble/setSuppressBubble
Apps can't actually suppress the bubble, that is only
done by the system so that method is @hide.

Did a similar thing for setSuppressNotification for
consistency.

Test: atest NotificationManagerTest (see CTS CL)
Bug: 184204395
Change-Id: Ia17453507daf5bba4408bd6b386efa225c3051dd
2021-04-08 19:26:14 +00:00
Jason Chang
327e463a30 Fix Talk back announces "Exit one handed mode" on every orientation
change though one-handed mode is off

Add more condition check when Talk back announce one-handed mode
related.

Bug: 182475904
Test: manual
Test: atest WMShellUnitTests
Change-Id: I0644146eaa6d7d6701af94fe6caceee5e6c3be8b
2021-04-08 12:19:58 +08:00
Winson Chung
43278ad135 Fix issue with lagging pip movement after entering/exiting dismiss
- Increase the spring stiffness to catch up to the finger sooner
- In certain cases, moving into and out of the dismiss area quickly
  will start the physics animator multiple times which can trigger
  the update callback multiple times per frame, so only update if
  the bounds have changed

Bug: 183756396
Test: Drag into and out of the
Change-Id: I85a94948ef23b9dc1d569ab3706af899e0d67ef1
2021-04-07 18:48:25 +00:00
Hongwei Wang
10488ee5ea Merge "Update PiP action even if menu is not visible" into sc-dev 2021-04-07 16:56:09 +00:00
Hongwei Wang
b9450d9ef9 Update PiP action even if menu is not visible
Deprecate also the query on WM for pip bounds in PhonePipMenuController

Video: http://recall/-/aaaaaabFQoRHlzixHdtY/n6eylZkmVGfJwp0nl42un
Bug: 172587320
Test: Play in spotify when PiP is in playing state, see video
Test: atest WMShellFlickerTests:com.android.wm.shell.flicker.pip
Change-Id: Ieca6b3e136d5fff6818474ef012ea6b415515fb4
2021-04-06 22:59:40 -07:00
Winson Chung
a740a2e46b Merge "Fix noisy pip logs" into sc-dev 2021-04-07 02:49:59 +00:00
Tony Huang
3a205500ca Add callback of TaskStackChangeListener
It was missed while migrating to wm-shell, add it back and follow
new thread arch.

Fix: 182688580
Test: Open link from Bubbles
Change-Id: I6c205a376e964ab1aaafaedea6508597ee667e23
2021-04-07 09:17:43 +08:00
Wei Sheng Shih
64aa8161e0 Merge "Use a blank splash screen for new task activity" into sc-dev 2021-04-07 00:47:54 +00:00
Wei Sheng Shih
5719f05cf1 Merge "Refine splash screen APIs" into sc-dev 2021-04-07 00:42:09 +00:00
Winson Chung
f81a67fa5e Fix noisy pip logs
- Whenever the shelf height changes, we still call into movement bounds
  changed which triggers menu resize even if not in pip

Bug: 183756396
Test: Open/close all apps, ensure no pip logs when not in pip
Change-Id: Ia27be382316f44bb161a0f3beecd6859813d0a66
2021-04-06 17:57:39 +00:00