Some minor changes to MWList

c++11
Stanislav Bas 10 years ago
parent 959fe3eb87
commit 6cb221f8d0

@ -48,7 +48,7 @@ namespace Gui
const int _scrollBarWidth = 20; // fetch this from skin? const int _scrollBarWidth = 20; // fetch this from skin?
const int scrollBarWidth = scrollbarShown ? _scrollBarWidth : 0; const int scrollBarWidth = scrollbarShown ? _scrollBarWidth : 0;
const int spacing = 3; const int spacing = 3;
int viewPosition = mScrollView->getViewOffset().top; int viewPosition = -mScrollView->getViewOffset().top;
while (mScrollView->getChildCount()) while (mScrollView->getChildCount())
{ {
@ -102,7 +102,7 @@ namespace Gui
int viewRange = mScrollView->getCanvasSize().height; int viewRange = mScrollView->getCanvasSize().height;
if(viewPosition > viewRange) if(viewPosition > viewRange)
viewPosition = viewRange; viewPosition = viewRange;
mScrollView->setViewOffset(MyGUI::IntPoint(0, viewPosition)); mScrollView->setViewOffset(MyGUI::IntPoint(0, -viewPosition));
} }
void MWList::setPropertyOverride(const std::string &_key, const std::string &_value) void MWList::setPropertyOverride(const std::string &_key, const std::string &_value)

Loading…
Cancel
Save