Index: media/midi/midi_manager_usb.h |
diff --git a/media/midi/midi_manager_usb.h b/media/midi/midi_manager_usb.h |
index 12e8ed5e790d51a31b5005bf6f4ccaffabeaae25..a4b06a0374377822cfc03a427a52d85e44829d7c 100644 |
--- a/media/midi/midi_manager_usb.h |
+++ b/media/midi/midi_manager_usb.h |
@@ -8,6 +8,7 @@ |
#include <stddef.h> |
#include <stdint.h> |
+#include <memory> |
#include <utility> |
#include <vector> |
@@ -16,7 +17,6 @@ |
#include "base/compiler_specific.h" |
#include "base/containers/hash_tables.h" |
#include "base/macros.h" |
-#include "base/memory/scoped_ptr.h" |
#include "base/time/time.h" |
#include "media/midi/midi_manager.h" |
#include "media/midi/usb_midi_device.h" |
@@ -36,7 +36,8 @@ class USB_MIDI_EXPORT MidiManagerUsb |
public UsbMidiDeviceDelegate, |
NON_EXPORTED_BASE(public UsbMidiInputStream::Delegate) { |
public: |
- explicit MidiManagerUsb(scoped_ptr<UsbMidiDevice::Factory> device_factory); |
+ explicit MidiManagerUsb( |
+ std::unique_ptr<UsbMidiDevice::Factory> device_factory); |
~MidiManagerUsb() override; |
// MidiManager implementation. |
@@ -52,7 +53,7 @@ class USB_MIDI_EXPORT MidiManagerUsb |
const uint8_t* data, |
size_t size, |
base::TimeTicks time) override; |
- void OnDeviceAttached(scoped_ptr<UsbMidiDevice> device) override; |
+ void OnDeviceAttached(std::unique_ptr<UsbMidiDevice> device) override; |
void OnDeviceDetached(size_t index) override; |
// UsbMidiInputStream::Delegate implementation. |
@@ -79,17 +80,17 @@ class USB_MIDI_EXPORT MidiManagerUsb |
void OnEnumerateDevicesDone(bool result, UsbMidiDevice::Devices* devices); |
bool AddPorts(UsbMidiDevice* device, int device_id); |
- scoped_ptr<UsbMidiDevice::Factory> device_factory_; |
+ std::unique_ptr<UsbMidiDevice::Factory> device_factory_; |
ScopedVector<UsbMidiDevice> devices_; |
ScopedVector<UsbMidiOutputStream> output_streams_; |
- scoped_ptr<UsbMidiInputStream> input_stream_; |
+ std::unique_ptr<UsbMidiInputStream> input_stream_; |
base::Callback<void(Result result)> initialize_callback_; |
// A map from <endpoint_number, cable_number> to the index of input jacks. |
base::hash_map<std::pair<int, int>, size_t> input_jack_dictionary_; |
- scoped_ptr<MidiScheduler> scheduler_; |
+ std::unique_ptr<MidiScheduler> scheduler_; |
DISALLOW_COPY_AND_ASSIGN(MidiManagerUsb); |
}; |