OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
77 | 77 |
78 OobeUIHTMLSource::OobeUIHTMLSource(DictionaryValue* localized_strings) | 78 OobeUIHTMLSource::OobeUIHTMLSource(DictionaryValue* localized_strings) |
79 : DataSource(chrome::kChromeUIOobeHost, MessageLoop::current()), | 79 : DataSource(chrome::kChromeUIOobeHost, MessageLoop::current()), |
80 localized_strings_(localized_strings) { | 80 localized_strings_(localized_strings) { |
81 } | 81 } |
82 | 82 |
83 void OobeUIHTMLSource::StartDataRequest(const std::string& path, | 83 void OobeUIHTMLSource::StartDataRequest(const std::string& path, |
84 bool is_incognito, | 84 bool is_incognito, |
85 int request_id) { | 85 int request_id) { |
86 if (UserManager::Get()->IsUserLoggedIn() && | 86 if (UserManager::Get()->IsUserLoggedIn() && |
87 !UserManager::Get()->IsLoggedInAsStub() && | |
rkc
2012/03/22 03:02:34
UserManager::Get()->IsUserLoggedIn() should not be
pastarmovj
2012/03/22 10:39:24
This was my first thought too but after discussing
| |
87 !ScreenLocker::default_screen_locker()) { | 88 !ScreenLocker::default_screen_locker()) { |
88 scoped_refptr<RefCountedBytes> empty_bytes(new RefCountedBytes()); | 89 scoped_refptr<RefCountedBytes> empty_bytes(new RefCountedBytes()); |
89 SendResponse(request_id, empty_bytes); | 90 SendResponse(request_id, empty_bytes); |
90 return; | 91 return; |
91 } | 92 } |
92 | 93 |
93 std::string response; | 94 std::string response; |
94 if (chromeos::KioskModeSettings::Get()->IsKioskModeEnabled()) | 95 if (chromeos::KioskModeSettings::Get()->IsKioskModeEnabled()) |
95 response = GetDataResource(IDR_DEMO_USER_LOGIN_HTML); | 96 response = GetDataResource(IDR_DEMO_USER_LOGIN_HTML); |
96 else if (path.empty()) | 97 else if (path.empty()) |
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
245 | 246 |
246 void OobeUI::ResetSigninScreenHandlerDelegate() { | 247 void OobeUI::ResetSigninScreenHandlerDelegate() { |
247 signin_screen_handler_->SetDelegate(NULL); | 248 signin_screen_handler_->SetDelegate(NULL); |
248 } | 249 } |
249 | 250 |
250 void OobeUI::OnLoginPromptVisible() { | 251 void OobeUI::OnLoginPromptVisible() { |
251 user_image_screen_actor_->CheckCameraPresence(); | 252 user_image_screen_actor_->CheckCameraPresence(); |
252 } | 253 } |
253 | 254 |
254 } // namespace chromeos | 255 } // namespace chromeos |
OLD | NEW |