| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_RENDERER_PEPPER_PEPPER_MEDIA_DEVICE_MANAGER_H_ | 5 #ifndef CONTENT_RENDERER_PEPPER_PEPPER_MEDIA_DEVICE_MANAGER_H_ |
| 6 #define CONTENT_RENDERER_PEPPER_PEPPER_MEDIA_DEVICE_MANAGER_H_ | 6 #define CONTENT_RENDERER_PEPPER_PEPPER_MEDIA_DEVICE_MANAGER_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 public RenderFrameObserver, | 27 public RenderFrameObserver, |
| 28 public RenderFrameObserverTracker<PepperMediaDeviceManager>, | 28 public RenderFrameObserverTracker<PepperMediaDeviceManager>, |
| 29 public base::SupportsWeakPtr<PepperMediaDeviceManager> { | 29 public base::SupportsWeakPtr<PepperMediaDeviceManager> { |
| 30 public: | 30 public: |
| 31 static base::WeakPtr<PepperMediaDeviceManager> GetForRenderFrame( | 31 static base::WeakPtr<PepperMediaDeviceManager> GetForRenderFrame( |
| 32 RenderFrame* render_frame); | 32 RenderFrame* render_frame); |
| 33 ~PepperMediaDeviceManager() override; | 33 ~PepperMediaDeviceManager() override; |
| 34 | 34 |
| 35 // PepperDeviceEnumerationHostHelper::Delegate implementation: | 35 // PepperDeviceEnumerationHostHelper::Delegate implementation: |
| 36 void EnumerateDevices(PP_DeviceType_Dev type, | 36 void EnumerateDevices(PP_DeviceType_Dev type, |
| 37 const GURL& document_url, | |
| 38 const DevicesCallback& callback) override; | 37 const DevicesCallback& callback) override; |
| 39 uint32_t StartMonitoringDevices(PP_DeviceType_Dev type, | 38 uint32_t StartMonitoringDevices(PP_DeviceType_Dev type, |
| 40 const GURL& document_url, | |
| 41 const DevicesCallback& callback) override; | 39 const DevicesCallback& callback) override; |
| 42 void StopMonitoringDevices(PP_DeviceType_Dev type, | 40 void StopMonitoringDevices(PP_DeviceType_Dev type, |
| 43 uint32_t subscription_id) override; | 41 uint32_t subscription_id) override; |
| 44 | 42 |
| 45 typedef base::Callback<void(int /* request_id */, | 43 typedef base::Callback<void(int /* request_id */, |
| 46 bool /* succeeded */, | 44 bool /* succeeded */, |
| 47 const std::string& /* label */)> | 45 const std::string& /* label */)> |
| 48 OpenDeviceCallback; | 46 OpenDeviceCallback; |
| 49 | 47 |
| 50 // Opens the specified device. The request ID passed into the callback will be | 48 // Opens the specified device. The request ID passed into the callback will be |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 113 OpenCallbackMap open_callbacks_; | 111 OpenCallbackMap open_callbacks_; |
| 114 | 112 |
| 115 ::mojom::MediaDevicesDispatcherHostPtr media_devices_dispatcher_; | 113 ::mojom::MediaDevicesDispatcherHostPtr media_devices_dispatcher_; |
| 116 | 114 |
| 117 DISALLOW_COPY_AND_ASSIGN(PepperMediaDeviceManager); | 115 DISALLOW_COPY_AND_ASSIGN(PepperMediaDeviceManager); |
| 118 }; | 116 }; |
| 119 | 117 |
| 120 } // namespace content | 118 } // namespace content |
| 121 | 119 |
| 122 #endif // CONTENT_RENDERER_PEPPER_PEPPER_MEDIA_DEVICE_MANAGER_H_ | 120 #endif // CONTENT_RENDERER_PEPPER_PEPPER_MEDIA_DEVICE_MANAGER_H_ |
| OLD | NEW |