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

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

Issue 957253003: Fix chrome://history for supervised users on mobile (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comment Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/resources/history/history_mobile.css ('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/history_ui.cc
diff --git a/chrome/browser/ui/webui/history_ui.cc b/chrome/browser/ui/webui/history_ui.cc
index ad89a93c3bbf17059531c57dc25475be6fff8cf6..8585e3fafd30caef3831765fd2f1635264f4a246 100644
--- a/chrome/browser/ui/webui/history_ui.cc
+++ b/chrome/browser/ui/webui/history_ui.cc
@@ -191,10 +191,14 @@ content::WebUIDataSource* CreateHistoryUIHTMLSource(Profile* profile) {
source->AddLocalizedString("entrySummary", IDS_HISTORY_ENTRY_SUMMARY);
source->AddBoolean("isFullHistorySyncEnabled",
WebHistoryServiceFactory::GetForProfile(profile) != NULL);
- source->AddBoolean("groupByDomain",
- profile->IsSupervised() ||
- base::CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kHistoryEnableGroupByDomain));
+ bool group_by_domain = base::CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kHistoryEnableGroupByDomain);
+ // Supervised users get the "group by domain" version, but not on mobile,
+ // because that version isn't adjusted for small screens yet. crbug.com/452859
+#if !defined(OS_ANDROID) && !defined(OS_IOS)
+ group_by_domain = group_by_domain || profile->IsSupervised();
+#endif
+ source->AddBoolean("groupByDomain", group_by_domain);
bool allow_deleting_history =
prefs->GetBoolean(prefs::kAllowDeletingBrowserHistory);
source->AddBoolean("allowDeletingHistory", allow_deleting_history);
« no previous file with comments | « chrome/browser/resources/history/history_mobile.css ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698