fix viewport resizing on screen resize.

This commit is contained in:
Edward Rudd 2013-12-31 19:31:14 -05:00
parent f8e8d704b5
commit 1120c60cae
1 changed files with 2 additions and 1 deletions

View File

@ -469,8 +469,9 @@ struct GraphicsPrivate
{ {
if (threadData->windowSizeMsg.pollChange(&winSize.x, &winSize.y)) if (threadData->windowSizeMsg.pollChange(&winSize.x, &winSize.y))
{ {
glState.viewport.init(IntRect(0, 0, winSize.x, winSize.y));
recalculateScreenSize(); recalculateScreenSize();
screen.setScreenSize(scSize.x, scSize.y); screen.setScreenSize(winSize.x, winSize.y);
updateScreenResoRatio(); updateScreenResoRatio();
} }
} }