Chromium Code Reviews| Index: chrome/browser/ui/webui/ntp/app_launcher_handler.h |
| diff --git a/chrome/browser/ui/webui/ntp/app_launcher_handler.h b/chrome/browser/ui/webui/ntp/app_launcher_handler.h |
| index 986d055b0cc7f35068c6fb3ca19ccd69bcd64755..ffa9c40805a8f9c4956c8ba965997fbd4c11572f 100644 |
| --- a/chrome/browser/ui/webui/ntp/app_launcher_handler.h |
| +++ b/chrome/browser/ui/webui/ntp/app_launcher_handler.h |
| @@ -8,6 +8,7 @@ |
| #include <set> |
| #include <string> |
| +#include "apps/metrics_names.h" |
| #include "base/memory/scoped_ptr.h" |
| #include "base/prefs/pref_change_registrar.h" |
| #include "chrome/browser/extensions/extension_uninstall_dialog.h" |
| @@ -68,47 +69,26 @@ class AppLauncherHandler : public content::WebUIMessageHandler, |
| // Populate the given dictionary with the web store promo content. |
| void FillPromoDictionary(base::DictionaryValue* value); |
| - // Callback for the "getApps" message. |
| - void HandleGetApps(const base::ListValue* args); |
| + // Callback for the "recordAppLaunchByURL" message. Takes an escaped URL and a |
| + // launch source (integer), and if the URL represents an app, records the |
| + // action for UMA. |
| + void HandleRecordAppLaunchByUrl(const base::ListValue* args); |
| - // Callback for the "launchApp" message. |
| + // Other registered message callbacks. |
| + void StopShowingAppLauncherPromo(const base::ListValue* args); |
| + void OnLearnMore(const base::ListValue* args); |
| + void HandleNotificationClose(const base::ListValue* args); |
| + void HandleSetNotificationsDisabled(const base::ListValue* args); |
| + void HandleGetApps(const base::ListValue* args); |
| void HandleLaunchApp(const base::ListValue* args); |
| - |
| - // Callback for the "setLaunchType" message. |
| void HandleSetLaunchType(const base::ListValue* args); |
| - |
| - // Callback for the "uninstallApp" message. |
| void HandleUninstallApp(const base::ListValue* args); |
| - |
| - // Callback for the "createAppShortcut" message. |
| void HandleCreateAppShortcut(const base::ListValue* args); |
| - |
| - // Callback for the "reorderApps" message. |
| void HandleReorderApps(const base::ListValue* args); |
| - |
| - // Callback for the "setPageIndex" message. |
| void HandleSetPageIndex(const base::ListValue* args); |
| - |
| - // Callback for the "saveAppPageName" message. |
| void HandleSaveAppPageName(const base::ListValue* args); |
| - |
| - // Callback for the "generateAppForLink" message. |
| void HandleGenerateAppForLink(const base::ListValue* args); |
|
Dan Beam
2013/06/27 00:59:31
nit: in theory these should mention which args wil
MAD
2013/06/27 21:43:35
Done.
|
| - // Callback for the "recordAppLaunchByURL" message. Takes an escaped URL and a |
| - // launch source (integer), and if the URL represents an app, records the |
| - // action for UMA. |
| - void HandleRecordAppLaunchByUrl(const base::ListValue* args); |
| - |
| - // Callback for "stopShowingAppLauncherPromo" message. |
| - void StopShowingAppLauncherPromo(const base::ListValue* args); |
| - |
| - // Callback for "closeNotification" message. |
| - void HandleNotificationClose(const base::ListValue* args); |
| - |
| - // Callback for "setNotificationsDisabled" message. |
| - void HandleSetNotificationsDisabled(const base::ListValue* args); |
| - |
| // Register app launcher preferences. |
| static void RegisterUserPrefs(user_prefs::PrefRegistrySyncable* registry); |
| @@ -122,6 +102,9 @@ class AppLauncherHandler : public content::WebUIMessageHandler, |
| // Records an app launch from the main view of the app list. |
| static void RecordAppListMainLaunch(const extensions::Extension* extension); |
| + static void RecordAppLauncherPromoHistogram( |
| + apps::AppLauncherPromoHistogramValues histogram); |
|
Ilya Sherman
2013/06/26 22:19:49
nit: Docs?
Ilya Sherman
2013/06/26 22:19:49
nit: "histogram" is a misleading variable name her
MAD
2013/06/27 21:43:35
Done.
MAD
2013/06/27 21:43:35
Done.
|
| + |
| private: |
| struct AppInstallInfo { |
| AppInstallInfo(); |