| OLD | NEW |
| 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 "ui/aura/desktop.h" | 5 #include "ui/aura/desktop.h" |
| 6 #include "ui/aura/toplevel_window_container.h" | 6 #include "ui/aura/toplevel_window_container.h" |
| 7 #include "ui/aura/window.h" | 7 #include "ui/aura/window.h" |
| 8 #include "ui/aura_shell/desktop_layout_manager.h" | 8 #include "ui/aura_shell/desktop_layout_manager.h" |
| 9 #include "ui/aura_shell/shell_factory.h" | 9 #include "ui/aura_shell/shell_factory.h" |
| 10 #include "ui/aura_shell/shell_window_ids.h" | 10 #include "ui/aura_shell/shell_window_ids.h" |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 status_container->set_id(internal::kShellWindowId_StatusContainer); | 44 status_container->set_id(internal::kShellWindowId_StatusContainer); |
| 45 containers->push_back(status_container); | 45 containers->push_back(status_container); |
| 46 } | 46 } |
| 47 | 47 |
| 48 void InitDesktopWindow() { | 48 void InitDesktopWindow() { |
| 49 aura::Window::Windows containers; | 49 aura::Window::Windows containers; |
| 50 CreateSpecialContainers(&containers); | 50 CreateSpecialContainers(&containers); |
| 51 aura::Window::Windows::const_iterator i; | 51 aura::Window::Windows::const_iterator i; |
| 52 for (i = containers.begin(); i != containers.end(); ++i) { | 52 for (i = containers.begin(); i != containers.end(); ++i) { |
| 53 (*i)->Init(); | 53 (*i)->Init(); |
| 54 (*i)->SetVisibility(aura::Window::VISIBILITY_SHOWN); | 54 (*i)->Show(); |
| 55 aura::Desktop::GetInstance()->window()->AddChild(*i); | 55 aura::Desktop::GetInstance()->window()->AddChild(*i); |
| 56 } | 56 } |
| 57 | 57 |
| 58 aura::Window* root_window = aura::Desktop::GetInstance()->window(); | 58 aura::Window* root_window = aura::Desktop::GetInstance()->window(); |
| 59 internal::DesktopLayoutManager* desktop_layout = | 59 internal::DesktopLayoutManager* desktop_layout = |
| 60 new internal::DesktopLayoutManager(root_window); | 60 new internal::DesktopLayoutManager(root_window); |
| 61 root_window->SetLayoutManager(desktop_layout); | 61 root_window->SetLayoutManager(desktop_layout); |
| 62 | 62 |
| 63 views::Widget* desktop_background = internal::CreateDesktopBackground(); | 63 views::Widget* desktop_background = internal::CreateDesktopBackground(); |
| 64 aura::Desktop::GetInstance()->window()->GetChildById( | 64 aura::Desktop::GetInstance()->window()->GetChildById( |
| (...skipping 10 matching lines...) Expand all Loading... |
| 75 internal::kShellWindowId_StatusContainer)->AddChild( | 75 internal::kShellWindowId_StatusContainer)->AddChild( |
| 76 status_area->GetNativeView()); | 76 status_area->GetNativeView()); |
| 77 | 77 |
| 78 desktop_layout->set_background_widget(desktop_background); | 78 desktop_layout->set_background_widget(desktop_background); |
| 79 desktop_layout->set_launcher_widget(launcher); | 79 desktop_layout->set_launcher_widget(launcher); |
| 80 desktop_layout->set_status_area_widget(status_area); | 80 desktop_layout->set_status_area_widget(status_area); |
| 81 } | 81 } |
| 82 | 82 |
| 83 } // namespace aura_shell | 83 } // namespace aura_shell |
| 84 | 84 |
| OLD | NEW |