summaryrefslogtreecommitdiff
path: root/src/gui/widgets/characterviewsmall.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/characterviewsmall.cpp')
-rw-r--r--src/gui/widgets/characterviewsmall.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/gui/widgets/characterviewsmall.cpp b/src/gui/widgets/characterviewsmall.cpp
index 6cdb01c7e..010bb3bba 100644
--- a/src/gui/widgets/characterviewsmall.cpp
+++ b/src/gui/widgets/characterviewsmall.cpp
@@ -45,7 +45,12 @@ CharacterViewSmall::CharacterViewSmall(CharSelectDialog *const widget,
{
add(*it);
}
- show(0);
+ const int sz = static_cast<signed>(mCharacterEntries->size());
+ mSelected = 0;
+ mSelectedEntry = (*mCharacterEntries)[mSelected];
+ mSelectedEntry->setVisible(true);
+ mNumber->setCaption(strprintf("%d / %d", mSelected + 1, sz));
+ mNumber->adjustSize();
}
add(mPrevious);
add(mNext);