Bug 626245. Part 5: Move plugin widgets before compositing the window, not after. r=matspal
authorRobert O'Callahan <robert@ocallahan.org>
Wed, 10 Oct 2012 23:25:57 +1300
changeset 110324 b78108ed9da38e40bb935fe37f79e348e9b40da1
parent 110323 eed1630b856f7857a8bc91d4979d0c852125fc90
child 110325 9cabc319f7ff447ab70bf6a2bfc51a18af05996d
push id93
push usernmatsakis@mozilla.com
push dateWed, 31 Oct 2012 21:26:57 +0000
reviewersmatspal
bugs626245
milestone19.0a1
Bug 626245. Part 5: Move plugin widgets before compositing the window, not after. r=matspal
layout/base/nsPresShell.cpp
--- a/layout/base/nsPresShell.cpp
+++ b/layout/base/nsPresShell.cpp
@@ -7015,33 +7015,29 @@ PresShell::WillPaintWindow(bool aWillSen
 {
   nsRootPresContext* rootPresContext = mPresContext->GetRootPresContext();
   if (rootPresContext != mPresContext) {
     // This could be a popup's presshell. We don't allow plugins in popups
     // so there's nothing to do here.
     return;
   }
 
-  if (!aWillSendDidPaint) {
-    rootPresContext->ApplyPluginGeometryUpdates();
-  }
+  rootPresContext->ApplyPluginGeometryUpdates();
 }
 
 void
 PresShell::DidPaintWindow()
 {
   nsRootPresContext* rootPresContext = mPresContext->GetRootPresContext();
   if (rootPresContext != mPresContext) {
-    // This could be a popup's presshell. We don't allow plugins in popups
-    // so there's nothing to do here.
+    // This could be a popup's presshell. No point in notifying XPConnect
+    // about compositing of popups.
     return;
   }
 
-  rootPresContext->ApplyPluginGeometryUpdates();
-
   if (nsContentUtils::XPConnect()) {
     nsContentUtils::XPConnect()->NotifyDidPaint();
   }
 }
 
 bool
 PresShell::IsVisible()
 {