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/error_screen_handler.h" | 5 #include "chrome/browser/ui/webui/chromeos/login/error_screen_handler.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
10 #include "base/time.h" | 10 #include "base/time.h" |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 localized_strings->SetString("offlineMessageTitle", | 150 localized_strings->SetString("offlineMessageTitle", |
151 l10n_util::GetStringUTF16(IDS_LOGIN_OFFLINE_TITLE)); | 151 l10n_util::GetStringUTF16(IDS_LOGIN_OFFLINE_TITLE)); |
152 localized_strings->SetString("offlineMessageBody", | 152 localized_strings->SetString("offlineMessageBody", |
153 l10n_util::GetStringUTF16(IDS_LOGIN_OFFLINE_MESSAGE)); | 153 l10n_util::GetStringUTF16(IDS_LOGIN_OFFLINE_MESSAGE)); |
154 localized_strings->SetString("captivePortalTitle", | 154 localized_strings->SetString("captivePortalTitle", |
155 l10n_util::GetStringUTF16(IDS_LOGIN_MAYBE_CAPTIVE_PORTAL_TITLE)); | 155 l10n_util::GetStringUTF16(IDS_LOGIN_MAYBE_CAPTIVE_PORTAL_TITLE)); |
156 localized_strings->SetString("captivePortalMessage", | 156 localized_strings->SetString("captivePortalMessage", |
157 l10n_util::GetStringUTF16(IDS_LOGIN_MAYBE_CAPTIVE_PORTAL)); | 157 l10n_util::GetStringUTF16(IDS_LOGIN_MAYBE_CAPTIVE_PORTAL)); |
158 localized_strings->SetString("captivePortalProxyMessage", | 158 localized_strings->SetString("captivePortalProxyMessage", |
159 l10n_util::GetStringUTF16(IDS_LOGIN_MAYBE_CAPTIVE_PORTAL_PROXY)); | 159 l10n_util::GetStringUTF16(IDS_LOGIN_MAYBE_CAPTIVE_PORTAL_PROXY)); |
160 localized_strings->SetString("timeoutMessageTitle", | |
161 l10n_util::GetStringUTF16(IDS_LOGIN_TIMEOUT_TITLE)); | |
162 localized_strings->SetString("captivePortalNetworkSelect", | 160 localized_strings->SetString("captivePortalNetworkSelect", |
163 l10n_util::GetStringUTF16(IDS_LOGIN_MAYBE_CAPTIVE_PORTAL_NETWORK_SELECT)); | 161 l10n_util::GetStringUTF16(IDS_LOGIN_MAYBE_CAPTIVE_PORTAL_NETWORK_SELECT)); |
164 localized_strings->SetString("proxyMessageText", | 162 localized_strings->SetString("proxyMessageText", |
165 l10n_util::GetStringUTF16(IDS_LOGIN_PROXY_ERROR_MESSAGE)); | 163 l10n_util::GetStringUTF16(IDS_LOGIN_PROXY_ERROR_MESSAGE)); |
166 } | 164 } |
167 | 165 |
168 void ErrorScreenHandler::Initialize() { | 166 void ErrorScreenHandler::Initialize() { |
169 if (!page_is_ready()) | 167 if (!page_is_ready()) |
170 return; | 168 return; |
171 if (show_on_init_) { | 169 if (show_on_init_) { |
172 Show(parent_screen_, NULL); | 170 Show(parent_screen_, NULL); |
173 show_on_init_ = false; | 171 show_on_init_ = false; |
174 } | 172 } |
175 } | 173 } |
176 | 174 |
177 gfx::NativeWindow ErrorScreenHandler::GetNativeWindow() { | 175 gfx::NativeWindow ErrorScreenHandler::GetNativeWindow() { |
178 if (native_window_delegate_) | 176 if (native_window_delegate_) |
179 return native_window_delegate_->GetNativeWindow(); | 177 return native_window_delegate_->GetNativeWindow(); |
180 return NULL; | 178 return NULL; |
181 } | 179 } |
182 | 180 |
183 } // namespace chromeos | 181 } // namespace chromeos |
OLD | NEW |