| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_CONSTRAINED_WINDOW_TAB_HELPER_H_ | 5 #ifndef CHROME_BROWSER_UI_CONSTRAINED_WINDOW_TAB_HELPER_H_ |
| 6 #define CHROME_BROWSER_UI_CONSTRAINED_WINDOW_TAB_HELPER_H_ | 6 #define CHROME_BROWSER_UI_CONSTRAINED_WINDOW_TAB_HELPER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <deque> | 9 #include <deque> |
| 10 | 10 |
| 11 #include "content/public/browser/web_contents_observer.h" | 11 #include "content/public/browser/web_contents_observer.h" |
| 12 | 12 |
| 13 class ConstrainedWindow; | 13 class ConstrainedWindow; |
| 14 class ConstrainedWindowTabHelperDelegate; | 14 class ConstrainedWindowTabHelperDelegate; |
| 15 class TabContentsWrapper; | 15 class TabContents; |
| 16 typedef TabContents TabContentsWrapper; |
| 16 | 17 |
| 17 // Per-tab class to manage constrained windows. | 18 // Per-tab class to manage constrained windows. |
| 18 class ConstrainedWindowTabHelper : public content::WebContentsObserver { | 19 class ConstrainedWindowTabHelper : public content::WebContentsObserver { |
| 19 public: | 20 public: |
| 20 explicit ConstrainedWindowTabHelper(TabContentsWrapper* tab_contents); | 21 explicit ConstrainedWindowTabHelper(TabContentsWrapper* tab_contents); |
| 21 virtual ~ConstrainedWindowTabHelper(); | 22 virtual ~ConstrainedWindowTabHelper(); |
| 22 | 23 |
| 23 ConstrainedWindowTabHelperDelegate* delegate() const { return delegate_; } | 24 ConstrainedWindowTabHelperDelegate* delegate() const { return delegate_; } |
| 24 void set_delegate(ConstrainedWindowTabHelperDelegate* d) { delegate_ = d; } | 25 void set_delegate(ConstrainedWindowTabHelperDelegate* d) { delegate_ = d; } |
| 25 | 26 |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 // Delegate for notifying our owner about stuff. Not owned by us. | 66 // Delegate for notifying our owner about stuff. Not owned by us. |
| 66 ConstrainedWindowTabHelperDelegate* delegate_; | 67 ConstrainedWindowTabHelperDelegate* delegate_; |
| 67 | 68 |
| 68 // All active constrained windows. | 69 // All active constrained windows. |
| 69 ConstrainedWindowList child_windows_; | 70 ConstrainedWindowList child_windows_; |
| 70 | 71 |
| 71 DISALLOW_COPY_AND_ASSIGN(ConstrainedWindowTabHelper); | 72 DISALLOW_COPY_AND_ASSIGN(ConstrainedWindowTabHelper); |
| 72 }; | 73 }; |
| 73 | 74 |
| 74 #endif // CHROME_BROWSER_UI_CONSTRAINED_WINDOW_TAB_HELPER_H_ | 75 #endif // CHROME_BROWSER_UI_CONSTRAINED_WINDOW_TAB_HELPER_H_ |
| OLD | NEW |