diff options
Diffstat (limited to 'chrome/browser/google_url_tracker.cc')
-rw-r--r-- | chrome/browser/google_url_tracker.cc | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/chrome/browser/google_url_tracker.cc b/chrome/browser/google_url_tracker.cc index 2e26147..8b60ae4 100644 --- a/chrome/browser/google_url_tracker.cc +++ b/chrome/browser/google_url_tracker.cc @@ -25,9 +25,8 @@ GoogleURLTracker::GoogleURLTracker() already_fetched_(false), need_to_fetch_(false), request_context_available_(!!Profile::GetDefaultRequestContext()) { - NotificationService::current()->AddObserver(this, - NotificationType::DEFAULT_REQUEST_CONTEXT_AVAILABLE, - NotificationService::AllSources()); + registrar_.Add(this, NotificationType::DEFAULT_REQUEST_CONTEXT_AVAILABLE, + NotificationService::AllSources()); // Because this function can be called during startup, when kicking off a URL // fetch can eat up 20 ms of time, we delay five seconds, which is hopefully @@ -42,9 +41,6 @@ GoogleURLTracker::GoogleURLTracker() } GoogleURLTracker::~GoogleURLTracker() { - NotificationService::current()->RemoveObserver(this, - NotificationType::DEFAULT_REQUEST_CONTEXT_AVAILABLE, - NotificationService::AllSources()); } // static |