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

Unified Diff: chrome/browser/chromeos/drive/drive_sync_client.h

Issue 11345008: Remove content::NotificationObserver dependency from most Prefs code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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/chromeos/drive/drive_sync_client.h
diff --git a/chrome/browser/chromeos/drive/drive_sync_client.h b/chrome/browser/chromeos/drive/drive_sync_client.h
index f0694e184b92622039323932aa6940e0352d0546..410b50e4b0836f4ae4ee41c0325fa9d39c705340 100644
--- a/chrome/browser/chromeos/drive/drive_sync_client.h
+++ b/chrome/browser/chromeos/drive/drive_sync_client.h
@@ -11,12 +11,12 @@
#include "base/callback_forward.h"
#include "base/memory/weak_ptr.h"
+#include "base/prefs/public/pref_observer.h"
#include "base/time.h"
#include "chrome/browser/chromeos/drive/drive_cache.h"
#include "chrome/browser/chromeos/drive/drive_cache_observer.h"
#include "chrome/browser/chromeos/drive/drive_file_system_observer.h"
#include "chrome/browser/chromeos/drive/drive_resource_metadata.h"
-#include "content/public/browser/notification_observer.h"
#include "net/base/network_change_notifier.h"
class Profile;
@@ -45,7 +45,7 @@ class DriveSyncClientObserver;
class DriveSyncClient
: public DriveFileSystemObserver,
public DriveCacheObserver,
- public content::NotificationObserver,
+ public PrefObserver,
public net::NetworkChangeNotifier::ConnectionTypeObserver {
public:
// Types of sync tasks.
@@ -178,10 +178,9 @@ class DriveSyncClient
void OnUploadFileComplete(const std::string& resource_id,
DriveFileError error);
- // content::NotificationObserver override.
- virtual void Observe(int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) OVERRIDE;
+ // PrefObserver override.
+ virtual void OnPreferenceChanged(PrefServiceBase* service,
+ const std::string& pref_name) OVERRIDE;
// net::NetworkChangeNotifier::ConnectionTypeObserver override.
virtual void OnConnectionTypeChanged(

Powered by Google App Engine
This is Rietveld 408576698