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

Unified Diff: chrome/browser/ui/chrome_pages.cc

Issue 12088040: Add a SigninAllowed policy. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Extract managed user specific stuff into another changelist. Created 7 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
Index: chrome/browser/ui/chrome_pages.cc
diff --git a/chrome/browser/ui/chrome_pages.cc b/chrome/browser/ui/chrome_pages.cc
index a2fbf0e8a4471a11e4653bb92321b62a7519a8f3..ddfb24bdaec9285ab3f925b70d70c86a3313b78c 100644
--- a/chrome/browser/ui/chrome_pages.cc
+++ b/chrome/browser/ui/chrome_pages.cc
@@ -185,6 +185,9 @@ void ShowBrowserSignin(Browser* browser, SyncPromoUI::Source source) {
Profile* original_profile = browser->profile()->GetOriginalProfile();
SigninManager* manager =
SigninManagerFactory::GetForProfile(original_profile);
+ // Check if Signin to Chrome is allowed by the policy.
+ if (!manager->IsSigninAllowed())
sail 2013/02/08 20:18:57 Why would this code be reached if signin is not al
Adrian Kuegel 2013/02/11 16:47:30 Yes, I agree this code should never be reached if
sail 2013/02/20 23:08:21 DCHECK is fine.
+ return;
// If we're signed in, just show settings.
if (!manager->GetAuthenticatedUsername().empty()) {
ShowSettings(browser);

Powered by Google App Engine
This is Rietveld 408576698