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

Unified Diff: Source/core/html/HTMLMediaSource.h

Issue 363953002: Oilpan: have the media element safely close its MediaSource. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Tidy clearing of m_attachedElement Created 6 years, 6 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/HTMLMediaElement.cpp ('k') | Source/modules/mediasource/MediaSource.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLMediaSource.h
diff --git a/Source/core/html/HTMLMediaSource.h b/Source/core/html/HTMLMediaSource.h
index 14baccb8e498df6f84c8592f6cf0b0da38bbf90b..0c51a73d34d0d6e3f1da9ebd6719a7bea7822b09 100644
--- a/Source/core/html/HTMLMediaSource.h
+++ b/Source/core/html/HTMLMediaSource.h
@@ -32,6 +32,7 @@
#define HTMLMediaSource_h
#include "core/html/URLRegistry.h"
+#include "platform/heap/Handle.h"
#include "wtf/Forward.h"
namespace blink {
@@ -43,13 +44,15 @@ namespace WebCore {
class HTMLMediaElement;
class TimeRanges;
-class HTMLMediaSource : public URLRegistrable {
+class HTMLMediaSource : public URLRegistrable, public WillBeGarbageCollectedMixin {
public:
static void setRegistry(URLRegistry*);
static HTMLMediaSource* lookup(const String& url) { return s_registry ? static_cast<HTMLMediaSource*>(s_registry->lookup(url)) : 0; }
+#if !ENABLE(OILPAN)
void ref() { refHTMLMediaSource(); }
void deref() { derefHTMLMediaSource(); }
+#endif
// Called when an HTMLMediaElement is attempting to attach to this object,
// and helps enforce attachment to at most one element at a time.
@@ -64,8 +67,10 @@ public:
virtual bool isClosed() const = 0;
virtual double duration() const = 0;
virtual PassRefPtr<TimeRanges> buffered() const = 0;
+#if !ENABLE(OILPAN)
virtual void refHTMLMediaSource() = 0;
virtual void derefHTMLMediaSource() = 0;
+#endif
// URLRegistrable
virtual URLRegistry& registry() const OVERRIDE { return *s_registry; }
« no previous file with comments | « Source/core/html/HTMLMediaElement.cpp ('k') | Source/modules/mediasource/MediaSource.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698