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

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: fix browser tests 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
« no previous file with comments | « chrome/browser/extensions/extension_host.cc ('k') | chrome/browser/extensions/extension_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/extension_service.h
===================================================================
--- chrome/browser/extensions/extension_service.h (revision 82593)
+++ 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(int renderer_child_id, const Extension* app);
+
+ // 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_;
« no previous file with comments | « chrome/browser/extensions/extension_host.cc ('k') | chrome/browser/extensions/extension_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698