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

Unified Diff: Source/modules/encryptedmedia/MediaKeys.h

Issue 139173012: Move encryptedmedia module to oilpan (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 10 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
Index: Source/modules/encryptedmedia/MediaKeys.h
diff --git a/Source/modules/encryptedmedia/MediaKeys.h b/Source/modules/encryptedmedia/MediaKeys.h
index 640c24865fadd50b9343aa4ebc2f50c31c2c1e35..5090e6f0d8ede68a565830c28d99412d3f4ae747 100644
--- a/Source/modules/encryptedmedia/MediaKeys.h
+++ b/Source/modules/encryptedmedia/MediaKeys.h
@@ -28,6 +28,7 @@
#include "bindings/v8/ScriptWrappable.h"
#include "core/events/EventTarget.h"
+#include "heap/Handle.h"
#include "modules/encryptedmedia/MediaKeySession.h"
#include "platform/Timer.h"
#include "wtf/Deque.h"
@@ -52,12 +53,13 @@ class ExceptionState;
// The ContentDecryptionModule has the same lifetime as this object.
// Maintains a reference to all MediaKeySessions created to ensure they live as
// long as this object unless explicitly close()'d.
-class MediaKeys : public RefCounted<MediaKeys>, public ScriptWrappable {
+class MediaKeys : public RefCountedWillBeGarbageCollected<MediaKeys>, public ScriptWrappable {
haraken 2014/02/07 05:21:56 I noticed that this should be RefCountedWillBeGarb
+ DECLARE_GC_INFO;
public:
- static PassRefPtr<MediaKeys> create(const String& keySystem, ExceptionState&);
+ static PassRefPtrWillBeRawPtr<MediaKeys> create(const String& keySystem, ExceptionState&);
~MediaKeys();
- PassRefPtr<MediaKeySession> createSession(ExecutionContext*, const String& contentType, Uint8Array* initData, ExceptionState&);
+ PassRefPtrWillBeRawPtr<MediaKeySession> createSession(ExecutionContext*, const String& contentType, Uint8Array* initData, ExceptionState&);
const String& keySystem() const { return m_keySystem; }
@@ -65,6 +67,8 @@ public:
blink::WebContentDecryptionModule* contentDecryptionModule();
+ void trace(Visitor*) { }
+
protected:
MediaKeys(const String& keySystem, PassOwnPtr<ContentDecryptionModule>);
void initializeNewSessionTimerFired(Timer<MediaKeys>*);
@@ -77,11 +81,11 @@ protected:
// FIXME: Check whether |initData| can be changed by JS. Maybe we should not pass it as a pointer.
struct InitializeNewSessionData {
- InitializeNewSessionData(PassRefPtr<MediaKeySession> session, const String& contentType, PassRefPtr<Uint8Array> initData)
+ InitializeNewSessionData(PassRefPtrWillBeRawPtr<MediaKeySession> session, const String& contentType, PassRefPtr<Uint8Array> initData)
: session(session)
, contentType(contentType)
, initData(initData) { }
- RefPtr<MediaKeySession> session;
+ RefPtrWillBePersistent<MediaKeySession> session;
String contentType;
RefPtr<Uint8Array> initData;
};

Powered by Google App Engine
This is Rietveld 408576698