Theming: Fix styling of TargetSettingsWidget

If using the flat style also the TargetSettingsWidget should be flat.

Change-Id: I16147c9868e3e949a4d9aa0fedf85358504bde9e
Reviewed-by: Thorben Kroeger <thorbenkroeger@gmail.com>
Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
Thomas Hartmann
2014-11-06 14:16:29 +01:00
committed by Orgad Shaneh
parent 0dc99f568a
commit da3b7a6c4a

View File

@@ -31,6 +31,8 @@
#include "targetsettingswidget.h"
#include "ui_targetsettingswidget.h"
#include <utils/theme/theme.h>
#include <QPushButton>
using namespace ProjectExplorer::Internal;
@@ -41,9 +43,15 @@ TargetSettingsWidget::TargetSettingsWidget(QWidget *parent) :
m_targetSelector(new TargetSelector(this))
{
ui->setupUi(this);
ui->header->setStyleSheet(QLatin1String("QWidget#header {"
"border-image: url(:/projectexplorer/images/targetseparatorbackground.png) 43 0 0 0 repeat;"
"}"));
if (Utils::creatorTheme()->widgetStyle() == Utils::Theme::StyleFlat) {
ui->separator->setVisible(false);
ui->shadow->setVisible(false);
} else {
ui->header->setStyleSheet(QLatin1String("QWidget#header {"
"border-image: url(:/projectexplorer/images/targetseparatorbackground.png) 43 0 0 0 repeat;"
"}"));
}
QHBoxLayout *headerLayout = new QHBoxLayout;
headerLayout->setContentsMargins(5, 3, 0, 0);