| Index: content/renderer/browser_plugin/browser_plugin.h
|
| diff --git a/content/renderer/browser_plugin/browser_plugin.h b/content/renderer/browser_plugin/browser_plugin.h
|
| index 3a1bf2ea1dfe5d4fe49d20f7a5ce7b4efa15b495..b6e8b4ae7b6d99848cae52a306c16f2a72c19dfb 100644
|
| --- a/content/renderer/browser_plugin/browser_plugin.h
|
| +++ b/content/renderer/browser_plugin/browser_plugin.h
|
| @@ -125,6 +125,12 @@ class CONTENT_EXPORT BrowserPlugin :
|
| // touch events.
|
| void SetAcceptTouchEvents(bool accept);
|
|
|
| + // Requests media access permission from the embedder.
|
| + void RequestMediaAccess(int request_id, const GURL& security_origin);
|
| + // Informs the BrowserPlugin that the guest's request for media access has
|
| + // been allowed or denied by the embedder.
|
| + void RespondMediaAccess(int request_id, bool allow);
|
| +
|
| // Tells the BrowserPlugin to tell the guest to navigate to the previous
|
| // navigation entry in the navigation history.
|
| void Back();
|
| @@ -153,6 +159,9 @@ class CONTENT_EXPORT BrowserPlugin :
|
|
|
| gfx::Point ToLocalCoordinates(const gfx::Point& point) const;
|
|
|
| + // Called by browser plugin binding.
|
| + void OnListenerCallMediaAccess(int request_id, bool allow);
|
| +
|
| // WebKit::WebPlugin implementation.
|
| virtual WebKit::WebPluginContainer* container() const OVERRIDE;
|
| virtual bool initialize(WebKit::WebPluginContainer* container) OVERRIDE;
|
| @@ -191,6 +200,7 @@ class CONTENT_EXPORT BrowserPlugin :
|
| const WebKit::WebURL& url,
|
| void* notify_data,
|
| const WebKit::WebURLError& error) OVERRIDE;
|
| +
|
| private:
|
| friend class base::DeleteHelper<BrowserPlugin>;
|
| // Only the manager is allowed to create a BrowserPlugin.
|
| @@ -273,6 +283,9 @@ class CONTENT_EXPORT BrowserPlugin :
|
| // Informs the BrowserPlugin that guest has changed its size in autosize mode.
|
| void SizeChangedDueToAutoSize(const gfx::Size& old_view_size);
|
|
|
| + bool HasEventListeners(const std::string& event_name);
|
| + size_t GetNumberOfEventListeners(const std::string& event_name);
|
| +
|
| #if defined(OS_MACOSX)
|
| bool DamageBufferMatches(const TransportDIB* damage_buffer,
|
| const TransportDIB::Id& other_damage_buffer_id);
|
| @@ -321,6 +334,8 @@ class CONTENT_EXPORT BrowserPlugin :
|
|
|
| gfx::Size last_view_size_;
|
| bool size_changed_in_flight_;
|
| + typedef std::map<int, size_t> MediaAccessPendingCountsMap;
|
| + MediaAccessPendingCountsMap media_access_pending_counts_;
|
|
|
| // BrowserPlugin outlives RenderViewImpl in Chrome Apps and so we need to
|
| // store the BrowserPlugin's BrowserPluginManager in a member variable to
|
|
|