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_EXTENSIONS_BROWSER_EXTENSION_WINDOW_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_BROWSER_EXTENSION_WINDOW_CONTROLLER_H_ |
6 #define CHROME_BROWSER_EXTENSIONS_BROWSER_EXTENSION_WINDOW_CONTROLLER_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_BROWSER_EXTENSION_WINDOW_CONTROLLER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "chrome/browser/extensions/extension_window_controller.h" | 9 #include "chrome/browser/extensions/extension_window_controller.h" |
10 | 10 |
11 class Browser; | 11 class Browser; |
12 | 12 |
13 class BrowserExtensionWindowController : public ExtensionWindowController { | 13 class BrowserExtensionWindowController : public ExtensionWindowController { |
14 public: | 14 public: |
15 explicit BrowserExtensionWindowController(Browser* browser); | 15 explicit BrowserExtensionWindowController(Browser* browser); |
16 | 16 |
17 // ExtensionWindowController implementation. | 17 // ExtensionWindowController implementation. |
18 virtual int GetWindowId() const OVERRIDE; | 18 virtual int GetWindowId() const OVERRIDE; |
19 virtual std::string GetWindowTypeText() const OVERRIDE; | 19 virtual std::string GetWindowTypeText() const OVERRIDE; |
20 virtual base::DictionaryValue* CreateWindowValue() const OVERRIDE; | 20 virtual base::DictionaryValue* CreateWindowValue() const OVERRIDE; |
21 virtual base::DictionaryValue* CreateWindowValueWithTabs() const OVERRIDE; | 21 virtual base::DictionaryValue* CreateWindowValueWithTabs() const OVERRIDE; |
22 virtual bool CanClose(Reason* reason) const OVERRIDE; | 22 virtual bool CanClose(Reason* reason) const OVERRIDE; |
23 virtual void SetFullscreenMode(bool is_fullscreen, | 23 virtual void SetFullscreenMode(bool is_fullscreen, |
24 const GURL& extension_url) const OVERRIDE; | 24 const GURL& extension_url) const OVERRIDE; |
25 virtual Browser* GetBrowser() const OVERRIDE; | 25 virtual Browser* GetBrowser() const OVERRIDE; |
26 | 26 |
| 27 protected: |
| 28 // Extension/window visibility and ownership is window-specific, subclasses |
| 29 // need to define this behavior. |
| 30 virtual bool IsVisibleToExtension(const Extension* extension) const OVERRIDE; |
| 31 |
27 private: | 32 private: |
28 Browser* browser_; | 33 Browser* browser_; |
29 | 34 |
30 DISALLOW_COPY_AND_ASSIGN(BrowserExtensionWindowController); | 35 DISALLOW_COPY_AND_ASSIGN(BrowserExtensionWindowController); |
31 }; | 36 }; |
32 | 37 |
33 #endif // CHROME_BROWSER_EXTENSIONS_BROWSER_EXTENSION_WINDOW_CONTROLLER_H_ | 38 #endif // CHROME_BROWSER_EXTENSIONS_BROWSER_EXTENSION_WINDOW_CONTROLLER_H_ |
OLD | NEW |