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/chromeos/login/login_display_host_impl.h" | 5 #include "chrome/browser/chromeos/login/login_display_host_impl.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "ash/desktop_background/desktop_background_controller.h" | 9 #include "ash/desktop_background/desktop_background_controller.h" |
10 #include "ash/desktop_background/user_wallpaper_delegate.h" | 10 #include "ash/desktop_background/user_wallpaper_delegate.h" |
11 #include "ash/shell.h" | 11 #include "ash/shell.h" |
12 #include "ash/shell_window_ids.h" | 12 #include "ash/shell_window_ids.h" |
13 #include "ash/wm/solo_window_tracker.h" | |
14 #include "base/bind.h" | 13 #include "base/bind.h" |
15 #include "base/command_line.h" | 14 #include "base/command_line.h" |
16 #include "base/debug/trace_event.h" | 15 #include "base/debug/trace_event.h" |
17 #include "base/logging.h" | 16 #include "base/logging.h" |
18 #include "base/prefs/pref_service.h" | 17 #include "base/prefs/pref_service.h" |
19 #include "base/strings/utf_string_conversions.h" | 18 #include "base/strings/utf_string_conversions.h" |
20 #include "base/threading/thread_restrictions.h" | 19 #include "base/threading/thread_restrictions.h" |
21 #include "base/time/time.h" | 20 #include "base/time/time.h" |
22 #include "base/values.h" | 21 #include "base/values.h" |
23 #include "chrome/browser/browser_process.h" | 22 #include "chrome/browser/browser_process.h" |
(...skipping 921 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
945 break; | 944 break; |
946 default: | 945 default: |
947 NOTREACHED(); | 946 NOTREACHED(); |
948 break; | 947 break; |
949 } | 948 } |
950 } | 949 } |
951 | 950 |
952 void LoginDisplayHostImpl::InitLoginWindowAndView() { | 951 void LoginDisplayHostImpl::InitLoginWindowAndView() { |
953 if (login_window_) | 952 if (login_window_) |
954 return; | 953 return; |
955 ash::SoloWindowTracker::SetSoloHeaderEnabled(false); | |
956 | 954 |
957 if (system::keyboard_settings::ForceKeyboardDrivenUINavigation()) { | 955 if (system::keyboard_settings::ForceKeyboardDrivenUINavigation()) { |
958 views::FocusManager::set_arrow_key_traversal_enabled(true); | 956 views::FocusManager::set_arrow_key_traversal_enabled(true); |
959 | 957 |
960 focus_ring_controller_.reset(new FocusRingController); | 958 focus_ring_controller_.reset(new FocusRingController); |
961 focus_ring_controller_->SetVisible(true); | 959 focus_ring_controller_->SetVisible(true); |
962 | 960 |
963 keyboard_driven_oobe_key_handler_.reset(new KeyboardDrivenOobeKeyHandler); | 961 keyboard_driven_oobe_key_handler_.reset(new KeyboardDrivenOobeKeyHandler); |
964 } | 962 } |
965 | 963 |
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
999 } else { | 997 } else { |
1000 LOG(WARNING) << "Login WebUI >> login wnd is hidden on create"; | 998 LOG(WARNING) << "Login WebUI >> login wnd is hidden on create"; |
1001 login_view_->set_is_hidden(true); | 999 login_view_->set_is_hidden(true); |
1002 } | 1000 } |
1003 login_window_->GetNativeView()->SetName("WebUILoginView"); | 1001 login_window_->GetNativeView()->SetName("WebUILoginView"); |
1004 } | 1002 } |
1005 | 1003 |
1006 void LoginDisplayHostImpl::ResetLoginWindowAndView() { | 1004 void LoginDisplayHostImpl::ResetLoginWindowAndView() { |
1007 if (!login_window_) | 1005 if (!login_window_) |
1008 return; | 1006 return; |
1009 ash::SoloWindowTracker::SetSoloHeaderEnabled(true); | |
1010 login_window_->Close(); | 1007 login_window_->Close(); |
1011 login_window_ = NULL; | 1008 login_window_ = NULL; |
1012 login_view_ = NULL; | 1009 login_view_ = NULL; |
1013 } | 1010 } |
1014 | 1011 |
1015 void LoginDisplayHostImpl::OnAuthPrewarmDone() { | 1012 void LoginDisplayHostImpl::OnAuthPrewarmDone() { |
1016 auth_prewarmer_.reset(); | 1013 auth_prewarmer_.reset(); |
1017 } | 1014 } |
1018 | 1015 |
1019 void LoginDisplayHostImpl::SetOobeProgressBarVisible(bool visible) { | 1016 void LoginDisplayHostImpl::SetOobeProgressBarVisible(bool visible) { |
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1195 | 1192 |
1196 scoped_ptr<locale_util::SwitchLanguageCallback> callback( | 1193 scoped_ptr<locale_util::SwitchLanguageCallback> callback( |
1197 new locale_util::SwitchLanguageCallback( | 1194 new locale_util::SwitchLanguageCallback( |
1198 base::Bind(&OnLanguageSwitchedCallback, base::Passed(data.Pass())))); | 1195 base::Bind(&OnLanguageSwitchedCallback, base::Passed(data.Pass())))); |
1199 | 1196 |
1200 // Do not load locale keyboards here. | 1197 // Do not load locale keyboards here. |
1201 locale_util::SwitchLanguage(locale, false, callback.Pass()); | 1198 locale_util::SwitchLanguage(locale, false, callback.Pass()); |
1202 } | 1199 } |
1203 | 1200 |
1204 } // namespace chromeos | 1201 } // namespace chromeos |
OLD | NEW |