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

Side by Side Diff: chromeos/login/login_state.cc

Issue 608283003: Remove retail mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chromeos/login/login_state.h" 5 #include "chromeos/login/login_state.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/sys_info.h" 9 #include "base/sys_info.h"
10 #include "chromeos/chromeos_switches.h" 10 #include "chromeos/chromeos_switches.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 bool LoginState::IsInSafeMode() const { 89 bool LoginState::IsInSafeMode() const {
90 DCHECK(!always_logged_in_ || logged_in_state_ != LOGGED_IN_SAFE_MODE); 90 DCHECK(!always_logged_in_ || logged_in_state_ != LOGGED_IN_SAFE_MODE);
91 return logged_in_state_ == LOGGED_IN_SAFE_MODE; 91 return logged_in_state_ == LOGGED_IN_SAFE_MODE;
92 } 92 }
93 93
94 bool LoginState::IsGuestSessionUser() const { 94 bool LoginState::IsGuestSessionUser() const {
95 return logged_in_user_type_ == LOGGED_IN_USER_GUEST; 95 return logged_in_user_type_ == LOGGED_IN_USER_GUEST;
96 } 96 }
97 97
98 bool LoginState::IsPublicSessionUser() const { 98 bool LoginState::IsPublicSessionUser() const {
99 return logged_in_user_type_ == LOGGED_IN_USER_PUBLIC_ACCOUNT || 99 return logged_in_user_type_ == LOGGED_IN_USER_PUBLIC_ACCOUNT;
100 logged_in_user_type_ == LOGGED_IN_USER_RETAIL_MODE;
101 } 100 }
102 101
103 bool LoginState::IsKioskApp() const { 102 bool LoginState::IsKioskApp() const {
104 return logged_in_user_type_ == LOGGED_IN_USER_KIOSK_APP; 103 return logged_in_user_type_ == LOGGED_IN_USER_KIOSK_APP;
105 } 104 }
106 105
107 bool LoginState::UserHasNetworkProfile() const { 106 bool LoginState::UserHasNetworkProfile() const {
108 if (!IsUserLoggedIn()) 107 if (!IsUserLoggedIn())
109 return false; 108 return false;
110 return logged_in_user_type_ != LOGGED_IN_USER_PUBLIC_ACCOUNT; 109 return logged_in_user_type_ != LOGGED_IN_USER_PUBLIC_ACCOUNT;
(...skipping 19 matching lines...) Expand all
130 129
131 LoginState::~LoginState() { 130 LoginState::~LoginState() {
132 } 131 }
133 132
134 void LoginState::NotifyObservers() { 133 void LoginState::NotifyObservers() {
135 FOR_EACH_OBSERVER(LoginState::Observer, observer_list_, 134 FOR_EACH_OBSERVER(LoginState::Observer, observer_list_,
136 LoggedInStateChanged()); 135 LoggedInStateChanged());
137 } 136 }
138 137
139 } // namespace chromeos 138 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698