| 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/shell_delegate_impl.h" | 5 #include "ash/shell/shell_delegate_impl.h" |
| 6 | 6 |
| 7 #include <limits> | 7 #include <limits> |
| 8 | 8 |
| 9 #include "ash/caps_lock_delegate_stub.h" | 9 #include "ash/caps_lock_delegate_stub.h" |
| 10 #include "ash/host/root_window_host_factory.h" | 10 #include "ash/host/root_window_host_factory.h" |
| 11 #include "ash/keyboard_controller_proxy_stub.h" | 11 #include "ash/keyboard_controller_proxy_stub.h" |
| 12 #include "ash/session_state_delegate.h" | 12 #include "ash/session_state_delegate.h" |
| 13 #include "ash/session_state_delegate_stub.h" | 13 #include "ash/session_state_delegate_stub.h" |
| 14 #include "ash/shell/context_menu.h" | 14 #include "ash/shell/context_menu.h" |
| 15 #include "ash/shell/example_factory.h" | 15 #include "ash/shell/example_factory.h" |
| 16 #include "ash/shell/launcher_delegate_impl.h" | 16 #include "ash/shell/launcher_delegate_impl.h" |
| 17 #include "ash/shell/toplevel_window.h" | 17 #include "ash/shell/toplevel_window.h" |
| 18 #include "ash/shell_window_ids.h" | 18 #include "ash/shell_window_ids.h" |
| 19 #include "ash/system/tray/default_system_tray_delegate.h" | 19 #include "ash/system/tray/default_system_tray_delegate.h" |
| 20 #include "ash/wm/window_util.h" | 20 #include "ash/wm/window_state.h" |
| 21 #include "base/message_loop/message_loop.h" | 21 #include "base/message_loop/message_loop.h" |
| 22 #include "ui/aura/window.h" | 22 #include "ui/aura/window.h" |
| 23 #include "ui/views/corewm/input_method_event_filter.h" | 23 #include "ui/views/corewm/input_method_event_filter.h" |
| 24 | 24 |
| 25 namespace ash { | 25 namespace ash { |
| 26 namespace shell { | 26 namespace shell { |
| 27 | 27 |
| 28 ShellDelegateImpl::ShellDelegateImpl() | 28 ShellDelegateImpl::ShellDelegateImpl() |
| 29 : watcher_(NULL), | 29 : watcher_(NULL), |
| 30 launcher_delegate_(NULL), | 30 launcher_delegate_(NULL), |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 create_params.can_resize = true; | 74 create_params.can_resize = true; |
| 75 create_params.can_maximize = true; | 75 create_params.can_maximize = true; |
| 76 ash::shell::ToplevelWindow::CreateToplevelWindow(create_params); | 76 ash::shell::ToplevelWindow::CreateToplevelWindow(create_params); |
| 77 } | 77 } |
| 78 | 78 |
| 79 void ShellDelegateImpl::ToggleFullscreen() { | 79 void ShellDelegateImpl::ToggleFullscreen() { |
| 80 ToggleMaximized(); | 80 ToggleMaximized(); |
| 81 } | 81 } |
| 82 | 82 |
| 83 void ShellDelegateImpl::ToggleMaximized() { | 83 void ShellDelegateImpl::ToggleMaximized() { |
| 84 aura::Window* window = ash::wm::GetActiveWindow(); | 84 wm::WindowState* window_state = wm::GetActiveWindowState(); |
| 85 if (window) | 85 if (window_state) |
| 86 ash::wm::ToggleMaximizedWindow(window); | 86 window_state->ToggleMaximized(); |
| 87 } | 87 } |
| 88 | 88 |
| 89 void ShellDelegateImpl::OpenFileManager(bool as_dialog) { | 89 void ShellDelegateImpl::OpenFileManager(bool as_dialog) { |
| 90 } | 90 } |
| 91 | 91 |
| 92 void ShellDelegateImpl::OpenCrosh() { | 92 void ShellDelegateImpl::OpenCrosh() { |
| 93 } | 93 } |
| 94 | 94 |
| 95 void ShellDelegateImpl::RestoreTab() { | 95 void ShellDelegateImpl::RestoreTab() { |
| 96 } | 96 } |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 217 RootWindowHostFactory* ShellDelegateImpl::CreateRootWindowHostFactory() { | 217 RootWindowHostFactory* ShellDelegateImpl::CreateRootWindowHostFactory() { |
| 218 return RootWindowHostFactory::Create(); | 218 return RootWindowHostFactory::Create(); |
| 219 } | 219 } |
| 220 | 220 |
| 221 base::string16 ShellDelegateImpl::GetProductName() const { | 221 base::string16 ShellDelegateImpl::GetProductName() const { |
| 222 return base::string16(); | 222 return base::string16(); |
| 223 } | 223 } |
| 224 | 224 |
| 225 } // namespace shell | 225 } // namespace shell |
| 226 } // namespace ash | 226 } // namespace ash |
| OLD | NEW |