Ensure wxBitmap::SetScaleFactor() doesn't change bitmap copies

Call AllocExclusive() to ensure that we're only changing the scale
factor of this object, and not of all the other objects using the same
data.
This commit is contained in:
Vadim Zeitlin
2022-01-22 23:00:12 +00:00
parent b4946c2fe3
commit d943d6f6cf

View File

@@ -346,6 +346,8 @@ void wxGDIImage::SetScaleFactor(double scale)
{
wxCHECK_RET( IsOk(), wxT("invalid bitmap") );
AllocExclusive();
GetGDIImageData()->m_scaleFactor = scale;
}