refactor(serverConfigDialog):rename accept -> save

This commit is contained in:
sithlord48 2026-08-13 04:26:12 -04:00 committed by Nick Bolton
parent 95923e0e90
commit 4db8c615bd
2 changed files with 3 additions and 4 deletions

View file

@ -56,7 +56,7 @@ bool ServerConfigDialog::addClient(const QString &clientName)
return addComputer(clientName, true); return addComputer(clientName, true);
} }
void ServerConfigDialog::accept() void ServerConfigDialog::save()
{ {
if (ui->groupExternalConfig->isChecked() && !QFile::exists(ui->lineConfigFile->text())) { if (ui->groupExternalConfig->isChecked() && !QFile::exists(ui->lineConfigFile->text())) {
@ -452,7 +452,7 @@ void ServerConfigDialog::loadFromConfig()
void ServerConfigDialog::initConnections() const void ServerConfigDialog::initConnections() const
{ {
connect(ui->buttonBox, &QDialogButtonBox::accepted, this, &ServerConfigDialog::accept); connect(ui->buttonBox, &QDialogButtonBox::accepted, this, &ServerConfigDialog::save);
connect(ui->buttonBox, &QDialogButtonBox::rejected, this, &ServerConfigDialog::cancel); connect(ui->buttonBox, &QDialogButtonBox::rejected, this, &ServerConfigDialog::cancel);
connect(ui->lblRemoveScreen, &TrashScreenWidget::screenRemoved, this, &ServerConfigDialog::onScreenRemoved); connect(ui->lblRemoveScreen, &TrashScreenWidget::screenRemoved, this, &ServerConfigDialog::onScreenRemoved);
connect(ui->btnNewHotkey, &QPushButton::clicked, this, &ServerConfigDialog::addHotkey); connect(ui->btnNewHotkey, &QPushButton::clicked, this, &ServerConfigDialog::addHotkey);

View file

@ -30,8 +30,6 @@ public:
bool addClient(const QString &clientName); bool addClient(const QString &clientName);
public Q_SLOTS: public Q_SLOTS:
void accept() override;
void message(const QString &message) void message(const QString &message)
{ {
m_message = message; m_message = message;
@ -90,6 +88,7 @@ protected:
} }
private: private:
void save();
void cancel(); void cancel();
void loadFromConfig(); void loadFromConfig();
void initConnections() const; void initConnections() const;