Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5423)

Unified Diff: chrome/browser/google/google_url_tracker_map_entry.h

Issue 290453005: Remove Infobars notifications from GoogleURLTrackerMapEntry (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Review comments Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/google/google_url_tracker.cc ('k') | chrome/browser/google/google_url_tracker_map_entry.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/google/google_url_tracker_map_entry.h
diff --git a/chrome/browser/google/google_url_tracker_map_entry.h b/chrome/browser/google/google_url_tracker_map_entry.h
index 1acd274341bb8a3bad78753308d019c495b51c48..5cdb2b5fc6ef1d961a8e727f116a2d563738f3d8 100644
--- a/chrome/browser/google/google_url_tracker_map_entry.h
+++ b/chrome/browser/google/google_url_tracker_map_entry.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Copyright 2012 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -8,8 +8,7 @@
#include "base/memory/scoped_ptr.h"
#include "chrome/browser/google/google_url_tracker_infobar_delegate.h"
#include "chrome/browser/google/google_url_tracker_navigation_helper.h"
-#include "content/public/browser/notification_observer.h"
-#include "content/public/browser/notification_registrar.h"
+#include "components/infobars/core/infobar_manager.h"
class GoogleURLTracker;
@@ -17,7 +16,7 @@ namespace infobars {
class InfoBarManager;
}
-class GoogleURLTrackerMapEntry : public content::NotificationObserver {
+class GoogleURLTrackerMapEntry : public infobars::InfoBarManager::Observer {
public:
GoogleURLTrackerMapEntry(
GoogleURLTracker* google_url_tracker,
@@ -38,21 +37,26 @@ class GoogleURLTrackerMapEntry : public content::NotificationObserver {
infobar_delegate_->navigation_helper() : navigation_helper_.get();
}
+ const infobars::InfoBarManager* infobar_manager() const {
+ return infobar_manager_;
+ }
+
void Close(bool redo_search);
private:
friend class GoogleURLTrackerTest;
- // content::NotificationObserver:
- virtual void Observe(int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) OVERRIDE;
+ // infobars::InfoBarManager::Observer:
+ virtual void OnInfoBarRemoved(infobars::InfoBar* infobar,
+ bool animate) OVERRIDE;
+ virtual void OnManagerShuttingDown(
+ infobars::InfoBarManager* manager) OVERRIDE;
- content::NotificationRegistrar registrar_;
GoogleURLTracker* const google_url_tracker_;
- const infobars::InfoBarManager* const infobar_manager_;
+ infobars::InfoBarManager* const infobar_manager_;
GoogleURLTrackerInfoBarDelegate* infobar_delegate_;
scoped_ptr<GoogleURLTrackerNavigationHelper> navigation_helper_;
+ bool observing_;
DISALLOW_COPY_AND_ASSIGN(GoogleURLTrackerMapEntry);
};
« no previous file with comments | « chrome/browser/google/google_url_tracker.cc ('k') | chrome/browser/google/google_url_tracker_map_entry.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698