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

Unified Diff: Source/modules/mediarecorder/BlobEvent.h

Issue 1354863002: MediaRecorder: Adding BlobEvent and connecting it in MediaRecorderHandler (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: MediaRecorder: BlobEvent Created 5 years, 3 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/mediarecorder/BlobEvent.h
diff --git a/Source/modules/mediarecorder/BlobEvent.h b/Source/modules/mediarecorder/BlobEvent.h
new file mode 100644
index 0000000000000000000000000000000000000000..72e78acb8eb8ebab45ca00286e54a4a655efae2a
--- /dev/null
+++ b/Source/modules/mediarecorder/BlobEvent.h
@@ -0,0 +1,41 @@
+// Copyright 2015 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef BlobEvent_h
+#define BlobEvent_h
+
+#include "core/fileapi/Blob.h"
+#include "modules/EventModules.h"
+#include "modules/ModulesExport.h"
+#include "wtf/text/AtomicString.h"
+
+namespace blink {
+
+class Blob;
+
+class MODULES_EXPORT BlobEvent final : public Event {
+ DEFINE_WRAPPERTYPEINFO();
+public:
+ virtual ~BlobEvent() {}
Peter Beverloo 2015/09/18 13:07:26 ~BlobEvent() override {} (The base class already
mcasas 2015/09/21 15:24:15 Done.
+
+ static PassRefPtrWillBeRawPtr<BlobEvent> create();
+ static PassRefPtrWillBeRawPtr<BlobEvent> create(const AtomicString& type, bool canBubble, bool cancelable, Blob*);
Peter Beverloo 2015/09/18 13:07:26 nit: You could consider inlining the bodies of the
mcasas 2015/09/21 15:24:15 Yeah, I'd love to, but in previous CLs I was instr
Peter Beverloo 2015/09/22 14:03:42 OK. I disagree, but don't feel strongly either so
+
+ Blob* data() const { return m_blob.get(); }
+
+ // Event
+ const AtomicString& interfaceName() const final;
+
+ DECLARE_VIRTUAL_TRACE();
+
+private:
+ BlobEvent() {}
+ BlobEvent(const AtomicString& type, bool canBubble, bool cancelable, Blob*);
+
+ PersistentWillBeMember<Blob> m_blob;
+};
+
+} // namespace blink
+
+#endif // BlobEvent_h

Powered by Google App Engine
This is Rietveld 408576698