OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef MEDIA_MIDI_MIDI_MANAGER_ALSA_H_ | 5 #ifndef MEDIA_MIDI_MIDI_MANAGER_ALSA_H_ |
6 #define MEDIA_MIDI_MIDI_MANAGER_ALSA_H_ | 6 #define MEDIA_MIDI_MIDI_MANAGER_ALSA_H_ |
7 | 7 |
8 #include <alsa/asoundlib.h> | 8 #include <alsa/asoundlib.h> |
9 #include <map> | 9 #include <map> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/basictypes.h" | 12 #include "base/basictypes.h" |
13 #include "base/gtest_prod_util.h" | 13 #include "base/gtest_prod_util.h" |
14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
15 #include "base/memory/scoped_vector.h" | 15 #include "base/memory/scoped_vector.h" |
16 #include "base/stl_util.h" | 16 #include "base/stl_util.h" |
17 #include "base/synchronization/lock.h" | 17 #include "base/synchronization/lock.h" |
18 #include "base/threading/thread.h" | 18 #include "base/threading/thread.h" |
19 #include "base/values.h" | 19 #include "base/values.h" |
20 #include "device/udev_linux/scoped_udev.h" | 20 #include "device/udev_linux/scoped_udev.h" |
21 #include "media/midi/midi_export.h" | 21 #include "media/midi/midi_export.h" |
22 #include "media/midi/midi_manager.h" | 22 #include "media/midi/midi_manager.h" |
23 | 23 |
24 namespace media { | 24 namespace media { |
| 25 namespace midi { |
25 | 26 |
26 class MIDI_EXPORT MidiManagerAlsa final : public MidiManager { | 27 class MIDI_EXPORT MidiManagerAlsa final : public MidiManager { |
27 public: | 28 public: |
28 MidiManagerAlsa(); | 29 MidiManagerAlsa(); |
29 ~MidiManagerAlsa() override; | 30 ~MidiManagerAlsa() override; |
30 | 31 |
31 // MidiManager implementation. | 32 // MidiManager implementation. |
32 void StartInitialization() override; | 33 void StartInitialization() override; |
33 void DispatchSendMidiData(MidiManagerClient* client, | 34 void DispatchSendMidiData(MidiManagerClient* client, |
34 uint32 port_index, | 35 uint32 port_index, |
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
319 | 320 |
320 base::Thread send_thread_; | 321 base::Thread send_thread_; |
321 base::Thread event_thread_; | 322 base::Thread event_thread_; |
322 | 323 |
323 bool event_thread_shutdown_; // guarded by shutdown_lock_ | 324 bool event_thread_shutdown_; // guarded by shutdown_lock_ |
324 base::Lock shutdown_lock_; // guards event_thread_shutdown_ | 325 base::Lock shutdown_lock_; // guards event_thread_shutdown_ |
325 | 326 |
326 DISALLOW_COPY_AND_ASSIGN(MidiManagerAlsa); | 327 DISALLOW_COPY_AND_ASSIGN(MidiManagerAlsa); |
327 }; | 328 }; |
328 | 329 |
| 330 } // namespace midi |
329 } // namespace media | 331 } // namespace media |
330 | 332 |
331 #endif // MEDIA_MIDI_MIDI_MANAGER_ALSA_H_ | 333 #endif // MEDIA_MIDI_MIDI_MANAGER_ALSA_H_ |
OLD | NEW |