summaryrefslogtreecommitdiffstats
path: root/chrome/browser/automation/automation_provider_observers.h
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser/automation/automation_provider_observers.h')
-rw-r--r--chrome/browser/automation/automation_provider_observers.h27
1 files changed, 25 insertions, 2 deletions
diff --git a/chrome/browser/automation/automation_provider_observers.h b/chrome/browser/automation/automation_provider_observers.h
index efb01e0..e6e434e 100644
--- a/chrome/browser/automation/automation_provider_observers.h
+++ b/chrome/browser/automation/automation_provider_observers.h
@@ -488,6 +488,29 @@ class LoginManagerObserver : public NotificationObserver {
};
#endif
+// Waits for the download shelf to appear or disappear
+// (depending on |visibility|).
+class DownloadShelfVisibilityObserver : public NotificationObserver {
+ public:
+ DownloadShelfVisibilityObserver(AutomationProvider* automation,
+ Browser* browser,
+ bool visiblity,
+ IPC::Message* reply_message);
+ ~DownloadShelfVisibilityObserver();
+
+ // NotificationObserver interface.
+ virtual void Observe(NotificationType type, const NotificationSource& source,
+ const NotificationDetails& details);
+
+ private:
+ NotificationRegistrar registrar_;
+ AutomationProvider* automation_;
+ bool visibility_;
+ IPC::Message* reply_message_;
+
+ DISALLOW_COPY_AND_ASSIGN(DownloadShelfVisibilityObserver);
+};
+
// Waits for the bookmark model to load.
class AutomationProviderBookmarkModelObserver : BookmarkModelObserver {
public:
@@ -536,8 +559,8 @@ class AutomationProviderBookmarkModelObserver : BookmarkModelObserver {
// When asked for pending downloads, the DownloadManager places
// results in a DownloadManager::Observer.
-class AutomationProviderDownloadManagerObserver :
- public DownloadManager::Observer {
+class AutomationProviderDownloadManagerObserver
+ : public DownloadManager::Observer {
public:
AutomationProviderDownloadManagerObserver() : DownloadManager::Observer() {}
virtual ~AutomationProviderDownloadManagerObserver() {}