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

Unified Diff: chrome/browser/extensions/extension_service.h

Issue 6880089: Don't hold the installed app in BrowserProcessRenderHost, since that's in content layer now. Ext... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 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/extensions/extension_service.h
===================================================================
--- chrome/browser/extensions/extension_service.h (revision 82344)
+++ chrome/browser/extensions/extension_service.h (working copy)
@@ -157,6 +157,13 @@
// Returns whether the URL is from either a hosted or packaged app.
bool IsInstalledApp(const GURL& url);
+ // Associates a renderer process with the given installed app.
+ void SetInstalledAppForRenderer(const Extension* app, int renderer_child_id);
Charlie Reis 2011/04/21 00:25:12 Let's swap these arguments so it's more like a tra
jam 2011/04/21 06:52:19 Done.
+
+ // If the renderer is hosting an installed app, returns it, otherwise returns
+ // NULL.
+ const Extension* GetInstalledAppForRenderer(int renderer_child_id);
+
// Attempts to uninstall an extension from a given ExtensionService. Returns
// true iff the target extension exists.
static bool UninstallExtensionHelper(ExtensionService* extensions_service,
@@ -562,6 +569,11 @@
// The map of extension IDs to their runtime data.
ExtensionRuntimeDataMap extension_runtime_data_;
+ // Holds a map between renderer process IDs that are associated with an
+ // installed app and their app.
+ typedef std::map<int, scoped_refptr<const Extension> > InstalledAppMap;
+ InstalledAppMap installed_app_hosts_;
+
// The full path to the directory where extensions are installed.
FilePath install_directory_;

Powered by Google App Engine
This is Rietveld 408576698