Fixed some MinGW warnings

This commit is contained in:
cnjinhao
2015-01-12 05:30:45 +08:00
parent 0474299bdc
commit 7496fea110
3 changed files with 24 additions and 36 deletions

View File

@@ -119,8 +119,8 @@ namespace nana
if (::EnumDisplaySettings(disp.DeviceName, ENUM_CURRENT_SETTINGS, &mode))
{
if (mode.dmPosition.x == mi.rcWork.left && mode.dmPosition.y == mi.rcWork.top &&
(mode.dmPelsWidth == mi.rcWork.right - mi.rcWork.left) &&
(mode.dmPelsHeight == mi.rcWork.bottom - mi.rcWork.top))
(static_cast<int>(mode.dmPelsWidth) == mi.rcWork.right - mi.rcWork.left) &&
(static_cast<int>(mode.dmPelsHeight) == mi.rcWork.bottom - mi.rcWork.top))
{
return std::make_shared<real_display>(static_cast<std::size_t>(index - 1), rectangle{ mode.dmPosition.x, mode.dmPosition.y, static_cast<unsigned>(mode.dmPelsWidth), static_cast<unsigned>(mode.dmPelsHeight) });
}
@@ -191,4 +191,4 @@ namespace nana
}
}
//end class screen
}
}