Chromium Code Reviews| Index: third_party/WebKit/Source/core/layout/LayoutMedia.cpp |
| diff --git a/third_party/WebKit/Source/core/layout/LayoutMedia.cpp b/third_party/WebKit/Source/core/layout/LayoutMedia.cpp |
| index ae50013ff9ecb3b817429f21eccb38bf6018c019..59f699bdabe82f41bbcb9f7e49e3f4b5448fc72c 100644 |
| --- a/third_party/WebKit/Source/core/layout/LayoutMedia.cpp |
| +++ b/third_party/WebKit/Source/core/layout/LayoutMedia.cpp |
| @@ -54,8 +54,6 @@ void LayoutMedia::layout() { |
| LayoutState state(*this); |
| - Optional<LayoutUnit> newPanelWidth; |
| - |
| // Iterate the children in reverse order so that the media controls are laid |
| // out before the text track container. This is to ensure that the text |
| // track rendering has an up-to-date position of the media controls for |
| @@ -83,7 +81,6 @@ void LayoutMedia::layout() { |
| LayoutUnit width = newRect.width(); |
| if (child->node()->isMediaControls()) { |
| width = computePanelWidth(newRect); |
| - newPanelWidth = width; |
|
mlamouri (slow - plz ping)
2017/03/07 19:07:30
Here, we set `width` then pass it to `newPanelWidt
mlamouri (slow - plz ping)
2017/03/08 19:13:04
Scratch that comment :)
steimel
2017/03/09 16:42:24
Acknowledged.
|
| } |
| LayoutBox* layoutBox = toLayoutBox(child); |
| @@ -97,18 +94,6 @@ void LayoutMedia::layout() { |
| } |
| clearNeedsLayout(); |
| - |
| - // Notify our MediaControls that a layout has happened. |
| - if (mediaElement() && mediaElement()->mediaControls() && |
| - newPanelWidth.has_value()) { |
| - if (!m_lastReportedPanelWidth.has_value() || |
| - m_lastReportedPanelWidth.value() != newPanelWidth.value()) { |
| - mediaElement()->mediaControls()->notifyPanelWidthChanged( |
| - newPanelWidth.value()); |
| - // Store the last value we reported, so we know if it has changed. |
| - m_lastReportedPanelWidth = newPanelWidth.value(); |
| - } |
| - } |
| } |
| bool LayoutMedia::isChildAllowed(LayoutObject* child, |