fix compiler warnings

This commit is contained in:
Jinhao 2017-06-22 00:11:36 +08:00
parent a937c6d8c5
commit 40c35d87a0

View File

@ -2327,7 +2327,7 @@ namespace nana{ namespace widgets
//move the caret to the end of the text if Ctrl is pressed //move the caret to the end of the text if Ctrl is pressed
if(arg.ctrl) if(arg.ctrl)
pos.y = (line_count - 1) * line_px; pos.y = static_cast<unsigned>((line_count - 1) * line_px);
break; break;
case keyboard::os_pageup: case keyboard::os_pageup:
if(origin.y > 0) if(origin.y > 0)
@ -2652,7 +2652,7 @@ namespace nana{ namespace widgets
} }
//move the caret to the end of this section. //move the caret to the end of this section.
res.x = text_size; res.x = static_cast<unsigned>(text_size);
for (std::size_t i = 0; i < row.second; ++i) for (std::size_t i = 0; i < row.second; ++i)
res.x += static_cast<int>(sections[i].end - sections[i].begin); res.x += static_cast<int>(sections[i].end - sections[i].begin);