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_TAB_CONTENTS_TAB_CONTENTS_WRAPPER_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_UI_TAB_CONTENTS_TAB_CONTENTS_WRAPPER_DELEGATE_H_ |
6 #define CHROME_BROWSER_UI_TAB_CONTENTS_TAB_CONTENTS_WRAPPER_DELEGATE_H_ | 6 #define CHROME_BROWSER_UI_TAB_CONTENTS_TAB_CONTENTS_WRAPPER_DELEGATE_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 | 10 |
11 class TabContentsWrapper; | 11 class TabContentsWrapper; |
12 struct WebApplicationInfo; | 12 struct WebApplicationInfo; |
13 | 13 |
14 // Objects implement this interface to get notified about changes in the | 14 // Objects implement this interface to get notified about changes in the |
15 // TabContentsWrapper and to provide necessary functionality. | 15 // TabContentsWrapper and to provide necessary functionality. |
16 class TabContentsWrapperDelegate { | 16 class TabContentsWrapperDelegate { |
17 public: | 17 public: |
18 // Notification that a user's request to install an application has completed. | 18 // Notification that a user's request to install an application has completed. |
19 virtual void OnDidGetApplicationInfo(TabContentsWrapper* source, | 19 virtual void OnDidGetApplicationInfo(TabContentsWrapper* source, |
20 int32 page_id); | 20 int32 page_id); |
21 | 21 |
22 // Notification when an application programmatically requests installation. | 22 // Notification when an application programmatically requests installation. |
23 virtual void OnInstallApplication(TabContentsWrapper* source, | 23 virtual void OnInstallApplication(TabContentsWrapper* source, |
24 const WebApplicationInfo& app_info); | 24 const WebApplicationInfo& app_info); |
25 | 25 |
26 virtual void SwapTabContents(TabContentsWrapper* old_tc, | 26 virtual void SwapTabContents(TabContentsWrapper* old_tc, |
27 TabContentsWrapper* new_tc) = 0; | 27 TabContentsWrapper* new_tc) = 0; |
28 | 28 |
29 // Invoked prior to the TabContentsWrapper showing a constrained window. | |
30 virtual void WillShowConstrainedWindow(TabContentsWrapper* source); | |
31 | |
32 // Returns true if constrained windows should be focused. Default is true. | |
33 virtual bool ShouldFocusConstrainedWindow(); | |
34 | |
35 // Changes the blocked state of |wrapper|. TabContents are considered blocked | |
36 // while displaying a tab modal dialog. During that time renderer host will | |
37 // ignore any UI interaction within TabContent outside of the currently | |
38 // displaying dialog. | |
39 virtual void SetTabContentBlocked(TabContentsWrapper* wrapper, bool blocked); | |
Avi (use Gerrit)
2011/09/28 00:16:50
Are these for the constrained window stuff? (Looks
| |
40 | |
29 protected: | 41 protected: |
30 virtual ~TabContentsWrapperDelegate(); | 42 virtual ~TabContentsWrapperDelegate(); |
31 }; | 43 }; |
32 | 44 |
33 #endif // CHROME_BROWSER_UI_TAB_CONTENTS_TAB_CONTENTS_WRAPPER_DELEGATE_H_ | 45 #endif // CHROME_BROWSER_UI_TAB_CONTENTS_TAB_CONTENTS_WRAPPER_DELEGATE_H_ |
OLD | NEW |