Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(679)

Unified Diff: chrome/browser/ui/webui/ntp/app_launcher_handler.h

Issue 11953021: Don't show the apps page on the NTP if the app launcher is installed. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: make shouldShowApps a pref Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 c68a176ecace1cfc5b772f8c320638ef6c33546c..2294e3b6982644abc7650caa6e4b22d8c385fdda 100644
--- a/chrome/browser/ui/webui/ntp/app_launcher_handler.h
+++ b/chrome/browser/ui/webui/ntp/app_launcher_handler.h
@@ -31,6 +31,24 @@ namespace extensions {
class AppNotification;
}
+class AppsPagePresenceHandler : public content::WebUIMessageHandler {
Evan Stade 2013/01/23 23:34:24 why is this separate from AppLauncherHandler?
jeremya 2013/01/24 02:40:04 Because AppLauncherHandler isn't always present. P
+ public:
+ AppsPagePresenceHandler();
+ virtual ~AppsPagePresenceHandler();
+
+ // WebUIMessageHandler implementation.
+ virtual void RegisterMessages() OVERRIDE;
+
+ // Callback for the "getShouldShowApps" message.
+ void HandleGetShouldShowApps(const base::ListValue* args);
+
+ private:
+ // Callback for extensions::GetIsAppLauncherEnabled().
+ void GotIsAppLauncherEnabled(bool is_enabled);
+
+ DISALLOW_COPY_AND_ASSIGN(AppsPagePresenceHandler);
+};
+
// The handler for Javascript messages related to the "apps" view.
class AppLauncherHandler : public content::WebUIMessageHandler,
public ExtensionUninstallDialog::Delegate,

Powered by Google App Engine
This is Rietveld 408576698