| 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 #ifndef EXTENSIONS_SHELL_BROWSER_SHELL_DESKTOP_CONTROLLER_H_ | 5 #ifndef EXTENSIONS_SHELL_BROWSER_SHELL_DESKTOP_CONTROLLER_H_ |
| 6 #define EXTENSIONS_SHELL_BROWSER_SHELL_DESKTOP_CONTROLLER_H_ | 6 #define EXTENSIONS_SHELL_BROWSER_SHELL_DESKTOP_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 58 #if defined(OS_CHROMEOS) | 58 #if defined(OS_CHROMEOS) |
| 59 public chromeos::PowerManagerClient::Observer, | 59 public chromeos::PowerManagerClient::Observer, |
| 60 public ui::DisplayConfigurator::Observer, | 60 public ui::DisplayConfigurator::Observer, |
| 61 #endif | 61 #endif |
| 62 public aura::WindowTreeHostObserver { | 62 public aura::WindowTreeHostObserver { |
| 63 public: | 63 public: |
| 64 ShellDesktopController(); | 64 ShellDesktopController(); |
| 65 virtual ~ShellDesktopController(); | 65 virtual ~ShellDesktopController(); |
| 66 | 66 |
| 67 // DesktopController: | 67 // DesktopController: |
| 68 virtual aura::WindowTreeHost* GetHost() OVERRIDE; | 68 virtual aura::WindowTreeHost* GetHost() override; |
| 69 virtual AppWindow* CreateAppWindow(content::BrowserContext* context, | 69 virtual AppWindow* CreateAppWindow(content::BrowserContext* context, |
| 70 const Extension* extension) OVERRIDE; | 70 const Extension* extension) override; |
| 71 virtual void AddAppWindow(aura::Window* window) OVERRIDE; | 71 virtual void AddAppWindow(aura::Window* window) override; |
| 72 virtual void CloseAppWindows() OVERRIDE; | 72 virtual void CloseAppWindows() override; |
| 73 | 73 |
| 74 // aura::client::WindowTreeClient overrides: | 74 // aura::client::WindowTreeClient overrides: |
| 75 virtual aura::Window* GetDefaultParent(aura::Window* context, | 75 virtual aura::Window* GetDefaultParent(aura::Window* context, |
| 76 aura::Window* window, | 76 aura::Window* window, |
| 77 const gfx::Rect& bounds) OVERRIDE; | 77 const gfx::Rect& bounds) override; |
| 78 | 78 |
| 79 #if defined(OS_CHROMEOS) | 79 #if defined(OS_CHROMEOS) |
| 80 // chromeos::PowerManagerClient::Observer overrides: | 80 // chromeos::PowerManagerClient::Observer overrides: |
| 81 virtual void PowerButtonEventReceived(bool down, | 81 virtual void PowerButtonEventReceived(bool down, |
| 82 const base::TimeTicks& timestamp) | 82 const base::TimeTicks& timestamp) |
| 83 OVERRIDE; | 83 override; |
| 84 | 84 |
| 85 // ui::DisplayConfigurator::Observer overrides. | 85 // ui::DisplayConfigurator::Observer overrides. |
| 86 virtual void OnDisplayModeChanged(const std::vector< | 86 virtual void OnDisplayModeChanged(const std::vector< |
| 87 ui::DisplayConfigurator::DisplayState>& displays) OVERRIDE; | 87 ui::DisplayConfigurator::DisplayState>& displays) override; |
| 88 #endif | 88 #endif |
| 89 | 89 |
| 90 // aura::WindowTreeHostObserver overrides: | 90 // aura::WindowTreeHostObserver overrides: |
| 91 virtual void OnHostCloseRequested(const aura::WindowTreeHost* host) OVERRIDE; | 91 virtual void OnHostCloseRequested(const aura::WindowTreeHost* host) override; |
| 92 | 92 |
| 93 protected: | 93 protected: |
| 94 // Creates and sets the aura clients and window manager stuff. Subclass may | 94 // Creates and sets the aura clients and window manager stuff. Subclass may |
| 95 // initialize different sets of the clients. | 95 // initialize different sets of the clients. |
| 96 virtual void InitWindowManager(); | 96 virtual void InitWindowManager(); |
| 97 | 97 |
| 98 private: | 98 private: |
| 99 // Creates the window that hosts the app. | 99 // Creates the window that hosts the app. |
| 100 void CreateRootWindow(); | 100 void CreateRootWindow(); |
| 101 | 101 |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 133 | 133 |
| 134 // The desktop supports a single app window. | 134 // The desktop supports a single app window. |
| 135 AppWindow* app_window_; // NativeAppWindow::Close() deletes this. | 135 AppWindow* app_window_; // NativeAppWindow::Close() deletes this. |
| 136 | 136 |
| 137 DISALLOW_COPY_AND_ASSIGN(ShellDesktopController); | 137 DISALLOW_COPY_AND_ASSIGN(ShellDesktopController); |
| 138 }; | 138 }; |
| 139 | 139 |
| 140 } // namespace extensions | 140 } // namespace extensions |
| 141 | 141 |
| 142 #endif // EXTENSIONS_SHELL_BROWSER_SHELL_DESKTOP_CONTROLLER_H_ | 142 #endif // EXTENSIONS_SHELL_BROWSER_SHELL_DESKTOP_CONTROLLER_H_ |
| OLD | NEW |