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

Side by Side Diff: chrome/browser/ui/webui/ntp/app_launcher_handler.h

Issue 10375021: Move Extension into extensions namespace (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Take 6 Created 8 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_UI_WEBUI_NTP_APP_LAUNCHER_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_NTP_APP_LAUNCHER_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_NTP_APP_LAUNCHER_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_NTP_APP_LAUNCHER_HANDLER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 19 matching lines...) Expand all
30 class AppLauncherHandler : public content::WebUIMessageHandler, 30 class AppLauncherHandler : public content::WebUIMessageHandler,
31 public ExtensionUninstallDialog::Delegate, 31 public ExtensionUninstallDialog::Delegate,
32 public ExtensionInstallUI::Delegate, 32 public ExtensionInstallUI::Delegate,
33 public content::NotificationObserver { 33 public content::NotificationObserver {
34 public: 34 public:
35 explicit AppLauncherHandler(ExtensionService* extension_service); 35 explicit AppLauncherHandler(ExtensionService* extension_service);
36 virtual ~AppLauncherHandler(); 36 virtual ~AppLauncherHandler();
37 37
38 // Populate a dictionary with the information from an extension. 38 // Populate a dictionary with the information from an extension.
39 static void CreateAppInfo( 39 static void CreateAppInfo(
40 const Extension* extension, 40 const extensions::Extension* extension,
41 const AppNotification* notification, 41 const AppNotification* notification,
42 ExtensionService* service, 42 ExtensionService* service,
43 base::DictionaryValue* value); 43 base::DictionaryValue* value);
44 44
45 // WebUIMessageHandler implementation. 45 // WebUIMessageHandler implementation.
46 virtual void RegisterMessages() OVERRIDE; 46 virtual void RegisterMessages() OVERRIDE;
47 47
48 // content::NotificationObserver 48 // content::NotificationObserver
49 virtual void Observe(int type, 49 virtual void Observe(int type,
50 const content::NotificationSource& source, 50 const content::NotificationSource& source,
51 const content::NotificationDetails& details) OVERRIDE; 51 const content::NotificationDetails& details) OVERRIDE;
52 52
53 // Populate the given dictionary with all installed app info. 53 // Populate the given dictionary with all installed app info.
54 void FillAppDictionary(base::DictionaryValue* value); 54 void FillAppDictionary(base::DictionaryValue* value);
55 55
56 // Create a dictionary value for the given extension. May return NULL, e.g. if 56 // Create a dictionary value for the given extension. May return NULL, e.g. if
57 // the given extension is not an app. If non-NULL, the caller assumes 57 // the given extension is not an app. If non-NULL, the caller assumes
58 // ownership of the pointer. 58 // ownership of the pointer.
59 base::DictionaryValue* GetAppInfo(const Extension* extension); 59 base::DictionaryValue* GetAppInfo(const extensions::Extension* extension);
60 60
61 // Populate the given dictionary with the web store promo content. 61 // Populate the given dictionary with the web store promo content.
62 void FillPromoDictionary(base::DictionaryValue* value); 62 void FillPromoDictionary(base::DictionaryValue* value);
63 63
64 // Callback for the "getApps" message. 64 // Callback for the "getApps" message.
65 void HandleGetApps(const base::ListValue* args); 65 void HandleGetApps(const base::ListValue* args);
66 66
67 // Callback for the "launchApp" message. 67 // Callback for the "launchApp" message.
68 void HandleLaunchApp(const base::ListValue* args); 68 void HandleLaunchApp(const base::ListValue* args);
69 69
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
201 // when the app is added to the page (via getAppsCallback or appAdded). 201 // when the app is added to the page (via getAppsCallback or appAdded).
202 std::string highlight_app_id_; 202 std::string highlight_app_id_;
203 203
204 // Hold state for favicon requests. 204 // Hold state for favicon requests.
205 CancelableRequestConsumerTSimple<AppInstallInfo*> favicon_consumer_; 205 CancelableRequestConsumerTSimple<AppInstallInfo*> favicon_consumer_;
206 206
207 DISALLOW_COPY_AND_ASSIGN(AppLauncherHandler); 207 DISALLOW_COPY_AND_ASSIGN(AppLauncherHandler);
208 }; 208 };
209 209
210 #endif // CHROME_BROWSER_UI_WEBUI_NTP_APP_LAUNCHER_HANDLER_H_ 210 #endif // CHROME_BROWSER_UI_WEBUI_NTP_APP_LAUNCHER_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/webui/inspect_ui.cc ('k') | chrome/browser/ui/webui/ntp/app_launcher_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698