diff options
| author | 2023-05-10 23:49:28 +0000 | |
|---|---|---|
| committer | 2023-05-10 23:49:28 +0000 | |
| commit | ca1c9e40e0fb2bcfe040d2d20bb6b63c30e07373 (patch) | |
| tree | 44201d69172aa51820be9a454a88121ec29e1920 | |
| parent | a086f03b246d1de0b777f314a61145117553c51f (diff) | |
| parent | 3e428597423552cd806a9658c763ed3f7ffcbc2c (diff) | |
Merge "Report folding features to letterboxed apps." into udc-dev
| -rw-r--r-- | libs/WindowManager/Jetpack/src/androidx/window/extensions/layout/WindowLayoutComponentImpl.java | 11 |
1 files changed, 1 insertions, 10 deletions
diff --git a/libs/WindowManager/Jetpack/src/androidx/window/extensions/layout/WindowLayoutComponentImpl.java b/libs/WindowManager/Jetpack/src/androidx/window/extensions/layout/WindowLayoutComponentImpl.java index a7a6b3c92157..a45a8a183ac8 100644 --- a/libs/WindowManager/Jetpack/src/androidx/window/extensions/layout/WindowLayoutComponentImpl.java +++ b/libs/WindowManager/Jetpack/src/androidx/window/extensions/layout/WindowLayoutComponentImpl.java @@ -371,24 +371,15 @@ public class WindowLayoutComponentImpl implements WindowLayoutComponent { final Rect taskBounds = taskConfig.windowConfiguration.getBounds(); final WindowManager windowManager = Objects.requireNonNull( context.getSystemService(WindowManager.class)); - final Rect currentBounds = windowManager.getCurrentWindowMetrics().getBounds(); final Rect maxBounds = windowManager.getMaximumWindowMetrics().getBounds(); boolean isTaskExpanded = maxBounds.equals(taskBounds); - boolean isActivityExpanded = maxBounds.equals(currentBounds); /* * We need to proxy being in full screen because when a user enters PiP and exits PiP * the task windowingMode will report multi-window/pinned until the transition is * finished in WM Shell. * maxBounds == taskWindowBounds is a proxy check to verify the window is full screen - * For tasks that are letterboxed, we use currentBounds == maxBounds to filter these - * out. */ - // TODO(b/262900133) remove currentBounds check when letterboxed apps report bounds. - // currently we don't want to report to letterboxed apps since they do not update the - // window bounds when the Activity is moved. An inaccurate fold will be reported so - // we skip. - return isTaskExpanded && (isActivityExpanded - || mTaskFragmentOrganizer.isActivityEmbedded(activityToken)); + return isTaskExpanded; } else { // TODO(b/242674941): use task windowing mode for window context that associates with // activity. |