summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'Swift/QtUI/UserSearch/QtContactListWidget.cpp')
-rw-r--r--Swift/QtUI/UserSearch/QtContactListWidget.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/Swift/QtUI/UserSearch/QtContactListWidget.cpp b/Swift/QtUI/UserSearch/QtContactListWidget.cpp
index 899c592..90adc11 100644
--- a/Swift/QtUI/UserSearch/QtContactListWidget.cpp
+++ b/Swift/QtUI/UserSearch/QtContactListWidget.cpp
@@ -44,8 +44,7 @@ QtContactListWidget::QtContactListWidget(QWidget* parent, SettingsProvider* sett
setItemDelegateForColumn(0, contactListDelegate_);
setItemDelegateForColumn(1, removableItemDelegate_);
- int closeIconWidth = fontMetrics().height();
- header()->resizeSection(1, closeIconWidth);
+ header()->resizeSection(1, removableItemDelegate_->sizeHint(QStyleOptionViewItem(), QModelIndex()).width());
header()->setStretchLastSection(false);
#if QT_VERSION >= 0x050000