| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_EXTENSION_POPUP_HOST_H_ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_POPUP_HOST_H_ |
| 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_POPUP_HOST_H_ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_POPUP_HOST_H_ |
| 7 | 7 |
| 8 #include "base/scoped_ptr.h" | 8 #include "base/scoped_ptr.h" |
| 9 #include "build/build_config.h" | 9 #include "build/build_config.h" |
| 10 #if defined(TOOLKIT_VIEWS) | 10 #if defined(TOOLKIT_VIEWS) |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 virtual void BubbleBrowserWindowMoved(BrowserBubble* bubble); | 67 virtual void BubbleBrowserWindowMoved(BrowserBubble* bubble); |
| 68 | 68 |
| 69 // Called with the Browser Window that this bubble is attached to is | 69 // Called with the Browser Window that this bubble is attached to is |
| 70 // about to close. | 70 // about to close. |
| 71 virtual void BubbleBrowserWindowClosing(BrowserBubble* bubble); | 71 virtual void BubbleBrowserWindowClosing(BrowserBubble* bubble); |
| 72 | 72 |
| 73 // Called when the bubble became active / got focus. | 73 // Called when the bubble became active / got focus. |
| 74 virtual void BubbleGotFocus(BrowserBubble* bubble); | 74 virtual void BubbleGotFocus(BrowserBubble* bubble); |
| 75 | 75 |
| 76 // Called when the bubble became inactive / lost focus. | 76 // Called when the bubble became inactive / lost focus. |
| 77 virtual void BubbleLostFocus(BrowserBubble* bubble); | 77 virtual void BubbleLostFocus(BrowserBubble* bubble, |
| 78 gfx::NativeView focused_view); |
| 78 #endif // defined(TOOLKIT_VIEWS) | 79 #endif // defined(TOOLKIT_VIEWS) |
| 79 | 80 |
| 80 // NotificationObserver implementation. | 81 // NotificationObserver implementation. |
| 81 virtual void Observe(NotificationType type, | 82 virtual void Observe(NotificationType type, |
| 82 const NotificationSource& source, | 83 const NotificationSource& source, |
| 83 const NotificationDetails& details); | 84 const NotificationDetails& details); |
| 84 | 85 |
| 85 private: | 86 private: |
| 86 #if defined(TOOLKIT_VIEWS) | 87 #if defined(TOOLKIT_VIEWS) |
| 87 // A popup view that is anchored to and owned by this ExtensionHost. However, | 88 // A popup view that is anchored to and owned by this ExtensionHost. However, |
| 88 // the popup contains its own separate ExtensionHost | 89 // the popup contains its own separate ExtensionHost |
| 89 ExtensionPopup* child_popup_; | 90 ExtensionPopup* child_popup_; |
| 90 #endif | 91 #endif |
| 91 | 92 |
| 92 NotificationRegistrar registrar_; | 93 NotificationRegistrar registrar_; |
| 93 | 94 |
| 94 // Non-owning pointer to the delegate for this host. | 95 // Non-owning pointer to the delegate for this host. |
| 95 PopupDelegate* delegate_; | 96 PopupDelegate* delegate_; |
| 96 | 97 |
| 97 // Boolean value used to ensure that the host only registers for event | 98 // Boolean value used to ensure that the host only registers for event |
| 98 // notifications once. | 99 // notifications once. |
| 99 bool listeners_registered_; | 100 bool listeners_registered_; |
| 100 | 101 |
| 101 DISALLOW_COPY_AND_ASSIGN(ExtensionPopupHost); | 102 DISALLOW_COPY_AND_ASSIGN(ExtensionPopupHost); |
| 102 }; | 103 }; |
| 103 | 104 |
| 104 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_POPUP_HOST_H_ | 105 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_POPUP_HOST_H_ |
| OLD | NEW |