MCPcopy Create free account
hub / github.com/deskflow/deskflow / accept

Method accept

src/lib/gui/dialogs/ServerConfigDialog.cpp:183–201  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

181}
182
183void ServerConfigDialog::accept()
184{
185 if (ui->groupExternalConfig->isChecked() && !QFile::exists(ui->lineConfigFile->text())) {
186
187 auto selectedButton = QMessageBox::warning(
188 this, "Filename invalid", "Please select a valid configuration file.", QMessageBox::Ok | QMessageBox::Ignore
189 );
190
191 if (selectedButton != QMessageBox::Ok || !browseConfigFile()) {
192 return;
193 }
194 }
195
196 // now that the dialog has been accepted, copy the new server config to the
197 // original one, which is a reference to the one in MainWindow.
198 setOriginalServerConfig(serverConfig());
199
200 QDialog::accept();
201}
202
203void ServerConfigDialog::reject()
204{

Callers

nothing calls this directly

Calls 1

textMethod · 0.45

Tested by

no test coverage detected