Compilation fix for MinGW in GDI+ code.
Don't use the XXXModeInvalid constants which are missing from MinGW headers for some reason. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@76317 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
72aad0d6ea
commit
bf00e40c4b
@ -1549,7 +1549,12 @@ bool wxGDIPlusContext::SetAntialiasMode(wxAntialiasMode antialias)
|
|||||||
if (m_antialias == antialias)
|
if (m_antialias == antialias)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
SmoothingMode antialiasMode = SmoothingModeInvalid;
|
// MinGW currently doesn't provide InterpolationModeInvalid in its headers,
|
||||||
|
// so use our own definition.
|
||||||
|
static const SmoothingMode
|
||||||
|
wxSmoothingModeInvalid = static_cast<SmoothingMode>(-1);
|
||||||
|
|
||||||
|
SmoothingMode antialiasMode = wxSmoothingModeInvalid;
|
||||||
switch (antialias)
|
switch (antialias)
|
||||||
{
|
{
|
||||||
case wxANTIALIAS_DEFAULT:
|
case wxANTIALIAS_DEFAULT:
|
||||||
@ -1561,7 +1566,7 @@ bool wxGDIPlusContext::SetAntialiasMode(wxAntialiasMode antialias)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
wxCHECK_MSG( antialiasMode != SmoothingModeInvalid, false,
|
wxCHECK_MSG( antialiasMode != wxSmoothingModeInvalid, false,
|
||||||
wxS("Unknown antialias mode") );
|
wxS("Unknown antialias mode") );
|
||||||
|
|
||||||
if ( m_context->SetSmoothingMode(antialiasMode) != Gdiplus::Ok )
|
if ( m_context->SetSmoothingMode(antialiasMode) != Gdiplus::Ok )
|
||||||
@ -1577,7 +1582,12 @@ bool wxGDIPlusContext::SetInterpolationQuality(wxInterpolationQuality interpolat
|
|||||||
if (m_interpolation == interpolation)
|
if (m_interpolation == interpolation)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
InterpolationMode interpolationMode = InterpolationModeInvalid;
|
// MinGW currently doesn't provide InterpolationModeInvalid in its headers,
|
||||||
|
// so use our own definition.
|
||||||
|
static const InterpolationMode
|
||||||
|
wxInterpolationModeInvalid = static_cast<InterpolationMode>(-1);
|
||||||
|
|
||||||
|
InterpolationMode interpolationMode = wxInterpolationModeInvalid;
|
||||||
switch (interpolation)
|
switch (interpolation)
|
||||||
{
|
{
|
||||||
case wxINTERPOLATION_DEFAULT:
|
case wxINTERPOLATION_DEFAULT:
|
||||||
@ -1601,7 +1611,7 @@ bool wxGDIPlusContext::SetInterpolationQuality(wxInterpolationQuality interpolat
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
wxCHECK_MSG( interpolationMode != InterpolationModeInvalid, false,
|
wxCHECK_MSG( interpolationMode != wxInterpolationModeInvalid, false,
|
||||||
wxS("Unknown interpolation mode") );
|
wxS("Unknown interpolation mode") );
|
||||||
|
|
||||||
if ( m_context->SetInterpolationMode(interpolationMode) != Gdiplus::Ok )
|
if ( m_context->SetInterpolationMode(interpolationMode) != Gdiplus::Ok )
|
||||||
|
Loading…
Reference in New Issue
Block a user