summaryrefslogtreecommitdiff
path: root/src/gui/widgets/extendedlistbox.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2012-08-30 02:10:59 +0300
committerAndrei Karas <akaras@inbox.ru>2012-08-30 02:10:59 +0300
commit46f0755975033f37eaae9db73c0e2b6499c2a923 (patch)
tree5c13c361ce4a4e4fd0e07fca1953c54637965666 /src/gui/widgets/extendedlistbox.cpp
parent1feb7f7edc5f8f383e594b256ef4cab0fae75b99 (diff)
downloadmv-46f0755975033f37eaae9db73c0e2b6499c2a923.tar.gz
mv-46f0755975033f37eaae9db73c0e2b6499c2a923.tar.bz2
mv-46f0755975033f37eaae9db73c0e2b6499c2a923.tar.xz
mv-46f0755975033f37eaae9db73c0e2b6499c2a923.zip
Add const to more classes.
Diffstat (limited to 'src/gui/widgets/extendedlistbox.cpp')
-rw-r--r--src/gui/widgets/extendedlistbox.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/gui/widgets/extendedlistbox.cpp b/src/gui/widgets/extendedlistbox.cpp
index 8421c22df..c7d42338c 100644
--- a/src/gui/widgets/extendedlistbox.cpp
+++ b/src/gui/widgets/extendedlistbox.cpp
@@ -38,7 +38,7 @@
#include "debug.h"
-ExtendedListBox::ExtendedListBox(gcn::ListModel *listModel):
+ExtendedListBox::ExtendedListBox(gcn::ListModel *const listModel):
ListBox(listModel),
mRowHeight(13)
{
@@ -53,8 +53,9 @@ void ExtendedListBox::draw(gcn::Graphics *graphics)
if (!mListModel)
return;
- ExtendedListModel *model = static_cast<ExtendedListModel*>(mListModel);
- Graphics *g = static_cast<Graphics*>(graphics);
+ ExtendedListModel *const model = static_cast<ExtendedListModel* const>(
+ mListModel);
+ Graphics *const g = static_cast<Graphics *const>(graphics);
updateAlpha();
graphics->setFont(getFont());
@@ -78,7 +79,7 @@ void ExtendedListBox::draw(gcn::Graphics *graphics)
for (int i = 0, y = 0; i < mListModel->getNumberOfElements();
++i, y += height)
{
- const Image *image = model->getImageAt(i);
+ const Image *const image = model->getImageAt(i);
if (!image)
{
graphics->drawText(mListModel->getElementAt(i), 1, y + textPos);