Index: chrome/browser/intents/device_attached_intent_source.h |
diff --git a/chrome/browser/intents/device_attached_intent_source.h b/chrome/browser/intents/device_attached_intent_source.h |
index f8c914c0b4988e5ae7f8541ec5b9e35e3cf5e05e..99fb7b97d5694a16f8955c4bd26887398710ac37 100644 |
--- a/chrome/browser/intents/device_attached_intent_source.h |
+++ b/chrome/browser/intents/device_attached_intent_source.h |
@@ -5,6 +5,7 @@ |
#ifndef CHROME_BROWSER_INTENTS_DEVICE_ATTACHED_INTENT_SOURCE_H_ |
#define CHROME_BROWSER_INTENTS_DEVICE_ATTACHED_INTENT_SOURCE_H_ |
+#include "base/memory/weak_ptr.h" |
#include "base/system_monitor/system_monitor.h" |
class Browser; |
@@ -21,7 +22,8 @@ class WebContentsDelegate; |
// root_path = the File Path at which the device is accessible |
// filesystem_id = registered isolated file system identifier |
class DeviceAttachedIntentSource |
- : public base::SystemMonitor::DevicesChangedObserver { |
+ : public base::SystemMonitor::DevicesChangedObserver, |
+ public base::SupportsWeakPtr<DeviceAttachedIntentSource> { |
James Hawkins
2012/08/06 16:36:36
Use WeakPtrFactory instead.
kmadhusu
2012/08/06 18:11:52
As per the comments in base/memory/weak_ptr.h,
We
|
public: |
DeviceAttachedIntentSource(Browser* browser, |
content::WebContentsDelegate* delegate); |
@@ -35,6 +37,11 @@ class DeviceAttachedIntentSource |
const FilePath::StringType& location) OVERRIDE; |
virtual void OnMediaDeviceDetached(const std::string& id) OVERRIDE; |
+ // Dispatches web intents for the attached media device specified by |
+ // |device_info|. |
+ void DispatchIntentsForService( |
+ const base::SystemMonitor::MediaDeviceInfo& device_info); |
+ |
private: |
typedef std::map<std::string, base::SystemMonitor::MediaDeviceInfo> |
DeviceIdToInfoMap; |