| 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 "athena/main/athena_launcher.h" | 5 #include "athena/main/athena_launcher.h" |
| 6 | 6 |
| 7 #include "athena/activity/public/activity_manager.h" | 7 #include "athena/activity/public/activity_manager.h" |
| 8 #include "athena/home/public/home_card.h" | 8 #include "athena/home/public/home_card.h" |
| 9 #include "athena/input/public/input_manager.h" |
| 9 #include "athena/main/placeholder.h" | 10 #include "athena/main/placeholder.h" |
| 10 #include "athena/screen/public/screen_manager.h" | 11 #include "athena/screen/public/screen_manager.h" |
| 11 #include "athena/wm/public/window_manager.h" | 12 #include "athena/wm/public/window_manager.h" |
| 12 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
| 13 #include "ui/aura/window_property.h" | 14 #include "ui/aura/window_property.h" |
| 14 #include "ui/wm/core/visibility_controller.h" | 15 #include "ui/wm/core/visibility_controller.h" |
| 15 | 16 |
| 16 namespace athena { | 17 namespace athena { |
| 17 struct RootWindowState; | 18 struct RootWindowState; |
| 18 } | 19 } |
| (...skipping 12 matching lines...) Expand all Loading... |
| 31 NULL); | 32 NULL); |
| 32 | 33 |
| 33 void StartAthena(aura::Window* root_window) { | 34 void StartAthena(aura::Window* root_window) { |
| 34 RootWindowState* root_window_state = new RootWindowState; | 35 RootWindowState* root_window_state = new RootWindowState; |
| 35 root_window->SetProperty(kRootWindowStateKey, root_window_state); | 36 root_window->SetProperty(kRootWindowStateKey, root_window_state); |
| 36 | 37 |
| 37 root_window_state->visibility_client.reset(new ::wm::VisibilityController); | 38 root_window_state->visibility_client.reset(new ::wm::VisibilityController); |
| 38 aura::client::SetVisibilityClient(root_window, | 39 aura::client::SetVisibilityClient(root_window, |
| 39 root_window_state->visibility_client.get()); | 40 root_window_state->visibility_client.get()); |
| 40 | 41 |
| 42 athena::InputManager::Create()->OnRootWindowCreated(root_window); |
| 41 athena::ScreenManager::Create(root_window); | 43 athena::ScreenManager::Create(root_window); |
| 42 athena::WindowManager::Create(); | 44 athena::WindowManager::Create(); |
| 43 athena::HomeCard::Create(); | 45 athena::HomeCard::Create(); |
| 44 athena::ActivityManager::Create(); | 46 athena::ActivityManager::Create(); |
| 45 | 47 |
| 46 SetupBackgroundImage(); | 48 SetupBackgroundImage(); |
| 47 } | 49 } |
| 48 | 50 |
| 49 void ShutdownAthena() { | 51 void ShutdownAthena() { |
| 50 athena::ActivityManager::Shutdown(); | 52 athena::ActivityManager::Shutdown(); |
| 51 athena::HomeCard::Shutdown(); | 53 athena::HomeCard::Shutdown(); |
| 52 athena::WindowManager::Shutdown(); | 54 athena::WindowManager::Shutdown(); |
| 53 athena::ScreenManager::Shutdown(); | 55 athena::ScreenManager::Shutdown(); |
| 56 athena::InputManager::Shutdown(); |
| 54 } | 57 } |
| 55 | 58 |
| 56 } // namespace athena | 59 } // namespace athena |
| OLD | NEW |