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

Unified Diff: Source/modules/webmidi/MIDIInput.h

Issue 23648006: Web MIDI: tentative sysex check for receiving messages (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 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/webmidi/MIDIInput.h
diff --git a/Source/modules/webmidi/MIDIInput.h b/Source/modules/webmidi/MIDIInput.h
index 4c560d5b3cedd929ec1d0798e7d85e23a5bf6c15..d37f643fc53f007841c13a826b78db5f51f0a264 100644
--- a/Source/modules/webmidi/MIDIInput.h
+++ b/Source/modules/webmidi/MIDIInput.h
@@ -33,15 +33,17 @@
#include "core/dom/EventTarget.h"
#include "modules/webmidi/MIDIPort.h"
+#include "wtf/RefPtr.h"
namespace WebCore {
+class MIDIAccess;
class ScriptExecutionContext;
class MIDIInput : public MIDIPort {
public:
- static PassRefPtr<MIDIInput> create(ScriptExecutionContext*, const String& id, const String& manufacturer, const String& name, const String& version);
- virtual ~MIDIInput() { }
+ static PassRefPtr<MIDIInput> create(MIDIAccess*, ScriptExecutionContext*, const String& id, const String& manufacturer, const String& name, const String& version);
+ virtual ~MIDIInput();
DEFINE_ATTRIBUTE_EVENT_LISTENER(midimessage);
@@ -52,7 +54,9 @@ public:
void didReceiveMIDIData(unsigned portIndex, const unsigned char* data, size_t length, double timeStamp);
private:
- MIDIInput(ScriptExecutionContext*, const String& id, const String& manufacturer, const String& name, const String& version);
+ MIDIInput(MIDIAccess*, ScriptExecutionContext*, const String& id, const String& manufacturer, const String& name, const String& version);
+
+ RefPtr<MIDIAccess> m_access;
};
typedef Vector<RefPtr<MIDIInput> > MIDIInputVector;

Powered by Google App Engine
This is Rietveld 408576698