diff options
author | ddorwin@chromium.org <ddorwin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-04-07 22:37:36 +0000 |
---|---|---|
committer | ddorwin@chromium.org <ddorwin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-04-07 22:37:36 +0000 |
commit | 6788b080965ee06e7bc329526834cd1490a5b772 (patch) | |
tree | f265dd4bd700ef2ecef652dfa38014d3db7ae614 /webkit/plugins/ppapi/plugin_delegate.h | |
parent | 1e44a9a4adccf4f31d817177e2ee47b58c93f40d (diff) | |
download | chromium_src-6788b080965ee06e7bc329526834cd1490a5b772.zip chromium_src-6788b080965ee06e7bc329526834cd1490a5b772.tar.gz chromium_src-6788b080965ee06e7bc329526834cd1490a5b772.tar.bz2 |
Added PPB_BrokerTrusted interface and a basic Chrome implementation of it.
The broker is not launched or connected yet.
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/6677178
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80858 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/plugins/ppapi/plugin_delegate.h')
-rw-r--r-- | webkit/plugins/ppapi/plugin_delegate.h | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/webkit/plugins/ppapi/plugin_delegate.h b/webkit/plugins/ppapi/plugin_delegate.h index 6112d53..6349cd9 100644 --- a/webkit/plugins/ppapi/plugin_delegate.h +++ b/webkit/plugins/ppapi/plugin_delegate.h @@ -67,6 +67,7 @@ class FullscreenContainer; class PepperFilePath; class PluginInstance; class PluginModule; +class PPB_Broker_Impl; class PPB_Flash_Menu_Impl; class PPB_Flash_NetConnector_Impl; @@ -95,7 +96,7 @@ class PluginDelegate { }; // This class is implemented by the PluginDelegate implementation and is - // designed to manage the lifetime and communicatin with the proxy's + // designed to manage the lifetime and communication with the proxy's // HostDispatcher for out-of-process PPAPI plugins. // // The point of this is to avoid having a relationship from the PPAPI plugin @@ -204,6 +205,18 @@ class PluginDelegate { virtual ~PlatformVideoDecoder() {} }; + // Provides access to the ppapi broker. + class PpapiBroker { + public: + virtual ~PpapiBroker() {} + + // Decrements the references to the broker for the instance. + // When the references reach 0 for all instances in this renderer, this + // object may be destroyed. When the references reach 0 for all instances + // using the same module, the broker may shut down. + virtual void Release(PluginInstance* instance) = 0; + }; + // Notification that the given plugin has crashed. When a plugin crashes, all // instances associated with that plugin will notify that they've crashed via // this function. @@ -237,6 +250,14 @@ class PluginDelegate { uint32_t sample_count, PlatformAudio::Client* client) = 0; + // A pointer is returned immediately, but it is not ready to be used until + // BrokerConnected has been called. + // The caller is responsible for calling Release() on the returned pointer + // to clean up the corresponding resources allocated during this call. + virtual PpapiBroker* ConnectToPpapiBroker( + PluginInstance* instance, + webkit::ppapi::PPB_Broker_Impl* client) = 0; + // Notifies that the number of find results has changed. virtual void NumberOfFindResultsChanged(int identifier, int total, |