OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/chromeos/login/webui_login_view.h" | 5 #include "chrome/browser/chromeos/login/webui_login_view.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/i18n/rtl.h" | 9 #include "base/i18n/rtl.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
200 ¶ms); | 200 ¶ms); |
201 #endif | 201 #endif |
202 } | 202 } |
203 | 203 |
204 void WebUILoginView::LoadURL(const GURL & url) { | 204 void WebUILoginView::LoadURL(const GURL & url) { |
205 webui_login_->LoadURL(url); | 205 webui_login_->LoadURL(url); |
206 webui_login_->RequestFocus(); | 206 webui_login_->RequestFocus(); |
207 } | 207 } |
208 | 208 |
209 WebUI* WebUILoginView::GetWebUI() { | 209 WebUI* WebUILoginView::GetWebUI() { |
210 return webui_login_->dom_contents()->tab_contents()->web_ui(); | 210 return webui_login_->dom_contents()->tab_contents()->GetWebUI(); |
211 } | 211 } |
212 | 212 |
213 void WebUILoginView::SetStatusAreaEnabled(bool enable) { | 213 void WebUILoginView::SetStatusAreaEnabled(bool enable) { |
214 if (status_area_) | 214 if (status_area_) |
215 status_area_->MakeButtonsActive(enable); | 215 status_area_->MakeButtonsActive(enable); |
216 } | 216 } |
217 | 217 |
218 void WebUILoginView::SetStatusAreaVisible(bool visible) { | 218 void WebUILoginView::SetStatusAreaVisible(bool visible) { |
219 if (status_area_) | 219 if (status_area_) |
220 status_area_->SetVisible(visible); | 220 status_area_->SetVisible(visible); |
(...skipping 198 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
419 // when the focus is inside an iframe. Only clear on KeyDown to prevent hiding | 419 // when the focus is inside an iframe. Only clear on KeyDown to prevent hiding |
420 // an immediate authentication error (See crbug.com/103643). | 420 // an immediate authentication error (See crbug.com/103643). |
421 if (event.type == WebKit::WebInputEvent::KeyDown) { | 421 if (event.type == WebKit::WebInputEvent::KeyDown) { |
422 WebUI* web_ui = GetWebUI(); | 422 WebUI* web_ui = GetWebUI(); |
423 if (web_ui) | 423 if (web_ui) |
424 web_ui->CallJavascriptFunction("cr.ui.Oobe.clearErrors"); | 424 web_ui->CallJavascriptFunction("cr.ui.Oobe.clearErrors"); |
425 } | 425 } |
426 } | 426 } |
427 | 427 |
428 } // namespace chromeos | 428 } // namespace chromeos |
OLD | NEW |