| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ |
| 6 #define CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 6 #define CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 163 // this to disable inactive rendering for the frame in the window the select | 163 // this to disable inactive rendering for the frame in the window the select |
| 164 // is opened within if necessary. | 164 // is opened within if necessary. |
| 165 virtual void RenderWidgetShowing(); | 165 virtual void RenderWidgetShowing(); |
| 166 | 166 |
| 167 // This is used when the contents is an extension that needs to route | 167 // This is used when the contents is an extension that needs to route |
| 168 // api calls through to the Browser process. | 168 // api calls through to the Browser process. |
| 169 virtual ExtensionFunctionDispatcher* CreateExtensionFunctionDispatcher( | 169 virtual ExtensionFunctionDispatcher* CreateExtensionFunctionDispatcher( |
| 170 RenderViewHost* render_view_host, | 170 RenderViewHost* render_view_host, |
| 171 const std::string& extension_id); | 171 const std::string& extension_id); |
| 172 | 172 |
| 173 // This is called when webkit tells us that it is done tabbing through | 173 // This is called when WebKit tells us that it is done tabbing through |
| 174 // controls on the page. Provides a way for TabContentsDelegates to handle | 174 // controls on the page. Provides a way for TabContentsDelegates to handle |
| 175 // this. Returns true if the delegate successfully handled it. | 175 // this. Returns true if the delegate successfully handled it. |
| 176 virtual bool TakeFocus(bool reverse); | 176 virtual bool TakeFocus(bool reverse); |
| 177 | 177 |
| 178 // Called by WebKit to notify that the page requested the tab hosting window |
| 179 // to be activated/deactivated (by calling window.focus()/blur()). |
| 180 virtual void Activate(); |
| 181 virtual void Deactivate(); |
| 182 |
| 178 // Changes the blocked state of the tab at |index|. TabContents are | 183 // Changes the blocked state of the tab at |index|. TabContents are |
| 179 // considered blocked while displaying a tab modal dialog. During that time | 184 // considered blocked while displaying a tab modal dialog. During that time |
| 180 // renderer host will ignore any UI interaction within TabContent outside of | 185 // renderer host will ignore any UI interaction within TabContent outside of |
| 181 // the currently displaying dialog. | 186 // the currently displaying dialog. |
| 182 virtual void SetTabContentBlocked(TabContents* contents, bool blocked); | 187 virtual void SetTabContentBlocked(TabContents* contents, bool blocked); |
| 183 | 188 |
| 184 // Notification that |tab_contents| has gained focus. | 189 // Notification that |tab_contents| has gained focus. |
| 185 virtual void TabContentsFocused(TabContents* tab_content); | 190 virtual void TabContentsFocused(TabContents* tab_content); |
| 186 | 191 |
| 187 // Return much extra vertical space should be allotted to the | 192 // Return much extra vertical space should be allotted to the |
| (...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 270 // Notifies the delegate that something has changed about what content the | 275 // Notifies the delegate that something has changed about what content the |
| 271 // TabContents is displaying. Currently this is only fired when displaying | 276 // TabContents is displaying. Currently this is only fired when displaying |
| 272 // PDF using the internal PDF plugin. | 277 // PDF using the internal PDF plugin. |
| 273 virtual void ContentTypeChanged(TabContents* source); | 278 virtual void ContentTypeChanged(TabContents* source); |
| 274 | 279 |
| 275 protected: | 280 protected: |
| 276 virtual ~TabContentsDelegate(); | 281 virtual ~TabContentsDelegate(); |
| 277 }; | 282 }; |
| 278 | 283 |
| 279 #endif // CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ | 284 #endif // CHROME_BROWSER_TAB_CONTENTS_TAB_CONTENTS_DELEGATE_H_ |
| OLD | NEW |