Bug 425958 - Draw white when Gecko refuses to draw in drawRect: (ifdef'd Camino-only). r=mstange, a=ss
git-svn-id: svn://10.0.0.236/trunk@258975 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
c2bfb46a1c
commit
2f0f1c1a3e
@ -2731,7 +2731,18 @@ NSEvent* gLastDragEvent = nil;
|
|||||||
paintEvent.region = rgn;
|
paintEvent.region = rgn;
|
||||||
|
|
||||||
nsAutoRetainCocoaObject kungFuDeathGrip(self);
|
nsAutoRetainCocoaObject kungFuDeathGrip(self);
|
||||||
|
#ifdef MOZ_MACBROWSER
|
||||||
|
PRBool painted = mGeckoChild->DispatchWindowEvent(paintEvent);
|
||||||
|
if (!painted && [self isOpaque]) {
|
||||||
|
// Gecko refused to draw, but we've claimed to be opaque, so we have to
|
||||||
|
// draw something--fill with white.
|
||||||
|
CGContextSetRGBFillColor(cgContext, 1, 1, 1, 1);
|
||||||
|
CGContextFillRect(cgContext, CGRectMake(aRect.origin.x, aRect.origin.y,
|
||||||
|
aRect.size.width, aRect.size.height));
|
||||||
|
}
|
||||||
|
#else
|
||||||
mGeckoChild->DispatchWindowEvent(paintEvent);
|
mGeckoChild->DispatchWindowEvent(paintEvent);
|
||||||
|
#endif
|
||||||
if (!mGeckoChild)
|
if (!mGeckoChild)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user