diff options
author | rpaquay@chromium.org <rpaquay@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-01-18 23:00:33 +0000 |
---|---|---|
committer | rpaquay@chromium.org <rpaquay@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-01-18 23:00:33 +0000 |
commit | 07ad9628854db580899ba0187f4bb51bf10e9572 (patch) | |
tree | d63f14fc6b2fbe3349d1dd6128e5d1c744d4a943 /chrome/browser/extensions/api/tabs/tabs_api.h | |
parent | 67255b68fc6d15dd5ede9e851de71533bf1aac69 (diff) | |
download | chromium_src-07ad9628854db580899ba0187f4bb51bf10e9572.zip chromium_src-07ad9628854db580899ba0187f4bb51bf10e9572.tar.gz chromium_src-07ad9628854db580899ba0187f4bb51bf10e9572.tar.bz2 |
Record histogram of extension API usage
We create one histogram per function name and record each call.
BUG=37963
TBR=sky@chromium.org (for mechanical changes in a bunch of chrome/ subdirs)
Review URL: https://chromiumcodereview.appspot.com/11577015
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@177787 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/api/tabs/tabs_api.h')
-rw-r--r-- | chrome/browser/extensions/api/tabs/tabs_api.h | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/chrome/browser/extensions/api/tabs/tabs_api.h b/chrome/browser/extensions/api/tabs/tabs_api.h index db362cc..71d7d49 100644 --- a/chrome/browser/extensions/api/tabs/tabs_api.h +++ b/chrome/browser/extensions/api/tabs/tabs_api.h @@ -45,22 +45,22 @@ class PlatformBitmap; class WindowsGetFunction : public SyncExtensionFunction { virtual ~WindowsGetFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("windows.get") + DECLARE_EXTENSION_FUNCTION("windows.get", WINDOWS_GET) }; class WindowsGetCurrentFunction : public SyncExtensionFunction { virtual ~WindowsGetCurrentFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("windows.getCurrent") + DECLARE_EXTENSION_FUNCTION("windows.getCurrent", WINDOWS_GETCURRENT) }; class WindowsGetLastFocusedFunction : public SyncExtensionFunction { virtual ~WindowsGetLastFocusedFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("windows.getLastFocused") + DECLARE_EXTENSION_FUNCTION("windows.getLastFocused", WINDOWS_GETLASTFOCUSED) }; class WindowsGetAllFunction : public SyncExtensionFunction { virtual ~WindowsGetAllFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("windows.getAll") + DECLARE_EXTENSION_FUNCTION("windows.getAll", WINDOWS_GETALL) }; class WindowsCreateFunction : public SyncExtensionFunction { virtual ~WindowsCreateFunction() {} @@ -74,59 +74,59 @@ class WindowsCreateFunction : public SyncExtensionFunction { bool ShouldOpenIncognitoWindow(const base::DictionaryValue* args, std::vector<GURL>* urls, bool* is_error); - DECLARE_EXTENSION_FUNCTION_NAME("windows.create") + DECLARE_EXTENSION_FUNCTION("windows.create", WINDOWS_CREATE) }; class WindowsUpdateFunction : public SyncExtensionFunction { virtual ~WindowsUpdateFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("windows.update") + DECLARE_EXTENSION_FUNCTION("windows.update", WINDOWS_UPDATE) }; class WindowsRemoveFunction : public SyncExtensionFunction { virtual ~WindowsRemoveFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("windows.remove") + DECLARE_EXTENSION_FUNCTION("windows.remove", WINDOWS_REMOVE) }; // Tabs class TabsGetFunction : public SyncExtensionFunction { virtual ~TabsGetFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.get") + DECLARE_EXTENSION_FUNCTION("tabs.get", TABS_GET) }; class TabsGetCurrentFunction : public SyncExtensionFunction { virtual ~TabsGetCurrentFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.getCurrent") + DECLARE_EXTENSION_FUNCTION("tabs.getCurrent", TABS_GETCURRENT) }; class TabsGetSelectedFunction : public SyncExtensionFunction { virtual ~TabsGetSelectedFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.getSelected") + DECLARE_EXTENSION_FUNCTION("tabs.getSelected", TABS_GETSELECTED) }; class TabsGetAllInWindowFunction : public SyncExtensionFunction { virtual ~TabsGetAllInWindowFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.getAllInWindow") + DECLARE_EXTENSION_FUNCTION("tabs.getAllInWindow", TABS_GETALLINWINDOW) }; class TabsQueryFunction : public SyncExtensionFunction { virtual ~TabsQueryFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.query") + DECLARE_EXTENSION_FUNCTION("tabs.query", TABS_QUERY) }; class TabsCreateFunction : public SyncExtensionFunction { virtual ~TabsCreateFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.create") + DECLARE_EXTENSION_FUNCTION("tabs.create", TABS_CREATE) }; class TabsDuplicateFunction : public SyncExtensionFunction { virtual ~TabsDuplicateFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.duplicate") + DECLARE_EXTENSION_FUNCTION("tabs.duplicate", TABS_DUPLICATE) }; class TabsHighlightFunction : public SyncExtensionFunction { virtual ~TabsHighlightFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.highlight") + DECLARE_EXTENSION_FUNCTION("tabs.highlight", TABS_HIGHLIGHT) }; class TabsUpdateFunction : public AsyncExtensionFunction { public: @@ -148,22 +148,22 @@ class TabsUpdateFunction : public AsyncExtensionFunction { const GURL& on_url, const ListValue& script_result); - DECLARE_EXTENSION_FUNCTION_NAME("tabs.update") + DECLARE_EXTENSION_FUNCTION("tabs.update", TABS_UPDATE) }; class TabsMoveFunction : public SyncExtensionFunction { virtual ~TabsMoveFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.move") + DECLARE_EXTENSION_FUNCTION("tabs.move", TABS_MOVE) }; class TabsReloadFunction : public SyncExtensionFunction { virtual ~TabsReloadFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.reload") + DECLARE_EXTENSION_FUNCTION("tabs.reload", TABS_RELOAD) }; class TabsRemoveFunction : public SyncExtensionFunction { virtual ~TabsRemoveFunction() {} virtual bool RunImpl() OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.remove") + DECLARE_EXTENSION_FUNCTION("tabs.remove", TABS_REMOVE) }; class TabsDetectLanguageFunction : public AsyncExtensionFunction, public content::NotificationObserver { @@ -176,7 +176,7 @@ class TabsDetectLanguageFunction : public AsyncExtensionFunction, const content::NotificationDetails& details) OVERRIDE; void GotLanguage(const std::string& language); content::NotificationRegistrar registrar_; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.detectLanguage") + DECLARE_EXTENSION_FUNCTION("tabs.detectLanguage", TABS_DETECTLANGUAGE) }; class TabsCaptureVisibleTabFunction : public AsyncExtensionFunction, public content::NotificationObserver { @@ -212,7 +212,7 @@ class TabsCaptureVisibleTabFunction : public AsyncExtensionFunction, // Quality setting to use when encoding jpegs. Set in RunImpl(). int image_quality_; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.captureVisibleTab") + DECLARE_EXTENSION_FUNCTION("tabs.captureVisibleTab", TABS_CAPTUREVISIBLETAB) }; // Implement API call tabs.executeScript and tabs.insertCSS. @@ -277,14 +277,14 @@ class TabsExecuteScriptFunction : public ExecuteCodeInTabFunction { const GURL& on_url, const ListValue& script_result) OVERRIDE; - DECLARE_EXTENSION_FUNCTION_NAME("tabs.executeScript") + DECLARE_EXTENSION_FUNCTION("tabs.executeScript", TABS_EXECUTESCRIPT) }; class TabsInsertCSSFunction : public ExecuteCodeInTabFunction { private: virtual ~TabsInsertCSSFunction() {} - DECLARE_EXTENSION_FUNCTION_NAME("tabs.insertCSS") + DECLARE_EXTENSION_FUNCTION("tabs.insertCSS", TABS_INSERTCSS) }; #endif // CHROME_BROWSER_EXTENSIONS_API_TABS_TABS_API_H_ |