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

Side by Side Diff: chrome/browser/chromeos/login/webui_login_view.cc

Issue 8598024: Now that we are doing a hard-cut-over to Aura, remove a bunch of *Views based classes that are ob... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 1 month 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 | Annotate | Revision Log
OLDNEW
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"
11 #include "base/values.h" 11 #include "base/values.h"
12 #include "chrome/browser/chromeos/accessibility_util.h" 12 #include "chrome/browser/chromeos/accessibility_util.h"
13 #include "chrome/browser/chromeos/cros/cros_library.h" 13 #include "chrome/browser/chromeos/cros/cros_library.h"
14 #include "chrome/browser/chromeos/dbus/dbus_thread_manager.h" 14 #include "chrome/browser/chromeos/dbus/dbus_thread_manager.h"
15 #include "chrome/browser/chromeos/dbus/session_manager_client.h" 15 #include "chrome/browser/chromeos/dbus/session_manager_client.h"
16 #include "chrome/browser/chromeos/login/proxy_settings_dialog.h" 16 #include "chrome/browser/chromeos/login/proxy_settings_dialog.h"
17 #include "chrome/browser/chromeos/login/webui_login_display.h" 17 #include "chrome/browser/chromeos/login/webui_login_display.h"
18 #include "chrome/browser/chromeos/status/status_area_view_chromeos.h" 18 #include "chrome/browser/chromeos/status/status_area_view_chromeos.h"
19 #include "chrome/browser/profiles/profile_manager.h" 19 #include "chrome/browser/profiles/profile_manager.h"
20 #include "chrome/browser/ui/views/dom_view.h" 20 #include "chrome/browser/ui/views/dom_view.h"
21 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h" 21 #include "chrome/browser/ui/webui/chromeos/login/oobe_ui.h"
22 #include "chrome/common/render_messages.h" 22 #include "chrome/common/render_messages.h"
23 #include "content/browser/renderer_host/render_view_host_observer.h" 23 #include "content/browser/renderer_host/render_view_host_observer.h"
24 #include "content/browser/tab_contents/tab_contents.h" 24 #include "content/browser/tab_contents/tab_contents.h"
25 #include "ui/gfx/rect.h" 25 #include "ui/gfx/rect.h"
26 #include "ui/gfx/size.h" 26 #include "ui/gfx/size.h"
27 #include "ui/views/desktop/desktop_window_view.h"
28 #include "views/widget/widget.h" 27 #include "views/widget/widget.h"
29 28
30 #if defined(TOOLKIT_USES_GTK) 29 #if defined(TOOLKIT_USES_GTK)
31 #include "chrome/browser/chromeos/legacy_window_manager/wm_ipc.h" 30 #include "chrome/browser/chromeos/legacy_window_manager/wm_ipc.h"
32 #include "views/widget/native_widget_gtk.h" 31 #include "views/widget/native_widget_gtk.h"
33 #endif 32 #endif
34 33
35 #if defined(USE_VIRTUAL_KEYBOARD) 34 #if defined(USE_VIRTUAL_KEYBOARD)
36 #include "chrome/browser/ui/virtual_keyboard/virtual_keyboard_manager.h" 35 #include "chrome/browser/ui/virtual_keyboard/virtual_keyboard_manager.h"
37 #endif 36 #endif
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after
295 host_window_frozen_ = false; 294 host_window_frozen_ = false;
296 295
297 // Unfreezes the host window since tab is rendered now. 296 // Unfreezes the host window since tab is rendered now.
298 views::NativeWidgetGtk::UpdateFreezeUpdatesProperty( 297 views::NativeWidgetGtk::UpdateFreezeUpdatesProperty(
299 GetNativeWindow(), false); 298 GetNativeWindow(), false);
300 } 299 }
301 #endif 300 #endif
302 301
303 bool emit_login_visible = false; 302 bool emit_login_visible = false;
304 303
305 // In aura or views-desktop environment, there will be no window-manager. So 304 // In aura, there will be no window-manager. So chrome needs to emit the
306 // chrome needs to emit the 'login-prompt-visible' signal. This needs to 305 // 'login-prompt-visible' signal. This needs to happen here, after the page
307 // happen here, after the page has completed rendering itself. 306 // has completed rendering itself.
308 #if defined(USE_AURA) 307 #if defined(USE_AURA)
309 emit_login_visible = true; 308 emit_login_visible = true;
310 #else
311 if (views::desktop::DesktopWindowView::desktop_window_view)
312 emit_login_visible = true;
313 #endif 309 #endif
314 if (emit_login_visible) 310 if (emit_login_visible)
315 chromeos::DBusThreadManager::Get()->GetSessionManagerClient() 311 chromeos::DBusThreadManager::Get()->GetSessionManagerClient()
316 ->EmitLoginPromptVisible(); 312 ->EmitLoginPromptVisible();
317 313
318 OobeUI* oobe_ui = static_cast<OobeUI*>(GetWebUI()); 314 OobeUI* oobe_ui = static_cast<OobeUI*>(GetWebUI());
319 // Notify OOBE that the login frame has been rendered. Currently 315 // Notify OOBE that the login frame has been rendered. Currently
320 // this is used to start camera presence check. 316 // this is used to start camera presence check.
321 oobe_ui->OnLoginPromptVisible(); 317 oobe_ui->OnLoginPromptVisible();
322 } 318 }
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
409 // when the focus is inside an iframe. Only clear on KeyDown to prevent hiding 405 // when the focus is inside an iframe. Only clear on KeyDown to prevent hiding
410 // an immediate authentication error (See crbug.com/103643). 406 // an immediate authentication error (See crbug.com/103643).
411 if (event.type == WebKit::WebInputEvent::KeyDown) { 407 if (event.type == WebKit::WebInputEvent::KeyDown) {
412 WebUI* web_ui = GetWebUI(); 408 WebUI* web_ui = GetWebUI();
413 if (web_ui) 409 if (web_ui)
414 web_ui->CallJavascriptFunction("cr.ui.Oobe.clearErrors"); 410 web_ui->CallJavascriptFunction("cr.ui.Oobe.clearErrors");
415 } 411 }
416 } 412 }
417 413
418 } // namespace chromeos 414 } // namespace chromeos
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/login/login_utils.cc ('k') | chrome/browser/extensions/extension_input_api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698