| Index: extensions/browser/renderer_startup_helper.h
|
| diff --git a/extensions/browser/renderer_startup_helper.h b/extensions/browser/renderer_startup_helper.h
|
| index 94ec3833b955795135c84650f0b857268d8be0d4..9f033c15078d3a740bbdc2ab2f3ca3d3b23f7dd3 100644
|
| --- a/extensions/browser/renderer_startup_helper.h
|
| +++ b/extensions/browser/renderer_startup_helper.h
|
| @@ -25,6 +25,10 @@ class RenderProcessHost;
|
| namespace extensions {
|
| class Extension;
|
|
|
| +namespace test {
|
| +class RendererStartupHelperTest;
|
| +} // namespace test
|
| +
|
| // Informs renderers about extensions-related data (loaded extensions, available
|
| // functions, etc.) when they start. Sends this information to both extension
|
| // and non-extension renderers, as the non-extension renderers may have content
|
| @@ -59,6 +63,8 @@ class RendererStartupHelper : public KeyedService,
|
| void OnExtensionLoaded(const Extension& extension);
|
|
|
| private:
|
| + friend class test::RendererStartupHelperTest;
|
| +
|
| // Initializes the specified process, informing it of system state and loaded
|
| // extensions.
|
| void InitializeProcess(content::RenderProcessHost* process);
|
| @@ -69,14 +75,16 @@ class RendererStartupHelper : public KeyedService,
|
| content::BrowserContext* browser_context_; // Not owned.
|
|
|
| // The set of render processes that have had the initial batch of IPC messages
|
| - // sent, including the set of loaded extensions. Further messages that
|
| + // sent, together with the set of loaded extensions. Further messages that
|
| // activate, load, or unload extensions should not be sent until after this
|
| - // happens.
|
| - std::set<content::RenderProcessHost*> initialized_processes_;
|
| + // happens. Used to keep the track of initialized processes along with its
|
| + // loaded extensions.
|
| + std::map<content::RenderProcessHost*, std::set<ExtensionId>>
|
| + loaded_extensions_;
|
|
|
| // The set of ids for extensions that are active in a process that has not
|
| - // been initialized. The activation message will be sent the process is
|
| - // initialized.
|
| + // been initialized. The activation message will be sent once the process is
|
| + // initialized. This is only valid for uninitialized processes.
|
| std::map<content::RenderProcessHost*, std::set<ExtensionId>>
|
| pending_active_extensions_;
|
|
|
|
|