Make wxBitmap::ConvertToDisabled() work correctly for scaled bitmaps
Preserve the scale factor after conversion. Closes #17307.
This commit is contained in:
@@ -302,7 +302,8 @@ wxBitmap::
|
|||||||
#endif
|
#endif
|
||||||
ConvertToDisabled(unsigned char brightness) const
|
ConvertToDisabled(unsigned char brightness) const
|
||||||
{
|
{
|
||||||
return ConvertToImage().ConvertToDisabled(brightness);
|
const wxImage imgDisabled = ConvertToImage().ConvertToDisabled(brightness);
|
||||||
|
return wxBitmap(imgDisabled, -1, GetScaleFactor());
|
||||||
}
|
}
|
||||||
#endif // wxUSE_IMAGE
|
#endif // wxUSE_IMAGE
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user