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

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

Issue 24070002: Web MIDI: MIDIInput/MIDIOutput should not have reference to MIDIAccess (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: (rebase) 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
« no previous file with comments | « Source/modules/webmidi/MIDIInput.h ('k') | Source/modules/webmidi/MIDIInput.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/webmidi/MIDIInput.cpp
diff --git a/Source/modules/webmidi/MIDIInput.cpp b/Source/modules/webmidi/MIDIInput.cpp
index 1e9e62c80095d7bcfaa742d97850f4bb4e8f32a0..a5fd6ce552c1301056c82b69187648308dad5f14 100644
--- a/Source/modules/webmidi/MIDIInput.cpp
+++ b/Source/modules/webmidi/MIDIInput.cpp
@@ -34,13 +34,15 @@
namespace WebCore {
-PassRefPtr<MIDIInput> MIDIInput::create(ScriptExecutionContext* context, const String& id, const String& manufacturer, const String& name, const String& version)
+PassRefPtr<MIDIInput> MIDIInput::create(MIDIAccess* access, ScriptExecutionContext* context, const String& id, const String& manufacturer, const String& name, const String& version)
{
- return adoptRef(new MIDIInput(context, id, manufacturer, name, version));
+ ASSERT(access);
+ return adoptRef(new MIDIInput(access, context, id, manufacturer, name, version));
}
-MIDIInput::MIDIInput(ScriptExecutionContext* context, const String& id, const String& manufacturer, const String& name, const String& version)
+MIDIInput::MIDIInput(MIDIAccess* access, ScriptExecutionContext* context, const String& id, const String& manufacturer, const String& name, const String& version)
: MIDIPort(context, id, manufacturer, name, MIDIPortTypeInput, version)
+ , m_access(access)
{
ScriptWrappable::init(this);
}
« no previous file with comments | « Source/modules/webmidi/MIDIInput.h ('k') | Source/modules/webmidi/MIDIInput.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698