| 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 #ifndef CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ | 5 #ifndef CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ |
| 6 #define CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ | 6 #define CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ |
| 7 | 7 |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "chrome/browser/extensions/extension_function_dispatcher.h" | 9 #include "chrome/browser/extensions/extension_function_dispatcher.h" |
| 10 #include "chrome/browser/extensions/extension_keybinding_registry.h" | 10 #include "chrome/browser/extensions/extension_keybinding_registry.h" |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 // is on startup and from within UpdateWindowTitle(). | 96 // is on startup and from within UpdateWindowTitle(). |
| 97 virtual string16 GetTitle() const; | 97 virtual string16 GetTitle() const; |
| 98 | 98 |
| 99 // Call to notify ShellRegistry and delete the window. Subclasses should | 99 // Call to notify ShellRegistry and delete the window. Subclasses should |
| 100 // invoke this method instead of using "delete this". | 100 // invoke this method instead of using "delete this". |
| 101 void OnNativeClose(); | 101 void OnNativeClose(); |
| 102 | 102 |
| 103 // Save the window position in the prefs. | 103 // Save the window position in the prefs. |
| 104 virtual void SaveWindowPosition(); | 104 virtual void SaveWindowPosition(); |
| 105 | 105 |
| 106 // Sends an update message with the current bounds to the renderer. |
| 107 void SendBoundsUpdate(); |
| 108 |
| 106 protected: | 109 protected: |
| 107 ShellWindow(Profile* profile, | 110 ShellWindow(Profile* profile, |
| 108 const extensions::Extension* extension); | 111 const extensions::Extension* extension); |
| 109 virtual ~ShellWindow(); | 112 virtual ~ShellWindow(); |
| 110 | 113 |
| 111 private: | 114 private: |
| 112 // PlatformAppBrowserTest needs access to web_contents() | 115 // PlatformAppBrowserTest needs access to web_contents() |
| 113 friend class extensions::PlatformAppBrowserTest; | 116 friend class extensions::PlatformAppBrowserTest; |
| 114 | 117 |
| 115 // Instantiates a platform-specific ShellWindow subclass (one implementation | 118 // Instantiates a platform-specific ShellWindow subclass (one implementation |
| (...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 204 | 207 |
| 205 // Used for loading app_icon_. | 208 // Used for loading app_icon_. |
| 206 scoped_ptr<ImageLoadingTracker> app_icon_loader_; | 209 scoped_ptr<ImageLoadingTracker> app_icon_loader_; |
| 207 | 210 |
| 208 scoped_ptr<NativeShellWindow> native_window_; | 211 scoped_ptr<NativeShellWindow> native_window_; |
| 209 | 212 |
| 210 DISALLOW_COPY_AND_ASSIGN(ShellWindow); | 213 DISALLOW_COPY_AND_ASSIGN(ShellWindow); |
| 211 }; | 214 }; |
| 212 | 215 |
| 213 #endif // CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ | 216 #endif // CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ |
| OLD | NEW |