| 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 "ash/shell.h" | 5 #include "ash/shell.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "ash/accelerators/focus_manager_factory.h" | 10 #include "ash/accelerators/focus_manager_factory.h" |
| (...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 451 | 451 |
| 452 // StatusAreaWidget uses Shell's CapsLockDelegate. | 452 // StatusAreaWidget uses Shell's CapsLockDelegate. |
| 453 if (delegate_.get()) | 453 if (delegate_.get()) |
| 454 caps_lock_delegate_.reset(delegate_->CreateCapsLockDelegate()); | 454 caps_lock_delegate_.reset(delegate_->CreateCapsLockDelegate()); |
| 455 else | 455 else |
| 456 caps_lock_delegate_.reset(new CapsLockDelegateStub); | 456 caps_lock_delegate_.reset(new CapsLockDelegateStub); |
| 457 | 457 |
| 458 // Initialize Primary RootWindow specific items. | 458 // Initialize Primary RootWindow specific items. |
| 459 status_area_widget_ = new internal::StatusAreaWidget(); | 459 status_area_widget_ = new internal::StatusAreaWidget(); |
| 460 status_area_widget_->CreateTrayViews(delegate_.get()); | 460 status_area_widget_->CreateTrayViews(delegate_.get()); |
| 461 status_area_widget_->Show(); | 461 // Login screen manages status area visibility by itself. |
| 462 if (delegate_.get() && delegate_->IsSessionStarted()) |
| 463 status_area_widget_->Show(); |
| 462 | 464 |
| 463 focus_cycler_.reset(new internal::FocusCycler()); | 465 focus_cycler_.reset(new internal::FocusCycler()); |
| 464 focus_cycler_->AddWidget(status_area_widget_); | 466 focus_cycler_->AddWidget(status_area_widget_); |
| 465 | 467 |
| 466 // This controller needs to be set before SetupManagedWindowMode. | 468 // This controller needs to be set before SetupManagedWindowMode. |
| 467 desktop_background_controller_.reset(new DesktopBackgroundController()); | 469 desktop_background_controller_.reset(new DesktopBackgroundController()); |
| 468 if (delegate_.get()) | 470 if (delegate_.get()) |
| 469 user_wallpaper_delegate_.reset(delegate_->CreateUserWallpaperDelegate()); | 471 user_wallpaper_delegate_.reset(delegate_->CreateUserWallpaperDelegate()); |
| 470 if (!user_wallpaper_delegate_.get()) | 472 if (!user_wallpaper_delegate_.get()) |
| 471 user_wallpaper_delegate_.reset(new DummyUserWallpaperDelegate()); | 473 user_wallpaper_delegate_.reset(new DummyUserWallpaperDelegate()); |
| (...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 771 } | 773 } |
| 772 | 774 |
| 773 void Shell::ShowCursor(bool visible) { | 775 void Shell::ShowCursor(bool visible) { |
| 774 RootWindowList root_windows = GetAllRootWindows(); | 776 RootWindowList root_windows = GetAllRootWindows(); |
| 775 for (RootWindowList::iterator iter = root_windows.begin(); | 777 for (RootWindowList::iterator iter = root_windows.begin(); |
| 776 iter != root_windows.end(); ++iter) | 778 iter != root_windows.end(); ++iter) |
| 777 (*iter)->ShowCursor(visible); | 779 (*iter)->ShowCursor(visible); |
| 778 } | 780 } |
| 779 | 781 |
| 780 } // namespace ash | 782 } // namespace ash |
| OLD | NEW |