| Index: content/renderer/pepper/pepper_plugin_instance_impl.cc
|
| diff --git a/content/renderer/pepper/pepper_plugin_instance_impl.cc b/content/renderer/pepper/pepper_plugin_instance_impl.cc
|
| index 768922ec459976eb4f1750f30bbfdd1f66fbd7c0..8d97178015df84f49a27fadc4c147436ffd8c218 100644
|
| --- a/content/renderer/pepper/pepper_plugin_instance_impl.cc
|
| +++ b/content/renderer/pepper/pepper_plugin_instance_impl.cc
|
| @@ -1957,6 +1957,8 @@ bool PepperPluginInstanceImpl::PrintPDFOutput(PP_Resource print_output,
|
| void PepperPluginInstanceImpl::UpdateLayer(bool device_changed) {
|
| if (!container_)
|
| return;
|
| + if (throttler_ && throttler_->IsHiddenForPlaceholder())
|
| + return;
|
|
|
| gpu::Mailbox mailbox;
|
| uint32 sync_point = 0;
|
| @@ -2043,6 +2045,14 @@ void PepperPluginInstanceImpl::OnThrottleStateChange() {
|
| SendDidChangeView();
|
| }
|
|
|
| +void PepperPluginInstanceImpl::OnHiddenForPlaceholder(bool hidden) {
|
| + if (hidden) {
|
| + container_->setWebLayer(nullptr);
|
| + } else {
|
| + UpdateLayer(true /* device_changed */);
|
| + }
|
| +}
|
| +
|
| void PepperPluginInstanceImpl::AddLatencyInfo(
|
| const std::vector<ui::LatencyInfo>& latency_info) {
|
| if (render_frame_ && render_frame_->GetRenderWidget()) {
|
|
|