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

Unified Diff: chrome/browser/service_process/service_process_control.h

Issue 2925973002: Migrate upgrade notifications to observer (Closed)
Patch Set: Fix test failure Created 3 years, 6 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
Index: chrome/browser/service_process/service_process_control.h
diff --git a/chrome/browser/service_process/service_process_control.h b/chrome/browser/service_process/service_process_control.h
index 80210d0a64945793fb7200634191d5324074001e..b254c5876ac45e57e7a02b732670e10c358c59f9 100644
--- a/chrome/browser/service_process/service_process_control.h
+++ b/chrome/browser/service_process/service_process_control.h
@@ -20,8 +20,7 @@
#include "base/memory/weak_ptr.h"
#include "base/process/process.h"
#include "build/build_config.h"
-#include "content/public/browser/notification_observer.h"
-#include "content/public/browser/notification_registrar.h"
+#include "chrome/browser/upgrade_observer.h"
#include "ipc/ipc_channel_proxy.h"
#include "ipc/ipc_listener.h"
#include "ipc/ipc_sender.h"
@@ -52,7 +51,7 @@ class PeerConnection;
// talks to the IPC channel on the IO thread.
class ServiceProcessControl : public IPC::Sender,
public IPC::Listener,
- public content::NotificationObserver {
+ public UpgradeObserver {
public:
enum ServiceProcessEvent {
SERVICE_EVENT_INITIALIZE,
@@ -114,10 +113,8 @@ class ServiceProcessControl : public IPC::Sender,
// IPC::Sender implementation
bool Send(IPC::Message* message) override;
- // content::NotificationObserver implementation.
- void Observe(int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) override;
+ // UpgradeObserver implementation.
+ void OnUpgradeRecommended() override;
// Send a shutdown message to the service process. IPC channel will be
// destroyed after calling this method.
@@ -241,8 +238,6 @@ class ServiceProcessControl : public IPC::Sender,
// the service process.
base::Closure histograms_callback_;
- content::NotificationRegistrar registrar_;
-
// Callback that gets invoked if service didn't reply in time.
base::CancelableClosure histograms_timeout_callback_;

Powered by Google App Engine
This is Rietveld 408576698