Bug 637278: INVALIDATE_NO_UPDATE_LAYER_TREE should subsume INVALIDATE_NO_THEBES_LAYERS. r=tn sr=roc
authorChris Jones <jones.chris.g@gmail.com>
Tue, 01 Mar 2011 12:27:35 -0600
changeset 63210 88074e56362792e1fc976da1e212b66db7ddb93b
parent 63209 21b0f3548852cfd82bf9577ac6f929730b70230c
child 63211 52ffeed74f9649899984d5ff11daa1c4f1508a10
push id1
push userroot
push dateTue, 26 Apr 2011 22:38:44 +0000
treeherdermozilla-beta@bfdb6e623a36 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstn, roc
bugs637278
milestone2.0b13pre
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 637278: INVALIDATE_NO_UPDATE_LAYER_TREE should subsume INVALIDATE_NO_THEBES_LAYERS. r=tn sr=roc
layout/generic/nsFrame.cpp
layout/generic/nsObjectFrame.cpp
--- a/layout/generic/nsFrame.cpp
+++ b/layout/generic/nsFrame.cpp
@@ -3953,17 +3953,17 @@ nsIFrame::InvalidateLayer(const nsRect& 
   if (!FrameLayerBuilder::HasDedicatedLayer(this, aDisplayItemKey)) {
     Invalidate(aDamageRect);
     return;
   }
 
   PRUint32 flags = INVALIDATE_NO_THEBES_LAYERS;
   if (aDisplayItemKey == nsDisplayItem::TYPE_VIDEO ||
       aDisplayItemKey == nsDisplayItem::TYPE_PLUGIN) {
-    flags = INVALIDATE_NO_UPDATE_LAYER_TREE;
+    flags |= INVALIDATE_NO_UPDATE_LAYER_TREE;
   }
 
   InvalidateWithFlags(aDamageRect, flags);
 }
 
 void
 nsIFrame::InvalidateTransformLayer()
 {
--- a/layout/generic/nsObjectFrame.cpp
+++ b/layout/generic/nsObjectFrame.cpp
@@ -3516,26 +3516,18 @@ NS_IMETHODIMP nsPluginInstanceOwner::Inv
      // The image size has changed - invalidate the old area too, bug 635405.
      nsRect oldRect = nsRect(0, 0,
                              presContext->DevPixelsToAppUnits(oldSize.width),
                              presContext->DevPixelsToAppUnits(oldSize.height));
      rect.UnionRect(rect, oldRect);
    }
  }
  rect.MoveBy(mObjectFrame->GetUsedBorderAndPadding().TopLeft());
-#ifndef XP_MACOSX
-  mObjectFrame->InvalidateLayer(rect, nsDisplayItem::TYPE_PLUGIN);
-#else
-  if (mozilla::FrameLayerBuilder::HasDedicatedLayer(mObjectFrame, nsDisplayItem::TYPE_PLUGIN)) {
-    mObjectFrame->InvalidateWithFlags(rect, nsIFrame::INVALIDATE_NO_UPDATE_LAYER_TREE);
-  } else {
-    mObjectFrame->Invalidate(rect);
-  }
-#endif
-  return NS_OK;
+ mObjectFrame->InvalidateLayer(rect, nsDisplayItem::TYPE_PLUGIN);
+ return NS_OK;
 }
 
 NS_IMETHODIMP nsPluginInstanceOwner::InvalidateRegion(NPRegion invalidRegion)
 {
   return NS_ERROR_NOT_IMPLEMENTED;
 }
 
 NS_IMETHODIMP nsPluginInstanceOwner::ForceRedraw()