Bug 1391689 - Pass the correct origin when drawing the titlebar overlay with webrender. r=mattwoodrow
authorMarkus Stange <mstange@themasta.com>
Thu, 07 Sep 2017 15:15:45 +0200
changeset 379737 39dc0da77e09f839fc395bdeb019536c7dcf244d
parent 379736 0a49941e45a5d58b01051b4283d4bd1fff7aadd1
child 379738 71652e02591473209ca9232374b5bbeac78b0c7f
push id32461
push userkwierso@gmail.com
push dateFri, 08 Sep 2017 20:15:32 +0000
treeherdermozilla-central@dd3736e98e4e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmattwoodrow
bugs1391689
milestone57.0a1
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 1391689 - Pass the correct origin when drawing the titlebar overlay with webrender. r=mattwoodrow MozReview-Commit-ID: DdMjUFr0LR9
widget/cocoa/nsChildView.mm
--- a/widget/cocoa/nsChildView.mm
+++ b/widget/cocoa/nsChildView.mm
@@ -2115,17 +2115,17 @@ nsChildView::AddWindowOverlayWebRenderCo
     }
 
     if (!updatedTitlebarRegion.IsEmpty()) {
       wr::ImageDescriptor descriptor(size, stride, format);
       aBuilder.Resources().UpdateImageBuffer(*mTitlebarImageKey, descriptor, buffer);
     }
 
     wr::LayoutRect rect = wr::ToLayoutRect(mTitlebarRect);
-    aBuilder.PushImage(wr::LayoutRect{ { 0, 0 }, { float(size.width), float(size.height) } },
+    aBuilder.PushImage(wr::LayoutRect{ rect.origin, { float(size.width), float(size.height) } },
                        rect, wr::ImageRendering::Auto, *mTitlebarImageKey);
   }
 }
 
 void
 nsChildView::CleanupWebRenderWindowOverlay(layers::WebRenderBridgeChild* aWrBridge)
 {
   if (mTitlebarImageKey) {