summaryrefslogtreecommitdiffstats
path: root/chrome/browser/extensions/extension_function_dispatcher.h
diff options
context:
space:
mode:
authorrafaelw@chromium.org <rafaelw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-04-15 19:05:07 +0000
committerrafaelw@chromium.org <rafaelw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-04-15 19:05:07 +0000
commit9aa2eaaeadd97c8ed9018a63ca701a42eb731c9b (patch)
treeedffb1492a5c26585cd0c666e8eea312f719c25e /chrome/browser/extensions/extension_function_dispatcher.h
parent3cf7b304ca304dde742f6362a90dbafad5986bc9 (diff)
downloadchromium_src-9aa2eaaeadd97c8ed9018a63ca701a42eb731c9b.zip
chromium_src-9aa2eaaeadd97c8ed9018a63ca701a42eb731c9b.tar.gz
chromium_src-9aa2eaaeadd97c8ed9018a63ca701a42eb731c9b.tar.bz2
Add ExtensionFunctionDispatcher::Delegate::GetAssociatedTabContents.
Following work from: http://codereview.chromium.org/1521032/show, based on comments from aa here: http://codereview.chromium.org/1521032/diff/4002/9004#newcode639 BUG=40428 TEST=All tests should pass Review URL: http://codereview.chromium.org/1627024 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@44680 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_function_dispatcher.h')
-rw-r--r--chrome/browser/extensions/extension_function_dispatcher.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/chrome/browser/extensions/extension_function_dispatcher.h b/chrome/browser/extensions/extension_function_dispatcher.h
index fc50c17..8f1f6d9 100644
--- a/chrome/browser/extensions/extension_function_dispatcher.h
+++ b/chrome/browser/extensions/extension_function_dispatcher.h
@@ -21,6 +21,7 @@ class ExtensionHost;
class Profile;
class RenderViewHost;
class RenderViewHostDelegate;
+class TabContents;
class Value;
// A factory function for creating new ExtensionFunction instances.
@@ -48,6 +49,12 @@ class ExtensionFunctionDispatcher {
return NULL;
}
+ // Asks the delegate for any relevant TabContents associated with this
+ // context. For example, the TabContents in which an infobar or
+ // chrome-extension://<id> URL are being shown. Callers must check for a
+ // NULL return value (as in the case of a background page).
+ virtual TabContents* associated_tab_contents() = 0;
+
protected:
virtual ~Delegate() {}
};