Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit a7de50a9 authored by Laurent Montel's avatar Laurent Montel 😁

Add parent to qdialogbuttonbox

parent 3b60d9db
......@@ -66,7 +66,7 @@ ContactPrintThemeConfigureDialog::ContactPrintThemeConfigureDialog(QWidget *pare
QVBoxLayout *mainLayout = new QVBoxLayout(this);
mainLayout->addWidget(tab);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel | QDialogButtonBox::RestoreDefaults);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel | QDialogButtonBox::RestoreDefaults, this);
QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok);
okButton->setDefault(true);
okButton->setShortcut(Qt::CTRL | Qt::Key_Return);
......
......@@ -65,7 +65,7 @@ ContactConfigureDialog::ContactConfigureDialog(QWidget *parent)
QVBoxLayout *mainLayout = new QVBoxLayout(this);
mainLayout->addWidget(tab);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel | QDialogButtonBox::RestoreDefaults);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel | QDialogButtonBox::RestoreDefaults, this);
QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok);
okButton->setDefault(true);
okButton->setShortcut(Qt::CTRL | Qt::Key_Return);
......
......@@ -73,7 +73,7 @@ ManageThemes::ManageThemes(const QString &relativeThemePath, QWidget *parent)
QVBoxLayout *mainLayout = new QVBoxLayout(this);
mainLayout->addWidget(w);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Close);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Close, this);
connect(buttonBox, &QDialogButtonBox::rejected, this, &ManageThemes::reject);
mainLayout->addWidget(buttonBox);
......
......@@ -60,7 +60,7 @@ ThemeConfigureDialog::ThemeConfigureDialog(QWidget *parent)
QVBoxLayout *mainLayout = new QVBoxLayout(this);
mainLayout->addWidget(tab);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel | QDialogButtonBox::RestoreDefaults);
QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel | QDialogButtonBox::RestoreDefaults, this);
QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok);
okButton->setDefault(true);
okButton->setShortcut(Qt::CTRL | Qt::Key_Return);
......
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