Commit 1f3779f9 authored by Sidney San Martín's avatar Sidney San Martín Committed by Commit Bot

Fix the PiP window jumping around on Mac.

The PiP window has a simple layer tree and triggers the FSLP code path.
But, this path didn't previously consider the video layer part of the
area that needs a backdrop, so the backdrop layer (the root layer) was
made too small.

It would be better if this code just had access to the size of the page
instead of having to guess by looking at the layer tree, but I don't
think it does right now.

Bug: 863580
Change-Id: Ib2e9ae24e98932b77b365a985dc956aa08287eb7
Reviewed-on: https://chromium-review.googlesource.com/1140923Reviewed-by: default avatarccameron <ccameron@chromium.org>
Commit-Queue: Sidney San Martín <sdy@chromium.org>
Cr-Commit-Position: refs/heads/master@{#576182}
parent 3754df62
...@@ -250,6 +250,7 @@ bool CARendererLayerTree::RootLayer::WantsFullcreenLowPowerBackdrop( ...@@ -250,6 +250,7 @@ bool CARendererLayerTree::RootLayer::WantsFullcreenLowPowerBackdrop(
// See if this is the video layer. // See if this is the video layer.
if (content_layer.use_av_layer) { if (content_layer.use_av_layer) {
background_rect->Union(gfx::RectF(content_layer.rect));
found_video_layer = true; found_video_layer = true;
if (!transform_layer.transform.IsPositiveScaleOrTranslation()) if (!transform_layer.transform.IsPositiveScaleOrTranslation())
return false; return false;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment