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

Unified Diff: chrome/browser/profiles/profile_window.cc

Issue 2029263002: [MD Settings] Add feature to enable md-settings by default. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix URL CHECK statement. (Use URL, not Host) Created 4 years, 6 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/profiles/profile_window.cc
diff --git a/chrome/browser/profiles/profile_window.cc b/chrome/browser/profiles/profile_window.cc
index f9b2b362c7b0b84513a621516727f19eb7e64275..dbf14c4965c3efd029e36b082551c9cadb877ef2 100644
--- a/chrome/browser/profiles/profile_window.cc
+++ b/chrome/browser/profiles/profile_window.cc
@@ -35,6 +35,7 @@
#include "chrome/browser/ui/browser_dialogs.h"
#include "chrome/browser/ui/profile_chooser_constants.h"
#include "chrome/browser/ui/user_manager.h"
+#include "chrome/common/chrome_features.h"
#include "chrome/common/pref_names.h"
#include "chrome/common/url_constants.h"
#include "components/browser_sync/browser/profile_sync_service.h"
@@ -135,9 +136,15 @@ void OnUserManagerSystemProfileCreated(
if (status != Profile::CREATE_STATUS_INITIALIZED || callback.is_null())
return;
+ // Force Material Design user manager on when Material Design settings are on.
+ bool use_material_design_user_manager =
+ switches::IsMaterialDesignUserManager() ||
+ base::FeatureList::IsEnabled(features::kMaterialDesignSettingsFeature);
+
// Tell the webui which user should be focused.
- std::string page = switches::IsMaterialDesignUserManager() ?
- chrome::kChromeUIMdUserManagerUrl : chrome::kChromeUIUserManagerURL;
+ std::string page = use_material_design_user_manager
+ ? chrome::kChromeUIMdUserManagerUrl
+ : chrome::kChromeUIUserManagerURL;
if (tutorial_mode == profiles::USER_MANAGER_TUTORIAL_OVERVIEW) {
page += profiles::kUserManagerDisplayTutorial;
« no previous file with comments | « chrome/browser/browser_about_handler.cc ('k') | chrome/browser/ui/webui/chrome_web_ui_controller_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698