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

Side by Side Diff: chrome/browser/ui/ash/app_sync_ui_state.cc

Issue 2657673004: Add shutdown notification and service refs to SyncServiceObserver. (Closed)
Patch Set: Chromeos fix Created 3 years, 10 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/ash/app_sync_ui_state.h" 5 #include "chrome/browser/ui/ash/app_sync_ui_state.h"
6 6
7 #include "build/build_config.h" 7 #include "build/build_config.h"
8 #include "chrome/browser/extensions/extension_service.h" 8 #include "chrome/browser/extensions/extension_service.h"
9 #include "chrome/browser/extensions/pending_extension_manager.h" 9 #include "chrome/browser/extensions/pending_extension_manager.h"
10 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 if (synced && !has_pending_extension) 125 if (synced && !has_pending_extension)
126 SetStatus(STATUS_NORMAL); 126 SetStatus(STATUS_NORMAL);
127 else 127 else
128 SetStatus(STATUS_SYNCING); 128 SetStatus(STATUS_SYNCING);
129 } 129 }
130 130
131 void AppSyncUIState::OnMaxSyncingTimer() { 131 void AppSyncUIState::OnMaxSyncingTimer() {
132 SetStatus(STATUS_TIMED_OUT); 132 SetStatus(STATUS_TIMED_OUT);
133 } 133 }
134 134
135 void AppSyncUIState::OnStateChanged() { 135 void AppSyncUIState::OnStateChanged(syncer::SyncService* sync) {
136 DCHECK(sync_service_); 136 DCHECK(sync_service_);
137 CheckAppSync(); 137 CheckAppSync();
138 } 138 }
139 139
140 void AppSyncUIState::OnExtensionLoaded(content::BrowserContext* browser_context, 140 void AppSyncUIState::OnExtensionLoaded(content::BrowserContext* browser_context,
141 const extensions::Extension* extension) { 141 const extensions::Extension* extension) {
142 CheckAppSync(); 142 CheckAppSync();
143 } 143 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/ash/app_sync_ui_state.h ('k') | chrome/browser/ui/sync/one_click_signin_sync_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698