Index: chrome/browser/ui/webui/ntp/new_tab_page_handler.h |
diff --git a/chrome/browser/ui/webui/ntp/new_tab_page_handler.h b/chrome/browser/ui/webui/ntp/new_tab_page_handler.h |
index 9db1182b29ac50043398a08fffad0b3b0ca524fa..34cc843949a55e76f64fd92bb6441f6c1f94be21 100644 |
--- a/chrome/browser/ui/webui/ntp/new_tab_page_handler.h |
+++ b/chrome/browser/ui/webui/ntp/new_tab_page_handler.h |
@@ -5,6 +5,7 @@ |
#ifndef CHROME_BROWSER_UI_WEBUI_NTP_NEW_TAB_PAGE_HANDLER_H_ |
#define CHROME_BROWSER_UI_WEBUI_NTP_NEW_TAB_PAGE_HANDLER_H_ |
+#include "base/memory/weak_ptr.h" |
#include "base/values.h" |
#include "chrome/common/chrome_notification_types.h" |
#include "content/public/browser/web_ui_message_handler.h" |
@@ -15,7 +16,8 @@ class Profile; |
// Handler for general New Tab Page functionality that does not belong in a |
// more specialized handler. |
-class NewTabPageHandler : public content::WebUIMessageHandler { |
+class NewTabPageHandler : public content::WebUIMessageHandler, |
+ public base::SupportsWeakPtr<NewTabPageHandler> { |
public: |
NewTabPageHandler(); |
@@ -55,6 +57,12 @@ class NewTabPageHandler : public content::WebUIMessageHandler { |
// Callback for "logTimeToClick". |
void HandleLogTimeToClick(const base::ListValue* args); |
+ // Callback for the "getShouldShowApps" message. |
+ void HandleGetShouldShowApps(const base::ListValue* args); |
+ |
+ // Callback from extensions::UpdateIsAppLauncherEnabled(). |
+ void GotIsAppLauncherEnabled(bool is_enabled); |
+ |
// Tracks the number of times the user has switches pages (for UMA). |
size_t page_switch_count_; |