summaryrefslogtreecommitdiff
path: root/src/gui/widgets/extendedlistbox.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-10-08 15:02:06 +0300
committerAndrei Karas <akaras@inbox.ru>2013-10-08 17:06:36 +0300
commitb930f7f858b0ad91206939ed1b6d5695bc10f9cc (patch)
tree2b6d2be95b1f387399709e99ffedf050866f534a /src/gui/widgets/extendedlistbox.cpp
parent4c404e75a4e36d2d3151200e09990a9b6e82dacf (diff)
downloadmanaplus-b930f7f858b0ad91206939ed1b6d5695bc10f9cc.tar.gz
manaplus-b930f7f858b0ad91206939ed1b6d5695bc10f9cc.tar.bz2
manaplus-b930f7f858b0ad91206939ed1b6d5695bc10f9cc.tar.xz
manaplus-b930f7f858b0ad91206939ed1b6d5695bc10f9cc.zip
use different item padding in listbox and extendedlistbox depend on DPI.
Diffstat (limited to 'src/gui/widgets/extendedlistbox.cpp')
-rw-r--r--src/gui/widgets/extendedlistbox.cpp12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/gui/widgets/extendedlistbox.cpp b/src/gui/widgets/extendedlistbox.cpp
index 45497ae0a..68b4df766 100644
--- a/src/gui/widgets/extendedlistbox.cpp
+++ b/src/gui/widgets/extendedlistbox.cpp
@@ -33,22 +33,14 @@ ExtendedListBox::ExtendedListBox(const Widget2 *const widget,
const std::string &skin,
const int rowHeight) :
ListBox(widget, listModel, skin),
- mRowHeight(rowHeight),
mImagePadding(mSkin ? mSkin->getOption("imagePadding") : 0),
mSpacing(mSkin ? mSkin->getOption("spacing") : 0),
- mItemPadding(mSkin ? mSkin->getOption("itemPadding") : 1),
mHeight(0),
mListItems(),
mSelectedItems()
{
- if (!mRowHeight)
- {
- const gcn::Font *font = getFont();
- if (font)
- mRowHeight = font->getHeight() + 2 * mItemPadding;
- else
- mRowHeight = 13;
- }
+ if (rowHeight)
+ mRowHeight = rowHeight;
}
ExtendedListBox::~ExtendedListBox()