| Index: content/renderer/browser_plugin/browser_plugin_manager.h
|
| diff --git a/content/renderer/browser_plugin/browser_plugin_manager.h b/content/renderer/browser_plugin/browser_plugin_manager.h
|
| index a4a59daf32058002b2c3b5c30c04b96fa4ab7f00..3f04db71437fa3f1524d30b8fb9b3e10840e6ebe 100644
|
| --- a/content/renderer/browser_plugin/browser_plugin_manager.h
|
| +++ b/content/renderer/browser_plugin/browser_plugin_manager.h
|
| @@ -19,7 +19,7 @@ struct WebPluginParams;
|
|
|
| namespace content {
|
|
|
| -class BrowserPlugin;
|
| +class BrowserPluginImpl;
|
| class BrowserPluginManagerFactory;
|
| class RenderViewImpl;
|
|
|
| @@ -44,15 +44,15 @@ class CONTENT_EXPORT BrowserPluginManager
|
| // BrowserPlugin is responsible for associating itself with the
|
| // BrowserPluginManager via AddBrowserPlugin. When it is destroyed, it is
|
| // responsible for removing its association via RemoveBrowserPlugin.
|
| - virtual BrowserPlugin* CreateBrowserPlugin(
|
| + virtual BrowserPluginImpl* CreateBrowserPlugin(
|
| RenderViewImpl* render_view,
|
| WebKit::WebFrame* frame,
|
| const WebKit::WebPluginParams& params) = 0;
|
| - virtual void AllocateInstanceID(BrowserPlugin* browser_plugin) = 0;
|
| + virtual void AllocateInstanceID(BrowserPluginImpl* browser_plugin) = 0;
|
|
|
| - void AddBrowserPlugin(int instance_id, BrowserPlugin* browser_plugin);
|
| + void AddBrowserPlugin(int instance_id, BrowserPluginImpl* browser_plugin);
|
| void RemoveBrowserPlugin(int instance_id);
|
| - BrowserPlugin* GetBrowserPlugin(int instance_id) const;
|
| + BrowserPluginImpl* GetBrowserPlugin(int instance_id) const;
|
| void UpdateFocusState();
|
| RenderViewImpl* render_view() const { return render_view_; }
|
|
|
| @@ -71,12 +71,21 @@ class CONTENT_EXPORT BrowserPluginManager
|
| // Friend RefCounted so that the dtor can be non-public.
|
| friend class base::RefCounted<BrowserPluginManager>;
|
|
|
| + // Initialize the set of message types that should be forwarded to
|
| + // BrowserPlugins.
|
| + void InitializeMessageSet();
|
| +
|
| + // Returns whether a message should be forwarded to BrowserPlugins.
|
| + bool ShouldForwardToBrowserPlugin(const IPC::Message& message);
|
| +
|
| // Static factory instance (always NULL for non-test).
|
| static BrowserPluginManagerFactory* factory_;
|
|
|
| virtual ~BrowserPluginManager();
|
| - IDMap<BrowserPlugin> instances_;
|
| + IDMap<BrowserPluginImpl> instances_;
|
| base::WeakPtr<RenderViewImpl> render_view_;
|
| + // Set of messages requested by BrowserPluginObservers.
|
| + std::set<uint32> browser_plugin_messages_;
|
|
|
| DISALLOW_COPY_AND_ASSIGN(BrowserPluginManager);
|
| };
|
|
|