diff options
author | sidchat@google.com <sidchat@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-07-10 16:41:27 +0000 |
---|---|---|
committer | sidchat@google.com <sidchat@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-07-10 16:41:27 +0000 |
commit | 5c4266928220b850dc96474953f0b3a29739e0d3 (patch) | |
tree | 0981198815b7d83ab1ccdb0fc358db8637618c05 /chrome/browser/extensions/extension_tabs_module.h | |
parent | 479d5bc48969f6de924471de27638409db848229 (diff) | |
download | chromium_src-5c4266928220b850dc96474953f0b3a29739e0d3.zip chromium_src-5c4266928220b850dc96474953f0b3a29739e0d3.tar.gz chromium_src-5c4266928220b850dc96474953f0b3a29739e0d3.tar.bz2 |
Add getLanguage function to tab extension.
BUG=none
TEST=enable extensions using the toolstip.html code (added with this CL) and load pages in different languages. The corresponding language should appear in the bottom left after the page is loadedm or when the button is clicked, or when you navigate back to that tab after visiting some other tab.
Review URL: http://codereview.chromium.org/150062
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@20378 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_tabs_module.h')
-rw-r--r-- | chrome/browser/extensions/extension_tabs_module.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/chrome/browser/extensions/extension_tabs_module.h b/chrome/browser/extensions/extension_tabs_module.h index cb8b3d3..1b7c307 100644 --- a/chrome/browser/extensions/extension_tabs_module.h +++ b/chrome/browser/extensions/extension_tabs_module.h @@ -8,6 +8,8 @@ #include <string> #include "chrome/browser/extensions/extension_function.h" +#include "chrome/common/notification_service.h" +#include "chrome/common/notification_registrar.h" class Browser; class DictionaryValue; @@ -86,5 +88,15 @@ class MoveTabFunction : public SyncExtensionFunction { class RemoveTabFunction : public SyncExtensionFunction { virtual bool RunImpl(); }; +class GetTabLanguageFunction : public AsyncExtensionFunction, + public NotificationObserver { + virtual bool RunImpl(); + + private: + virtual void Observe(NotificationType type, + const NotificationSource& source, + const NotificationDetails& details); + NotificationRegistrar registrar_; +}; #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_TABS_MODULE_H__ |