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

Unified Diff: content/browser/media/midi_host.h

Issue 664843002: Web MIDI: distributes MIDIPort information asynchronously (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lifecycle
Patch Set: . => -> Created 6 years, 2 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 | « no previous file | content/browser/media/midi_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/media/midi_host.h
diff --git a/content/browser/media/midi_host.h b/content/browser/media/midi_host.h
index acaee52bb901ea546c7ad9d9dc4e0d4b53106379..3a469bf93b9e2eef4ab6a2656f7e899877e15736 100644
--- a/content/browser/media/midi_host.h
+++ b/content/browser/media/midi_host.h
@@ -37,6 +37,8 @@ class CONTENT_EXPORT MidiHost
// MidiManagerClient implementation.
void CompleteStartSession(media::MidiResult result) override;
+ void AddInputPort(const media::MidiPortInfo& info) override;
+ void AddOutputPort(const media::MidiPortInfo& info) override;
void ReceiveMidiData(uint32 port,
const uint8* data,
size_t length,
@@ -86,6 +88,9 @@ class CONTENT_EXPORT MidiHost
// Buffers where data sent from each MIDI input port is stored.
ScopedVector<media::MidiMessageQueue> received_messages_queues_;
+ // Protects access to |received_messages_queues_|;
+ base::Lock messages_queues_lock_;
+
// The number of bytes sent to the platform-specific MIDI sending
// system, but not yet completed.
size_t sent_bytes_in_flight_;
« no previous file with comments | « no previous file | content/browser/media/midi_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698