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

Unified Diff: chrome/browser/ui/webui/sessions_ui.cc

Issue 9169096: Remove a bunch of GetProfileSyncService callers to use the new factory. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rm todos Created 8 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
« no previous file with comments | « chrome/browser/ui/webui/options2/stop_syncing_handler2.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/sessions_ui.cc
diff --git a/chrome/browser/ui/webui/sessions_ui.cc b/chrome/browser/ui/webui/sessions_ui.cc
index bfaddf73cf6e1aad8ce60c8615e3cc15d152fb9b..c4b2661765a1264923743315872cbde60941cc38 100644
--- a/chrome/browser/ui/webui/sessions_ui.cc
+++ b/chrome/browser/ui/webui/sessions_ui.cc
@@ -13,6 +13,7 @@
#include "chrome/browser/sync/glue/session_model_associator.h"
#include "chrome/browser/sync/glue/synced_session.h"
#include "chrome/browser/sync/profile_sync_service.h"
+#include "chrome/browser/sync/profile_sync_service_factory.h"
#include "chrome/browser/ui/webui/chrome_url_data_manager.h"
#include "chrome/browser/ui/webui/chrome_web_ui_data_source.h"
#include "chrome/browser/ui/webui/ntp/new_tab_ui.h"
@@ -127,7 +128,8 @@ browser_sync::SessionModelAssociator* SessionsDOMHandler::GetModelAssociator() {
Profile* profile = Profile::FromWebUI(web_ui());
if (!profile->HasProfileSyncService())
return NULL;
- ProfileSyncService* service = profile->GetProfileSyncService();
+ ProfileSyncService* service(ProfileSyncServiceFactory::
+ GetInstance()->GetForProfile(profile));
if (!service->ShouldPushChanges())
return NULL;
return service->GetSessionModelAssociator();
« no previous file with comments | « chrome/browser/ui/webui/options2/stop_syncing_handler2.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698