| 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 "content/shell/shell.h" | 5 #include "content/shell/shell.h" |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
| 9 #include "ui/aura/desktop/desktop_screen.h" | 9 #include "ui/aura/desktop/desktop_screen.h" |
| 10 #include "ui/aura/display_manager.h" | 10 #include "ui/aura/display_manager.h" |
| (...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 286 aura::Env::GetInstance()->SetDisplayManager(new aura::SingleDisplayManager); | 286 aura::Env::GetInstance()->SetDisplayManager(new aura::SingleDisplayManager); |
| 287 #if defined(OS_CHROMEOS) | 287 #if defined(OS_CHROMEOS) |
| 288 stacking_client_ = new content::ShellStackingClientAsh(); | 288 stacking_client_ = new content::ShellStackingClientAsh(); |
| 289 gfx::Screen::SetScreenInstance( | 289 gfx::Screen::SetScreenInstance( |
| 290 gfx::SCREEN_TYPE_NATIVE, new ash::ScreenAsh); | 290 gfx::SCREEN_TYPE_NATIVE, new ash::ScreenAsh); |
| 291 #else | 291 #else |
| 292 stacking_client_ = new aura::DesktopStackingClient(); | 292 stacking_client_ = new aura::DesktopStackingClient(); |
| 293 gfx::Screen::SetScreenInstance( | 293 gfx::Screen::SetScreenInstance( |
| 294 gfx::SCREEN_TYPE_NATIVE, aura::CreateDesktopScreen()); | 294 gfx::SCREEN_TYPE_NATIVE, aura::CreateDesktopScreen()); |
| 295 #endif | 295 #endif |
| 296 aura::client::SetStackingClient(stacking_client_); |
| 296 views_delegate_ = new ShellViewsDelegateAura(); | 297 views_delegate_ = new ShellViewsDelegateAura(); |
| 297 } | 298 } |
| 298 | 299 |
| 299 void Shell::PlatformExit() { | 300 void Shell::PlatformExit() { |
| 300 if (stacking_client_) | 301 if (stacking_client_) |
| 301 delete stacking_client_; | 302 delete stacking_client_; |
| 302 if (views_delegate_) | 303 if (views_delegate_) |
| 303 delete views_delegate_; | 304 delete views_delegate_; |
| 304 #if defined(OS_CHROMEOS) | 305 #if defined(OS_CHROMEOS) |
| 305 chromeos::DBusThreadManager::Shutdown(); | 306 chromeos::DBusThreadManager::Shutdown(); |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 356 } | 357 } |
| 357 | 358 |
| 358 void Shell::PlatformSetTitle(const string16& title) { | 359 void Shell::PlatformSetTitle(const string16& title) { |
| 359 ShellWindowDelegateView* delegate_view = | 360 ShellWindowDelegateView* delegate_view = |
| 360 static_cast<ShellWindowDelegateView*>(window_widget_->widget_delegate()); | 361 static_cast<ShellWindowDelegateView*>(window_widget_->widget_delegate()); |
| 361 delegate_view->SetWindowTitle(title); | 362 delegate_view->SetWindowTitle(title); |
| 362 window_widget_->UpdateWindowTitle(); | 363 window_widget_->UpdateWindowTitle(); |
| 363 } | 364 } |
| 364 | 365 |
| 365 } // namespace content | 366 } // namespace content |
| OLD | NEW |