Bug 1259785: Do a proper flush when taking a snapshot so our dependent targets and command lists get appropriately cleared. r=jrmuizel draft
authorBas Schouten <bschouten@mozilla.com>
Thu, 31 Mar 2016 21:45:36 +0200
changeset 346299 79bc34d1822396e87eedb5913ac56ecbf1b65fa3
parent 345945 9f60a89fb3407e9ba100c34ebe90ccaf16cdd67f
child 517408 9da16b948489f2e5addc28829d975c814c82d591
push id14335
push userbschouten@mozilla.com
push dateThu, 31 Mar 2016 19:47:04 +0000
reviewersjrmuizel
bugs1259785
milestone48.0a1
Bug 1259785: Do a proper flush when taking a snapshot so our dependent targets and command lists get appropriately cleared. r=jrmuizel MozReview-Commit-ID: D49eFNRGD2V
gfx/2d/DrawTargetD2D1.cpp
--- a/gfx/2d/DrawTargetD2D1.cpp
+++ b/gfx/2d/DrawTargetD2D1.cpp
@@ -83,17 +83,17 @@ already_AddRefed<SourceSurface>
 DrawTargetD2D1::Snapshot()
 {
   if (mSnapshot) {
     RefPtr<SourceSurface> snapshot(mSnapshot);
     return snapshot.forget();
   }
   PopAllClips();
 
-  mDC->Flush();
+  Flush();
 
   mSnapshot = new SourceSurfaceD2D1(mBitmap, mDC, mFormat, mSize, this);
 
   RefPtr<SourceSurface> snapshot(mSnapshot);
   return snapshot.forget();
 }
 
 // Command lists are kept around by device contexts until EndDraw is called,