fix double to int conversion warning
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@45580 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -63,8 +63,6 @@ enum Transparency
|
|||||||
Transparency_Alpha
|
Transparency_Alpha
|
||||||
};
|
};
|
||||||
|
|
||||||
static const double INCHES_IN_METER = 39.3700787;
|
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// local functions
|
// local functions
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
@@ -755,8 +753,11 @@ bool wxPNGHandler::SaveFile( wxImage *image, wxOutputStream& stream, bool verbos
|
|||||||
switch ( GetResolutionFromOptions(*image, &resX, &resY) )
|
switch ( GetResolutionFromOptions(*image, &resX, &resY) )
|
||||||
{
|
{
|
||||||
case wxIMAGE_RESOLUTION_INCHES:
|
case wxIMAGE_RESOLUTION_INCHES:
|
||||||
resX *= INCHES_IN_METER;
|
{
|
||||||
resY *= INCHES_IN_METER;
|
const double INCHES_IN_METER = 10000.0 / 254;
|
||||||
|
resX = int(resX * INCHES_IN_METER);
|
||||||
|
resY = int(resY * INCHES_IN_METER);
|
||||||
|
}
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case wxIMAGE_RESOLUTION_CM:
|
case wxIMAGE_RESOLUTION_CM:
|
||||||
|
Reference in New Issue
Block a user