qt: Finetune ModalOverlay (#3699)

* qt: Align warning icon in ModalOverlay properly with the text

* qt: Center form layout in modaloverlay
This commit is contained in:
dustinface 2020-09-13 00:48:23 +02:00 committed by xdustinface
parent 16f9d94404
commit 01a3a6c81a
3 changed files with 8 additions and 9 deletions

View File

@ -79,10 +79,7 @@
<number>0</number>
</property>
<item>
<widget class="QPushButton" name="warningIcon">
<property name="enabled">
<bool>false</bool>
</property>
<widget class="QLabel" name="warningIcon">
<property name="text">
<string/>
</property>
@ -172,6 +169,9 @@
<property name="fieldGrowthPolicy">
<enum>QFormLayout::FieldsStayAtSizeHint</enum>
</property>
<property name="formAlignment">
<set>Qt::AlignHCenter|Qt::AlignTop</set>
</property>
<property name="horizontalSpacing">
<number>6</number>
</property>

View File

@ -31,7 +31,7 @@ foreverHidden(false)
ui->labelEstimatedTimeLeft,
}, GUIUtil::FontWeight::Bold);
GUIUtil::setIcon(ui->warningIcon, "warning", GUIUtil::ThemedColor::ORANGE, QSize(48, 48));
ui->warningIcon->setPixmap(GUIUtil::getIcon("warning", GUIUtil::ThemedColor::ORANGE).pixmap(48, 48));
connect(ui->closeButton, SIGNAL(clicked()), this, SLOT(closeClicked()));
if (parent) {

View File

@ -1231,11 +1231,10 @@ QWidget#bgWidget { /* The frame overlaying the overview-page */
padding-right: 10px;
}
QWidget#bgWidget .QPushButton#warningIcon {
QWidget#bgWidget .QLabel#warningIcon {
background-color: #00000000;
width: 64px;
height: 64px;
padding: 5px;
margin-left: 10px;
margin-right: 10px;
}
QWidget#contentWidget { /* The actual content with the text/buttons/etc... */