Commit 5b6ba952 authored by Kurt Hindenburg's avatar Kurt Hindenburg

Do not setShortcut() on the OK button on dialogs

using okButton->setShortcut(Konsole::ACCEL | Qt::Key_Return); causes
the Alt+O to not work on the OK button.  Both Ctrl+Return and Alt+O
now work to close the dialog.

BUG: 364716
FIXED-IN: 18.04
parent e2e2ef66
......@@ -68,7 +68,6 @@ ColorSchemeEditor::ColorSchemeEditor(QWidget *aParent) :
mainLayout->addWidget(mainWidget);
QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok);
okButton->setDefault(true);
okButton->setShortcut(Konsole::ACCEL | Qt::Key_Return);
connect(buttonBox, &QDialogButtonBox::accepted, this, &ColorSchemeEditor::accept);
connect(buttonBox, &QDialogButtonBox::rejected, this, &ColorSchemeEditor::reject);
mainLayout->addWidget(buttonBox);
......
......@@ -47,7 +47,6 @@ CopyInputDialog::CopyInputDialog(QWidget *parent) :
mainLayout->addWidget(mainWidget);
QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok);
okButton->setDefault(true);
okButton->setShortcut(Konsole::ACCEL | Qt::Key_Return);
connect(buttonBox, &QDialogButtonBox::accepted, this, &CopyInputDialog::accept);
connect(buttonBox, &QDialogButtonBox::rejected, this, &CopyInputDialog::reject);
mainLayout->addWidget(buttonBox);
......
......@@ -83,7 +83,6 @@ EditProfileDialog::EditProfileDialog(QWidget *aParent) :
mainLayout->addWidget(mainWidget);
QPushButton *okButton = mButtonBox->button(QDialogButtonBox::Ok);
okButton->setDefault(true);
okButton->setShortcut(Konsole::ACCEL | Qt::Key_Return);
connect(mButtonBox, &QDialogButtonBox::accepted, this, &Konsole::EditProfileDialog::accept);
connect(mButtonBox, &QDialogButtonBox::rejected, this, &Konsole::EditProfileDialog::reject);
......
......@@ -43,7 +43,6 @@ HistorySizeDialog::HistorySizeDialog(QWidget *parent) :
mainLayout->addWidget(mainWidget);
QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok);
okButton->setDefault(true);
okButton->setShortcut(Konsole::ACCEL | Qt::Key_Return);
connect(buttonBox, &QDialogButtonBox::accepted, this, &HistorySizeDialog::accept);
connect(buttonBox, &QDialogButtonBox::rejected, this, &HistorySizeDialog::reject);
mainLayout->addWidget(buttonBox);
......
......@@ -42,7 +42,6 @@ RenameTabDialog::RenameTabDialog(QWidget *parent) :
mainLayout->addWidget(mainWidget);
QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok);
okButton->setAutoDefault(true);
okButton->setShortcut(Konsole::ACCEL | Qt::Key_Return);
connect(buttonBox, &QDialogButtonBox::accepted, this, &RenameTabDialog::accept);
connect(buttonBox, &QDialogButtonBox::rejected, this, &RenameTabDialog::reject);
mainLayout->addWidget(buttonBox);
......
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