From ef0eca53d7e669dd7f172c618c5a4296a9ce70f0 Mon Sep 17 00:00:00 2001 From: Orgad Shaneh <orgad.shaneh@audiocodes.com> Date: Tue, 4 Nov 2014 10:31:51 +0200 Subject: [PATCH] ThemeEditor: Preselect widget style on edit Change-Id: I9992d595fc5995c9dbd9f244744b80f93548e942 Reviewed-by: Thorben Kroeger <thorbenkroeger@gmail.com> Reviewed-by: Orgad Shaneh <orgads@gmail.com> --- src/plugins/coreplugin/themeeditor/themesettingsitemdelegate.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plugins/coreplugin/themeeditor/themesettingsitemdelegate.cpp b/src/plugins/coreplugin/themeeditor/themesettingsitemdelegate.cpp index 94f2f8dc2bb..0430c2630f6 100644 --- a/src/plugins/coreplugin/themeeditor/themesettingsitemdelegate.cpp +++ b/src/plugins/coreplugin/themeeditor/themesettingsitemdelegate.cpp @@ -134,6 +134,7 @@ QWidget *ThemeSettingsItemDelegate::createEditor(QWidget *parent, const QStyleOp QMetaEnum e = Theme::staticMetaObject.enumerator(Theme::staticMetaObject.indexOfEnumerator("WidgetStyle")); for (int i = 0, total = e.keyCount(); i < total; ++i) cb->addItem(QLatin1String(e.key(i))); + cb->setCurrentIndex(model->m_widgetStyle); connect(cb, static_cast<void (QComboBox::*)(int)>(&QComboBox::activated), this, [this, cb]() { ThemeSettingsItemDelegate *me = const_cast<ThemeSettingsItemDelegate *>(this); -- GitLab