From 494dfc2f4bef254a5915a3aae4981407aca5afc8 Mon Sep 17 00:00:00 2001 From: tooomm Date: Sat, 26 May 2018 03:59:52 +0200 Subject: [PATCH] actCancel remove (#3261) --- cockatrice/src/dlg_edit_avatar.cpp | 7 +------ cockatrice/src/dlg_edit_avatar.h | 1 - cockatrice/src/dlg_edit_password.cpp | 7 +------ cockatrice/src/dlg_edit_password.h | 1 - cockatrice/src/dlg_edit_user.cpp | 7 +------ cockatrice/src/dlg_edit_user.h | 1 - cockatrice/src/dlg_forgotpasswordchallenge.cpp | 9 ++------- cockatrice/src/dlg_forgotpasswordchallenge.h | 1 - cockatrice/src/dlg_forgotpasswordrequest.cpp | 7 +------ cockatrice/src/dlg_forgotpasswordrequest.h | 1 - cockatrice/src/dlg_forgotpasswordreset.cpp | 9 ++------- cockatrice/src/dlg_forgotpasswordreset.h | 1 - cockatrice/src/dlg_register.cpp | 7 +------ cockatrice/src/dlg_register.h | 1 - 14 files changed, 9 insertions(+), 51 deletions(-) diff --git a/cockatrice/src/dlg_edit_avatar.cpp b/cockatrice/src/dlg_edit_avatar.cpp index 06228459..c6a1818f 100644 --- a/cockatrice/src/dlg_edit_avatar.cpp +++ b/cockatrice/src/dlg_edit_avatar.cpp @@ -29,7 +29,7 @@ DlgEditAvatar::DlgEditAvatar(QWidget *parent) : QDialog(parent) QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); connect(buttonBox, SIGNAL(accepted()), this, SLOT(actOk())); - connect(buttonBox, SIGNAL(rejected()), this, SLOT(actCancel())); + connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject())); QVBoxLayout *mainLayout = new QVBoxLayout; mainLayout->addLayout(grid); @@ -46,11 +46,6 @@ void DlgEditAvatar::actOk() accept(); } -void DlgEditAvatar::actCancel() -{ - reject(); -} - void DlgEditAvatar::actBrowse() { QString fileName = diff --git a/cockatrice/src/dlg_edit_avatar.h b/cockatrice/src/dlg_edit_avatar.h index cd72af50..ef033e5a 100644 --- a/cockatrice/src/dlg_edit_avatar.h +++ b/cockatrice/src/dlg_edit_avatar.h @@ -17,7 +17,6 @@ public: QByteArray getImage(); private slots: void actOk(); - void actCancel(); void actBrowse(); private: diff --git a/cockatrice/src/dlg_edit_password.cpp b/cockatrice/src/dlg_edit_password.cpp index b642b136..8cae0bc0 100644 --- a/cockatrice/src/dlg_edit_password.cpp +++ b/cockatrice/src/dlg_edit_password.cpp @@ -39,7 +39,7 @@ DlgEditPassword::DlgEditPassword(QWidget *parent) : QDialog(parent) QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); connect(buttonBox, SIGNAL(accepted()), this, SLOT(actOk())); - connect(buttonBox, SIGNAL(rejected()), this, SLOT(actCancel())); + connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject())); QVBoxLayout *mainLayout = new QVBoxLayout; mainLayout->addLayout(grid); @@ -62,8 +62,3 @@ void DlgEditPassword::actOk() settingsCache->servers().setPassword(newPasswordEdit->text()); accept(); } - -void DlgEditPassword::actCancel() -{ - reject(); -} diff --git a/cockatrice/src/dlg_edit_password.h b/cockatrice/src/dlg_edit_password.h index 23009639..6c45e0eb 100644 --- a/cockatrice/src/dlg_edit_password.h +++ b/cockatrice/src/dlg_edit_password.h @@ -24,7 +24,6 @@ public: } private slots: void actOk(); - void actCancel(); private: QLabel *oldPasswordLabel, *newPasswordLabel, *newPasswordLabel2; diff --git a/cockatrice/src/dlg_edit_user.cpp b/cockatrice/src/dlg_edit_user.cpp index 7b93ee90..23f16f7f 100644 --- a/cockatrice/src/dlg_edit_user.cpp +++ b/cockatrice/src/dlg_edit_user.cpp @@ -45,7 +45,7 @@ DlgEditUser::DlgEditUser(QWidget *parent, QString email, QString country, QStrin QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); connect(buttonBox, SIGNAL(accepted()), this, SLOT(actOk())); - connect(buttonBox, SIGNAL(rejected()), this, SLOT(actCancel())); + connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject())); QVBoxLayout *mainLayout = new QVBoxLayout; mainLayout->addLayout(grid); @@ -61,8 +61,3 @@ void DlgEditUser::actOk() { accept(); } - -void DlgEditUser::actCancel() -{ - reject(); -} diff --git a/cockatrice/src/dlg_edit_user.h b/cockatrice/src/dlg_edit_user.h index 2bd1f56f..49da4b30 100644 --- a/cockatrice/src/dlg_edit_user.h +++ b/cockatrice/src/dlg_edit_user.h @@ -35,7 +35,6 @@ public: } private slots: void actOk(); - void actCancel(); private: QLabel *emailLabel, *countryLabel, *realnameLabel; diff --git a/cockatrice/src/dlg_forgotpasswordchallenge.cpp b/cockatrice/src/dlg_forgotpasswordchallenge.cpp index b9418f52..8ae4404c 100644 --- a/cockatrice/src/dlg_forgotpasswordchallenge.cpp +++ b/cockatrice/src/dlg_forgotpasswordchallenge.cpp @@ -31,7 +31,7 @@ DlgForgotPasswordChallenge::DlgForgotPasswordChallenge(QWidget *parent) : QDialo QMessageBox::warning(this, tr("Forgot Password Challenge Warning"), tr("Oops, looks like something has gone wrong. Please restart the forgot password " "process by using the forgot password button on the connection screen.")); - actCancel(); + reject(); } hostLabel = new QLabel(tr("&Host:")); @@ -72,7 +72,7 @@ DlgForgotPasswordChallenge::DlgForgotPasswordChallenge(QWidget *parent) : QDialo QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); connect(buttonBox, SIGNAL(accepted()), this, SLOT(actOk())); - connect(buttonBox, SIGNAL(rejected()), this, SLOT(actCancel())); + connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject())); QVBoxLayout *mainLayout = new QVBoxLayout; mainLayout->addLayout(grid); @@ -97,8 +97,3 @@ void DlgForgotPasswordChallenge::actOk() accept(); } - -void DlgForgotPasswordChallenge::actCancel() -{ - reject(); -} diff --git a/cockatrice/src/dlg_forgotpasswordchallenge.h b/cockatrice/src/dlg_forgotpasswordchallenge.h index f8503aa5..8631b08c 100644 --- a/cockatrice/src/dlg_forgotpasswordchallenge.h +++ b/cockatrice/src/dlg_forgotpasswordchallenge.h @@ -32,7 +32,6 @@ public: } private slots: void actOk(); - void actCancel(); private: QLabel *hostLabel, *portLabel, *playernameLabel, *emailLabel; diff --git a/cockatrice/src/dlg_forgotpasswordrequest.cpp b/cockatrice/src/dlg_forgotpasswordrequest.cpp index ac87a9c8..38dec831 100644 --- a/cockatrice/src/dlg_forgotpasswordrequest.cpp +++ b/cockatrice/src/dlg_forgotpasswordrequest.cpp @@ -48,7 +48,7 @@ DlgForgotPasswordRequest::DlgForgotPasswordRequest(QWidget *parent) : QDialog(pa QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); connect(buttonBox, SIGNAL(accepted()), this, SLOT(actOk())); - connect(buttonBox, SIGNAL(rejected()), this, SLOT(actCancel())); + connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject())); QVBoxLayout *mainLayout = new QVBoxLayout; mainLayout->addLayout(grid); @@ -73,8 +73,3 @@ void DlgForgotPasswordRequest::actOk() accept(); } - -void DlgForgotPasswordRequest::actCancel() -{ - reject(); -} diff --git a/cockatrice/src/dlg_forgotpasswordrequest.h b/cockatrice/src/dlg_forgotpasswordrequest.h index d7da9e09..00698498 100644 --- a/cockatrice/src/dlg_forgotpasswordrequest.h +++ b/cockatrice/src/dlg_forgotpasswordrequest.h @@ -28,7 +28,6 @@ public: } private slots: void actOk(); - void actCancel(); private: QLabel *hostLabel, *portLabel, *playernameLabel; diff --git a/cockatrice/src/dlg_forgotpasswordreset.cpp b/cockatrice/src/dlg_forgotpasswordreset.cpp index dbfb6d29..85989452 100644 --- a/cockatrice/src/dlg_forgotpasswordreset.cpp +++ b/cockatrice/src/dlg_forgotpasswordreset.cpp @@ -31,7 +31,7 @@ DlgForgotPasswordReset::DlgForgotPasswordReset(QWidget *parent) : QDialog(parent QMessageBox::warning(this, tr("Forgot Password Reset Warning"), tr("Opps, looks like something has gone wrong. Please re-start the forgot password " "process by using the forgot password button on the connection screen.")); - actCancel(); + reject(); } hostLabel = new QLabel(tr("&Host:")); @@ -86,7 +86,7 @@ DlgForgotPasswordReset::DlgForgotPasswordReset(QWidget *parent) : QDialog(parent QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); connect(buttonBox, SIGNAL(accepted()), this, SLOT(actOk())); - connect(buttonBox, SIGNAL(rejected()), this, SLOT(actCancel())); + connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject())); QVBoxLayout *mainLayout = new QVBoxLayout; mainLayout->addLayout(grid); @@ -126,8 +126,3 @@ void DlgForgotPasswordReset::actOk() accept(); } - -void DlgForgotPasswordReset::actCancel() -{ - reject(); -} diff --git a/cockatrice/src/dlg_forgotpasswordreset.h b/cockatrice/src/dlg_forgotpasswordreset.h index 41c593a1..de1c9b74 100644 --- a/cockatrice/src/dlg_forgotpasswordreset.h +++ b/cockatrice/src/dlg_forgotpasswordreset.h @@ -36,7 +36,6 @@ public: } private slots: void actOk(); - void actCancel(); private: QLabel *hostLabel, *portLabel, *playernameLabel, *tokenLabel, *newpasswordLabel, *newpasswordverifyLabel; diff --git a/cockatrice/src/dlg_register.cpp b/cockatrice/src/dlg_register.cpp index d9deb94c..b7f54b20 100644 --- a/cockatrice/src/dlg_register.cpp +++ b/cockatrice/src/dlg_register.cpp @@ -326,7 +326,7 @@ DlgRegister::DlgRegister(QWidget *parent) : QDialog(parent) QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel); connect(buttonBox, SIGNAL(accepted()), this, SLOT(actOk())); - connect(buttonBox, SIGNAL(rejected()), this, SLOT(actCancel())); + connect(buttonBox, SIGNAL(rejected()), this, SLOT(reject())); QVBoxLayout *mainLayout = new QVBoxLayout; mainLayout->addLayout(grid); @@ -361,8 +361,3 @@ void DlgRegister::actOk() accept(); } - -void DlgRegister::actCancel() -{ - reject(); -} diff --git a/cockatrice/src/dlg_register.h b/cockatrice/src/dlg_register.h index 287a5856..b2bc579c 100644 --- a/cockatrice/src/dlg_register.h +++ b/cockatrice/src/dlg_register.h @@ -48,7 +48,6 @@ public: } private slots: void actOk(); - void actCancel(); private: QLabel *hostLabel, *portLabel, *playernameLabel, *passwordLabel, *passwordConfirmationLabel, *emailLabel,