Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(752)

Unified Diff: components/plugins/renderer/loadable_plugin_placeholder.cc

Issue 1056643002: Force layout and invalidation for new plugin content (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased, just to be sure. Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/plugins/renderer/loadable_plugin_placeholder.cc
diff --git a/components/plugins/renderer/loadable_plugin_placeholder.cc b/components/plugins/renderer/loadable_plugin_placeholder.cc
index 3719130a70f189e57fe16ef983c59acd1ee6a9e7..d259f79b495e88e359ad9ec14511e90cfe632eb0 100644
--- a/components/plugins/renderer/loadable_plugin_placeholder.cc
+++ b/components/plugins/renderer/loadable_plugin_placeholder.cc
@@ -329,6 +329,12 @@ void LoadablePluginPlaceholder::DidFinishLoadingCallback() {
if (message_.length() > 0)
UpdateMessage();
+ // Ensure that we force a layout and paint invalidation for the new
+ // content. This will cause the container invalidation to be acted upon.
+ blink::WebFrame* frame = GetFrame();
+ blink::WebView* view = frame->view();
+ view->setNeedsLayoutAndFullPaintInvalidation();
+
// Wait for the placeholder to finish loading to hide the premade plugin.
// This is necessary to prevent a flicker.
if (premade_throttler_ && !placeholder_was_replaced_)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698