The increase to the gradient height doesn't work well for phone
landscape since it can be larger. This meant the calculation to
place the dismiss target window is incorrect.
This change fixes it by capping the height to the window size.
Test: visual - have PIP in landscape on phone and verify drag to
dismiss target is fully visible
Bug: 223467425
Change-Id: I78a5565c8e09f010fad46ccd96c137f1c4de93b0
controllers.
Test: m -j.
Test: Open and swipe back on pre-T and T apps.
Test: atest BackNavigationControllerTests
Test: atest BackAnimationControllerTest
Bug: 195946584
Change-Id: I981f8deff9fad75355ee0e8bbe08b375f4da6e74
This reverts commit ad89a82145.
Reason for revert: b/222170518 was unrelated to gesture back, and is now fixed.
Test: m -j. Test back behavior throughout system.
Change-Id: Ia27c7ea97416831355e1949ec6874de570b52108
We would like to make relayoutWindow a non-blocking call,
and of course why not, who likes blocking. However it functions
as a critical path of BLASTSync. To understand why examine the
Guarantee described in BLASTSync.md.
In order to implement this guarantee we need to know
“Which frame has the client finished drawing” when it calls
finishDrawing. The current answer to this question is
“The frame reflecting the state observed in the last call
to relayoutWindow”. The comments on mPending and mCurrentDrawHandlers
also have a lot more context on how this works currently. Since
relayoutWindow has a critical section, it also ensures that changes
to syncable state and preparation of sync will be observed atomically
(since they are both observed over relayoutWindow, which is always
called before any frame drawing updated syncable state).
We design a new protocol described in BLASTSync.md, which uses a seqId
to track which call to finishDrawing reflects which syncable state.
We implement this seqId based system. Unfortunately the WindowManager
doesn’t quite conform to the requirements specified by the protocol,
and a follow up CL ensures that syncable state changes will
always be sent with the seqId.
This CL simply adds the protocol specification and makes some required
interface changes. It can be seen to be a no-op.
Bug: 161810301
Bug: 175861051
Bug: 175861127
Bug: 200285149
Change-Id: If2dea07121fe7de5d2524c5b63678dddf955d4b7
When rotation, it will re-init the split divider for new rotation on
DAinfoChanged callback, but when shell transition, we should do it on
startAnimation to make transition smooth and make didider could release
by specfic Transcation to avoid it hide immediately but didn't sync with
transition.
Fix: 222158856
Test: manual
Test: pass existing tests
Change-Id: I797ffd0ea35d89b4ec1e3ef4828ce36e18c860be
I noticed when opening settings while stack is expanded wouldn't
cause the stack to collapse. This was because we skipped the collapse
if the shade was expanded. I don't think there's any reason to be
doing this, I think this was accidentally added during the refactor
to move bubbles into shell.
Test: manual - have bubbles expanded, pull down the shade, tap on
the settings gear or long press on a tile, ensure that
when the settings screen opens that the stack collapsed
Bug: 223635739
Change-Id: Ia3476e694a8e64c95eed63dea4a3729e83766683
- Legacy style was overriding the Shell landscape style for the
divider
Bug: 213379024
Test: Build sysui from studio and verify the divider background
is correct
Change-Id: Ic47b411fad0469c86459cc01189a722dbad8d8c3
Take system bars and display cutout insets into account when calculating
smallestWidthDp for splitting tasks.
Bug: 217600744
Test: atest WMShellUnitTests
Change-Id: Ifa56c51d90418d9771d95bd64be69b2c084e446f
Support to switch the split position of the splitting app which is not
supporting multi-instance when dragging its app icon to another side of
the split.
Bug: 199386272
Test: manual check repro steps of app not supporting multi-instance
Change-Id: Ib7c50ff29dd9ea72e33162bed55eb52c8e4fc31b
Some function call in finishEnterSplitScreen should be non-null so
passing transcation to it instaed of null.
Fix: 223396097
Test: manual
Test: pass existing tests
Change-Id: I0c3e2ab3d04191eabf749bda0f5bb0c11c09723a
The PiP is placed in a way to avoid keep clear areas.
If no areas overlapping the default PiP anchor position are defined,
the PiP will stay at its anchor position.
Otherwise, it will try to move to a free location closest to its anchor
position. Unrestricted areas can cause the PiP to move across the entire
screen, but restricted areas have limited influence and can only move
the PiP a short distance.
If no free position is found, the PiP will be stashed for some time.
To find the position to move to once the PiP unstashes, a relaxed search
is performed, excluding a restricted keep clear area. If this still does
not yield a position to move to, only unrestricted areas will be taken
into account. The PiP is stashed along the edge closest to the unstash
position.
Bug: 218416347
Bug: 218494300
Test: atest TvPipKeepClearAlgorithmTest
Change-Id: I76c6527320fc403bb604b188f38eed505eeaab89
GKS requested that app's bounds should not overlap with the nav bar area
when kids mode is enabled except for Launcher.
Creates a dedicate task organizer for kids mode. When kids mode is
enabled, create a root task with its bounds excluding the nav bar area
and tasks except launcher will be launched into it.
Bug: 161689887
Test: manual:
1. adb shell settings put secure "nav_bar_force_visible" "1"
2. choose 3-buttons navigation mode in
Settings>System>Gestures>System navigation
3. check winscope and see if bounds are set correctly
Test: atest KidsModeTaskOrganizerTest
Test: atest WindowOrganizerTests
Change-Id: I93af1bc5b2696654d8ca5055dbbbebf5a41f89aa
When the Task contains multiple activities, entering/exiting PIP will
move the PIP activity in/out of a new PIP Task.
Bug: 222410428
Test: verify with test app that contains multiple activities
Change-Id: Icdb27b24b5dcf332c84ac01dd368e4f16f19889e
Now that BadgedImageView is a viewgroup overriding onDraw doesn't
work, instead we can override dispatchDraw.
Fixes: 213595915
Test: visual - add a bubble and see that there is a dot
Change-Id: I5f417f95922a070f5290b7291b6e7748a69840d8