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

Unified Diff: chrome/browser/extensions/api/history/history_api.h

Issue 773103004: Remove NOTIFICATION_HISTORY_URLS_DELETED (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove NotificationObserver from InMemoryURLIndex Created 6 years 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
Index: chrome/browser/extensions/api/history/history_api.h
diff --git a/chrome/browser/extensions/api/history/history_api.h b/chrome/browser/extensions/api/history/history_api.h
index ccae66fb0c4872e09b8ec589a9a1449b930a8223..b53bdba05dc1df9ea3a6a36aab282c811d0d8ccb 100644
--- a/chrome/browser/extensions/api/history/history_api.h
+++ b/chrome/browser/extensions/api/history/history_api.h
@@ -16,7 +16,6 @@
#include "chrome/browser/history/history_service.h"
#include "chrome/common/extensions/api/history.h"
#include "components/history/core/browser/history_service_observer.h"
-#include "content/public/browser/notification_registrar.h"
#include "extensions/browser/browser_context_keyed_api_factory.h"
#include "extensions/browser/event_router.h"
@@ -28,24 +27,21 @@ namespace extensions {
// Observes History service and routes the notifications as events to the
// extension system.
-class HistoryEventRouter : public content::NotificationObserver,
- public history::HistoryServiceObserver {
+class HistoryEventRouter : public history::HistoryServiceObserver {
public:
HistoryEventRouter(Profile* profile, HistoryService* history_service);
~HistoryEventRouter() override;
private:
- // content::NotificationObserver::Observe.
- void Observe(int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) override;
-
// history::HistoryServiceObserver.
void OnURLVisited(HistoryService* history_service,
ui::PageTransition transition,
const history::URLRow& row,
const history::RedirectList& redirects,
base::Time visit_time) override;
+ void OnURLsDeleted(
+ HistoryService* history_service,
+ const history::URLsDeletedDetails& deleted_details) override;
void HistoryUrlsRemoved(Profile* profile,
const history::URLsDeletedDetails* details);
@@ -54,8 +50,6 @@ class HistoryEventRouter : public content::NotificationObserver,
const std::string& event_name,
scoped_ptr<base::ListValue> event_args);
- // Used for tracking registrations to history service notifications.
- content::NotificationRegistrar registrar_;
Profile* profile_;
ScopedObserver<HistoryService, HistoryServiceObserver>
history_service_observer_;

Powered by Google App Engine
This is Rietveld 408576698