mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 777700 - Part 2: Verify if a cached SourceSurface is still valid. r=jrmuizel
This commit is contained in:
parent
69cb6d9312
commit
58584f2ceb
@ -503,7 +503,13 @@ gfxPlatform::GetSourceSurfaceForSurface(DrawTarget *aTarget, gfxASurface *aSurfa
|
||||
void *userData = aSurface->GetData(&kSourceSurface);
|
||||
|
||||
if (userData) {
|
||||
return static_cast<SourceSurface*>(userData);
|
||||
SourceSurface *surf = static_cast<SourceSurface*>(userData);
|
||||
|
||||
if (surf->IsValid()) {
|
||||
return surf;
|
||||
}
|
||||
// We can just continue here as when setting new user data the destroy
|
||||
// function will be called for the old user data.
|
||||
}
|
||||
|
||||
SurfaceFormat format;
|
||||
|
Loading…
Reference in New Issue
Block a user