From 93d9d9b39ca11134aebc7ffc361713362248c2d4 Mon Sep 17 00:00:00 2001 From: "sfraser%netscape.com" Date: Thu, 4 Nov 1999 22:36:21 +0000 Subject: [PATCH] Fixes for 18029 and 16723 -- fix image drawing on Mac to use GWorlds, and put in api to lock and unlock pixels. Pass a real nsDrawingSurface to the image, instead oif a cast GrafPtr. r=pnunn, a=chofmann. --- gfx/src/mac/nsRenderingContextMac.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gfx/src/mac/nsRenderingContextMac.cpp b/gfx/src/mac/nsRenderingContextMac.cpp index ce81f1539ce0..7792cb8b4355 100644 --- a/gfx/src/mac/nsRenderingContextMac.cpp +++ b/gfx/src/mac/nsRenderingContextMac.cpp @@ -1414,8 +1414,8 @@ NS_IMETHODIMP nsRenderingContextMac::DrawImage(nsIImage *aImage, const nsRect& a mGS->mTMatrix.TransformCoord(&sr.x,&sr.y,&sr.width,&sr.height); mGS->mTMatrix.TransformCoord(&dr.x,&dr.y,&dr.width,&dr.height); - nsresult result = aImage->Draw(*this,mPort,sr.x,sr.y,sr.width,sr.height, - dr.x,dr.y,dr.width,dr.height); + nsresult result = aImage->Draw(*this, mCurrentSurface, sr.x, sr.y, sr.width, sr.height, + dr.x, dr.y, dr.width, dr.height); EndDraw(); return result; @@ -1430,7 +1430,7 @@ NS_IMETHODIMP nsRenderingContextMac::DrawImage(nsIImage *aImage, const nsRect& a nsRect tr = aRect; mGS->mTMatrix.TransformCoord(&tr.x,&tr.y,&tr.width,&tr.height); - nsresult result = aImage->Draw(*this,mPort,tr.x,tr.y,tr.width,tr.height); + nsresult result = aImage->Draw(*this, mCurrentSurface, tr.x, tr.y, tr.width, tr.height); EndDraw(); return result;