mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 729116: Try our best to have a valid mTarget even when having an invalid context. r=joe
This commit is contained in:
parent
0610770d3b
commit
c0689e1446
@ -1306,6 +1306,10 @@ nsCanvasRenderingContext2DAzure::InitializeWithTarget(DrawTarget *target, PRInt3
|
||||
mTarget = target;
|
||||
} else {
|
||||
mValid = false;
|
||||
// Create a dummy target in the hopes that it will help us deal with users
|
||||
// calling into us after having changed the size where the size resulted
|
||||
// in an inability to create a correct DrawTarget.
|
||||
mTarget = gfxPlatform::GetPlatform()->CreateOffscreenDrawTarget(IntSize(1, 1), FORMAT_B8G8R8A8);
|
||||
}
|
||||
|
||||
mResetLayer = true;
|
||||
|
Loading…
Reference in New Issue
Block a user