Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(836)

Unified Diff: Source/core/html/shadow/MediaControlElements.cpp

Issue 219283004: Remove what remains of MediaControllerInterface (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: earliest possible position FIXME Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/html/shadow/MediaControlElements.h ('k') | Source/core/html/shadow/MediaControls.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/shadow/MediaControlElements.cpp
diff --git a/Source/core/html/shadow/MediaControlElements.cpp b/Source/core/html/shadow/MediaControlElements.cpp
index 8b98f277ebbe9f043138cde129d9657648837bdf..a6160fe088cae309d0b5ed36b46a924ade9e6480 100644
--- a/Source/core/html/shadow/MediaControlElements.cpp
+++ b/Source/core/html/shadow/MediaControlElements.cpp
@@ -38,6 +38,7 @@
#include "core/events/MouseEvent.h"
#include "core/frame/LocalFrame.h"
#include "core/html/HTMLVideoElement.h"
+#include "core/html/MediaController.h"
#include "core/html/shadow/MediaControls.h"
#include "core/html/track/TextTrack.h"
#include "core/html/track/vtt/VTTRegionList.h"
@@ -372,8 +373,12 @@ void MediaControlTimelineElement::defaultEventHandler(Event* event)
return;
double time = value().toDouble();
- if (event->type() == EventTypeNames::input && time != mediaControllerInterface().currentTime())
- mediaControllerInterface().setCurrentTime(time, IGNORE_EXCEPTION);
+ if (event->type() == EventTypeNames::input) {
+ if (mediaElement().controller())
+ mediaElement().controller()->setCurrentTime(time, IGNORE_EXCEPTION);
+ else
+ mediaElement().setCurrentTime(time, IGNORE_EXCEPTION);
+ }
RenderSlider* slider = toRenderSlider(renderer());
if (slider && slider->inDragMode())
« no previous file with comments | « Source/core/html/shadow/MediaControlElements.h ('k') | Source/core/html/shadow/MediaControls.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698