Share dialog: Don't close on enter
authorChristian Kamm <mail@ckamm.de>
Tue, 24 Nov 2015 08:58:18 +0000 (09:58 +0100)
committerChristian Kamm <mail@ckamm.de>
Tue, 24 Nov 2015 08:58:18 +0000 (09:58 +0100)
Setting default=false was not enough.

src/gui/sharedialog.cpp

index d5963fcf916ed83bd75e90cffe134a645dd8cdae..c85ffc8bbd1363f535668ce339e42f77d8b4e580 100644 (file)
@@ -46,7 +46,10 @@ ShareDialog::ShareDialog(AccountPtr account, const QString &sharePath, const QSt
 
     QPushButton *closeButton = _ui->buttonBox->button(QDialogButtonBox::Close);
     connect(closeButton, SIGNAL(clicked()), this, SLOT(close()));
-    closeButton->setDefault(false); // Because people press enter in the dialog and we don't want to close for that
+
+    // Because people press enter in the dialog and we don't want to close for that
+    closeButton->setDefault(false);
+    closeButton->setAutoDefault(false);
 
     // Set icon
     QFileInfo f_info(_localPath);