Skip to content

Commit

Permalink
Limit drawing rect of selected item to viewport size (fixes #4341)
Browse files Browse the repository at this point in the history
  • Loading branch information
sfan5 committed Dec 20, 2016
1 parent 0f05021 commit bdf8f85
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/guiFormSpecMenu.cpp
Expand Up @@ -2362,6 +2362,7 @@ void GUIFormSpecMenu::drawSelectedItem()

core::rect<s32> imgrect(0,0,imgsize.X,imgsize.Y);
core::rect<s32> rect = imgrect + (m_pointer - imgrect.getCenter());
rect.constrainTo(driver->getViewPort());
drawItemStack(driver, m_font, stack, rect, NULL, m_gamedef, IT_ROT_DRAGGED);
}

Expand Down

0 comments on commit bdf8f85

Please sign in to comment.