From 7c51eee345d27e680a26a915ffccb2d0abf063ea Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 28 Dec 2012 22:17:27 +0300 Subject: Fix previous commit error. --- src/gui/widgets/extendedlistbox.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/gui/widgets/extendedlistbox.cpp b/src/gui/widgets/extendedlistbox.cpp index b1bcf257f..b932f91b0 100644 --- a/src/gui/widgets/extendedlistbox.cpp +++ b/src/gui/widgets/extendedlistbox.cpp @@ -109,12 +109,12 @@ void ExtendedListBox::draw(gcn::Graphics *graphics) } else { + const int y = mSelected * height; g->drawImage(image, mImagePadding, y + (height - image->getHeight()) / 2 + mPadding); graphics->setColor(mForegroundSelectedColor); font->drawString(graphics, mListModel->getElementAt(mSelected), - image->getWidth() + mImagePadding + mSpacing, - mSelected * height + textPos); + image->getWidth() + mImagePadding + mSpacing, y + textPos); } } BLOCK_END("ExtendedListBox::draw") -- cgit v1.2.3-70-g09d2