diff options
Diffstat (limited to 'chrome/renderer/pepper_plugin_delegate_impl.cc')
-rw-r--r-- | chrome/renderer/pepper_plugin_delegate_impl.cc | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/chrome/renderer/pepper_plugin_delegate_impl.cc b/chrome/renderer/pepper_plugin_delegate_impl.cc index 7ca9d4e..31b89ff 100644 --- a/chrome/renderer/pepper_plugin_delegate_impl.cc +++ b/chrome/renderer/pepper_plugin_delegate_impl.cc @@ -53,6 +53,10 @@ class PlatformImage2DImpl : public pepper::PluginDelegate::PlatformImage2D { return reinterpret_cast<intptr_t>(dib_.get()); } + virtual TransportDIB* GetTransportDIB() const { + return dib_.get(); + } + private: int width_; int height_; @@ -520,6 +524,22 @@ void PepperPluginDelegateImpl::ViewFlushedPaint() { } } +bool PepperPluginDelegateImpl::GetBitmapForOptimizedPluginPaint( + const gfx::Rect& paint_bounds, + TransportDIB** dib, + gfx::Rect* location, + gfx::Rect* clip) { + for (std::set<pepper::PluginInstance*>::iterator i = + active_instances_.begin(); + i != active_instances_.end(); ++i) { + pepper::PluginInstance* instance = *i; + if (instance->GetBitmapForOptimizedPluginPaint( + paint_bounds, dib, location, clip)) + return true; + } + return false; +} + void PepperPluginDelegateImpl::InstanceCreated( pepper::PluginInstance* instance) { active_instances_.insert(instance); |