New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 902637 link

Starred by 2 users

Issue metadata

Status: Available
Owner:
Last visit > 30 days ago
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 1
Type: Bug



Sign in to add a comment

Chrome PIP window sometimes loses PIP window state type

Project Member Reported by edcourtney@chromium.org, Nov 7

Issue description

It seems like the Chrome PIP window sometimes loses the PIP window state type.

Repro steps:
1. Navigate to a video and right click to go into PIP mode
2. PIP window with rounded corners + pip window state appears.
3. Close the PIP window
4. Right click again and open
5. PIP window without rounded corners which doesn't have pip window state appears

Expected behaviour:
Opening again should still have PIP window state applied
 
Components: -Internals>Services>Ash UI>Shell
Status: Started (was: Assigned)
I confirmed the WindowStateType::PIP is correctly applied even to second (and later) pip windows. So the cause may be different. Let me investigate further.

Eliot, do you have any idea about the cause.
Ok, I found the cause: window_state.cc:676.
https://cs.chromium.org/chromium/src/ash/wm/window_state.cc?q=window_state&sq=package:chromium&dr=C&l=675

Since the new window's bounds and the old mask's bounds are same, the mask is not applied to the new window.

Let me create a fix.
Thanks. I also noticed that the special PIP window management didn't seem to apply after the second opening. Could you confirm your fix also fixes this?

Thanks a lot~!
Re #4, it looks window snapping is working correctly even with second PIP windows. Let me fix only the mask. Thanks.
Status: Fixed (was: Started)
Status: Available (was: Fixed)
Sorry, I closed this by mistake. The fix is not landed yet.
Project Member

Comment 8 by bugdroid1@chromium.org, Nov 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/648aa9e1cabc52d962fbc76be4d488b4d5af1f6d

commit 648aa9e1cabc52d962fbc76be4d488b4d5af1f6d
Author: yoshiki iguchi <yoshiki@chromium.org>
Date: Wed Nov 21 05:56:00 2018

Apply PIP mask correctly to second (and later) PIP window

Previously the mask was applied only to the first PIP window. This CL
fixes this bug.

Bug: 902637
Test: Tested manually with the steps on the issue
Test: Added test passes

Change-Id: I4f86fa1713a861243ab3c87d051ff491f7b6bd32
Reviewed-on: https://chromium-review.googlesource.com/c/1322188
Reviewed-by: Mitsuru Oshima <oshima@chromium.org>
Commit-Queue: Yoshiki Iguchi <yoshiki@chromium.org>
Cr-Commit-Position: refs/heads/master@{#609924}
[modify] https://crrev.com/648aa9e1cabc52d962fbc76be4d488b4d5af1f6d/ash/wm/window_state.cc
[modify] https://crrev.com/648aa9e1cabc52d962fbc76be4d488b4d5af1f6d/ash/wm/window_state.h
[modify] https://crrev.com/648aa9e1cabc52d962fbc76be4d488b4d5af1f6d/ash/wm/window_state_unittest.cc

Sign in to add a comment