OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/ui/login_display_host_impl.h" | 5 #include "chrome/browser/chromeos/login/ui/login_display_host_impl.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "ash/audio/sounds.h" | 9 #include "ash/audio/sounds.h" |
10 #include "ash/desktop_background/desktop_background_controller.h" | 10 #include "ash/desktop_background/desktop_background_controller.h" |
(...skipping 898 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
909 if (shutting_down_) | 909 if (shutting_down_) |
910 return; | 910 return; |
911 | 911 |
912 shutting_down_ = true; | 912 shutting_down_ = true; |
913 registrar_.RemoveAll(); | 913 registrar_.RemoveAll(); |
914 base::MessageLoop::current()->DeleteSoon(FROM_HERE, this); | 914 base::MessageLoop::current()->DeleteSoon(FROM_HERE, this); |
915 if (post_quit_task) | 915 if (post_quit_task) |
916 base::MessageLoop::current()->Quit(); | 916 base::MessageLoop::current()->Quit(); |
917 | 917 |
918 if (!completion_callback_.is_null()) | 918 if (!completion_callback_.is_null()) |
919 completion_callback_.Run(); | 919 base::MessageLoop::current()->PostTask(FROM_HERE, completion_callback_); |
dzhioev (left Google)
2015/09/24 23:51:17
Can you please explain, how this helps to prevent
| |
920 } | 920 } |
921 | 921 |
922 void LoginDisplayHostImpl::ScheduleWorkspaceAnimation() { | 922 void LoginDisplayHostImpl::ScheduleWorkspaceAnimation() { |
923 if (ash::Shell::GetContainer(ash::Shell::GetPrimaryRootWindow(), | 923 if (ash::Shell::GetContainer(ash::Shell::GetPrimaryRootWindow(), |
924 ash::kShellWindowId_DesktopBackgroundContainer) | 924 ash::kShellWindowId_DesktopBackgroundContainer) |
925 ->children() | 925 ->children() |
926 .empty()) { | 926 .empty()) { |
927 // If there is no background window, don't perform any animation on the | 927 // If there is no background window, don't perform any animation on the |
928 // default and background layer because there is nothing behind it. | 928 // default and background layer because there is nothing behind it. |
929 return; | 929 return; |
(...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1256 | 1256 |
1257 locale_util::SwitchLanguageCallback callback( | 1257 locale_util::SwitchLanguageCallback callback( |
1258 base::Bind(&OnLanguageSwitchedCallback, base::Passed(data.Pass()))); | 1258 base::Bind(&OnLanguageSwitchedCallback, base::Passed(data.Pass()))); |
1259 | 1259 |
1260 // Load locale keyboards here. Hardware layout would be automatically enabled. | 1260 // Load locale keyboards here. Hardware layout would be automatically enabled. |
1261 locale_util::SwitchLanguage(locale, true, true /* login_layouts_only */, | 1261 locale_util::SwitchLanguage(locale, true, true /* login_layouts_only */, |
1262 callback, ProfileManager::GetActiveUserProfile()); | 1262 callback, ProfileManager::GetActiveUserProfile()); |
1263 } | 1263 } |
1264 | 1264 |
1265 } // namespace chromeos | 1265 } // namespace chromeos |
OLD | NEW |