wxDC::Blit() ignores useMask if there is no mask instead of giving an assert failure
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5677 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
4f527e7158
commit
d5536adedf
@ -1255,8 +1255,12 @@ bool wxDC::DoBlit(wxCoord xdest, wxCoord ydest,
|
|||||||
const wxBitmap& bmp = source->m_selectedBitmap;
|
const wxBitmap& bmp = source->m_selectedBitmap;
|
||||||
mask = bmp.GetMask();
|
mask = bmp.GetMask();
|
||||||
|
|
||||||
wxCHECK_MSG( bmp.Ok() && mask && mask->GetMaskBitmap(), FALSE,
|
if ( !(bmp.Ok() && mask && mask->GetMaskBitmap()) )
|
||||||
_T("can't blit with mask without mask") );
|
{
|
||||||
|
// don't give assert here because this would break existing
|
||||||
|
// programs - just silently ignore useMask parameter
|
||||||
|
useMask = FALSE;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
COLORREF old_textground = ::GetTextColor(GetHdc());
|
COLORREF old_textground = ::GetTextColor(GetHdc());
|
||||||
|
Loading…
Reference in New Issue
Block a user