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

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

Issue 2517243002: [Sync] Removing complexity around PROXY_TABS now that empty sessions are provided when disabled. (Closed)
Patch Set: Rebase and re-vulcanize after conflict. Created 4 years 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/ui/webui/foreign_session_handler.cc
diff --git a/chrome/browser/ui/webui/foreign_session_handler.cc b/chrome/browser/ui/webui/foreign_session_handler.cc
index 62f33c2f54b525147f23e662554d8926dd7d2da1..df6d2570780cc5eec87ba54ca7fba353f4f2b1bf 100644
--- a/chrome/browser/ui/webui/foreign_session_handler.cc
+++ b/chrome/browser/ui/webui/foreign_session_handler.cc
@@ -237,13 +237,6 @@ void ForeignSessionHandler::OnForeignSessionUpdated() {
HandleGetForeignSessions(nullptr);
}
-bool ForeignSessionHandler::IsTabSyncEnabled() {
- Profile* profile = Profile::FromWebUI(web_ui());
- browser_sync::ProfileSyncService* service =
- ProfileSyncServiceFactory::GetInstance()->GetForProfile(profile);
- return service && service->GetActiveDataTypes().Has(syncer::PROXY_TABS);
-}
-
base::string16 ForeignSessionHandler::FormatSessionTime(
const base::Time& time) {
// Return a time like "1 hour ago", "2 days ago", etc.
@@ -338,9 +331,7 @@ void ForeignSessionHandler::HandleGetForeignSessions(
session_list.Append(std::move(session_data));
}
}
- base::FundamentalValue tab_sync_enabled(IsTabSyncEnabled());
- web_ui()->CallJavascriptFunctionUnsafe("setForeignSessions", session_list,
- tab_sync_enabled);
+ web_ui()->CallJavascriptFunctionUnsafe("setForeignSessions", session_list);
}
void ForeignSessionHandler::HandleOpenForeignSession(
« no previous file with comments | « chrome/browser/ui/webui/foreign_session_handler.h ('k') | chrome/test/data/webui/md_history/history_metrics_test.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698