Chromium Code Reviews| Index: Source/core/html/shadow/MediaControls.cpp |
| diff --git a/Source/core/html/shadow/MediaControls.cpp b/Source/core/html/shadow/MediaControls.cpp |
| index f7ebf6b0d182a82285e26a069d288b7a14ec223e..158b5a1662413c23f54f491d6ccbf8d3f7df7e7e 100644 |
| --- a/Source/core/html/shadow/MediaControls.cpp |
| +++ b/Source/core/html/shadow/MediaControls.cpp |
| @@ -58,9 +58,6 @@ MediaControls::MediaControls(Document& document) |
| PassRefPtr<MediaControls> MediaControls::create(Document& document) |
|
eseidel
2014/03/08 20:39:05
One way to test these methods is to do:
<iframe i
|
| { |
| - if (!document.page()) |
| - return nullptr; |
| - |
| RefPtr<MediaControls> controls; |
| #if OS(ANDROID) |
| controls = adoptRef(new MediaControlsAndroid(document)); |
| @@ -167,10 +164,6 @@ void MediaControls::setMediaController(MediaControllerInterface* controller) |
| void MediaControls::reset() |
| { |
| - Page* page = document().page(); |
| - if (!page) |
| - return; |
| - |
| double duration = m_mediaController->duration(); |
| m_durationDisplay->setInnerText(RenderTheme::theme().formatMediaControlsTime(duration), ASSERT_NO_EXCEPTION); |
| m_durationDisplay->setCurrentValue(duration); |
| @@ -264,10 +257,6 @@ void MediaControls::updateCurrentTimeDisplay() |
| double now = m_mediaController->currentTime(); |
| double duration = m_mediaController->duration(); |
| - Page* page = document().page(); |
| - if (!page) |
| - return; |
| - |
| // After seek, hide duration display and show current time. |
| if (now > 0) { |
| m_currentTimeDisplay->show(); |
| @@ -383,10 +372,6 @@ void MediaControls::startHideFullscreenControlsTimer() |
| if (!m_isFullscreen) |
| return; |
| - Page* page = document().page(); |
| - if (!page) |
| - return; |
| - |
| m_hideFullscreenControlsTimer.startOneShot(timeWithoutMouseMovementBeforeHidingFullscreenControls); |
| } |