Commit 08663392 authored by Friedemann Kleint's avatar Friedemann Kleint

QML-Designer: Use QDialogButtonBox in warnings dialog.

Change-Id: Ic1853f7749ec64ad35e441a5903d2a343379f019
Reviewed-by: default avatarThomas Hartmann <Thomas.Hartmann@digia.com>
parent c4bbc5bc
......@@ -3,6 +3,8 @@
#include <qmldesignerplugin.h>
#include <QPushButton>
namespace QmlDesigner {
namespace Internal {
......@@ -16,8 +18,10 @@ QmlWarningDialog::QmlWarningDialog(QWidget *parent, const QStringList &warnings)
setResult (0);
ui->checkBox->setChecked(true);
connect(ui->ignoreButton, SIGNAL(clicked()), this, SLOT(ignoreButtonPressed()));
connect(ui->okButton, SIGNAL(clicked()), this, SLOT(okButtonPressed()));
connect(ui->buttonBox->button(QDialogButtonBox::Ignore),
SIGNAL(clicked()), this, SLOT(ignoreButtonPressed()));
connect(ui->buttonBox->button(QDialogButtonBox::Ok),
SIGNAL(clicked()), this, SLOT(okButtonPressed()));
connect(ui->checkBox, SIGNAL(toggled(bool)), this, SLOT(checkBoxToggled(bool)));
connect(ui->warnings, SIGNAL(linkActivated(QString)), this, SLOT(linkClicked(QString)));
......
......@@ -72,38 +72,11 @@
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>88</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QPushButton" name="ignoreButton">
<property name="toolTip">
<string>Ignore this warning and open the file</string>
</property>
<property name="text">
<string>Ignore</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="okButton">
<property name="text">
<string>OK</string>
</property>
</widget>
</item>
</layout>
<widget class="QDialogButtonBox" name="buttonBox">
<property name="standardButtons">
<set>QDialogButtonBox::Ignore|QDialogButtonBox::Ok</set>
</property>
</widget>
</item>
</layout>
</widget>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment