diff options
| author | Hongwei Wang <hwwang@google.com> | 2019-11-15 15:44:12 -0800 |
|---|---|---|
| committer | Hongwei Wang <hwwang@google.com> | 2020-04-30 08:48:09 -0700 |
| commit | 5711b8fdaf2d99414c8167d142c140c02301c64c (patch) | |
| tree | 2e5263c89c916158ce828c1e07cacdcced851c08 /core/java/android/app/WindowConfiguration.java | |
| parent | 265622e3c79afde612d39e4f74635f741cacf4c1 (diff) | |
Move PIP/MW mode callbacks to be on the client side
We now infer the PIP/MW mode change from the new configuration.
Note also that both
- Activity#isInPictureInPictureMode
- Activity#isInMultiWindowMode
infer the current state from the configuration rather than querying
against the WM.
Also in this CL:
- When in removePinnedStackInSurfaceTransaction, keep the pinned stack
hidden till the windowing mode is set to fullscreen, this is to surpress
the attempt to set the activities to be started in reparenting
- When in ActivityRecord#shouldBeVisible, should take account the force
hidden flag, which is not actually in use before
Bug: 144097203
Bug: 142282126
Bug: 138329093
Test: atest ActivityLifecyclePipTests \
ActivityLifecycleSplitScreenTests \
ActivityLifecycleTopResumedStateTests \
PinnedStackTests \
SplitScreenTests \
ActivityTaskManagerServiceTests \
RecentsAnimationTest \
AssistantStackTests \
StartActivityTests \
ActivityVisibilityTests \
MultiDisplaySecurityTests \
MultiDisplaySystemDecorationTests
Change-Id: Ibe032b5e50ba5c6d6bc44ebb54d07ac974ebe656
Diffstat (limited to 'core/java/android/app/WindowConfiguration.java')
| -rw-r--r-- | core/java/android/app/WindowConfiguration.java | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/core/java/android/app/WindowConfiguration.java b/core/java/android/app/WindowConfiguration.java index 37e07de9809a..a486b9501e0c 100644 --- a/core/java/android/app/WindowConfiguration.java +++ b/core/java/android/app/WindowConfiguration.java @@ -727,6 +727,16 @@ public class WindowConfiguration implements Parcelable, Comparable<WindowConfigu } /** + * Returns {@code true} if the windowingMode represents a window in multi-window mode. + * I.e. sharing the screen with another activity. + * @hide + */ + public static boolean inMultiWindowMode(int windowingMode) { + return windowingMode != WINDOWING_MODE_FULLSCREEN + && windowingMode != WINDOWING_MODE_UNDEFINED; + } + + /** * Returns true if the windowingMode represents a split window. * @hide */ |
