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

Unified Diff: chrome/browser/chromeos/contacts/google_contact_store.cc

Issue 11620007: Switch from OnIPAddressChanged and OnConnectionTypeChange to OnNetworkChanged Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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/contacts/google_contact_store.cc
diff --git a/chrome/browser/chromeos/contacts/google_contact_store.cc b/chrome/browser/chromeos/contacts/google_contact_store.cc
index 43b6a71ab694cd62f5aed12afb77a6a048cab815..8ed590379b537385fa2fb3786f3d995cda3a8cb4 100644
--- a/chrome/browser/chromeos/contacts/google_contact_store.cc
+++ b/chrome/browser/chromeos/contacts/google_contact_store.cc
@@ -80,7 +80,7 @@ void GoogleContactStore::TestAPI::NotifyAboutNetworkStateChange(bool online) {
online ?
net::NetworkChangeNotifier::CONNECTION_UNKNOWN :
net::NetworkChangeNotifier::CONNECTION_NONE;
- store_->OnConnectionTypeChanged(type);
+ store_->OnNetworkChanged(type);
}
scoped_ptr<ContactPointers> GoogleContactStore::TestAPI::GetLoadedContacts() {
@@ -104,14 +104,14 @@ GoogleContactStore::GoogleContactStore(
should_update_when_online_(false),
ALLOW_THIS_IN_INITIALIZER_LIST(weak_ptr_factory_(this)) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
- net::NetworkChangeNotifier::AddConnectionTypeObserver(this);
+ net::NetworkChangeNotifier::AddNetworkChangeObserver(this);
is_online_ = !net::NetworkChangeNotifier::IsOffline();
}
GoogleContactStore::~GoogleContactStore() {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
weak_ptr_factory_.InvalidateWeakPtrs();
- net::NetworkChangeNotifier::RemoveConnectionTypeObserver(this);
+ net::NetworkChangeNotifier::RemoveNetworkChangeObserver(this);
DestroyDatabase();
}
@@ -161,7 +161,7 @@ void GoogleContactStore::RemoveObserver(ContactStoreObserver* observer) {
observers_.RemoveObserver(observer);
}
-void GoogleContactStore::OnConnectionTypeChanged(
+void GoogleContactStore::OnNetworkChanged(
net::NetworkChangeNotifier::ConnectionType type) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
bool was_online = is_online_;

Powered by Google App Engine
This is Rietveld 408576698