chore: df-gui mainwindow directly connect more methods without intermediarty methods

This commit is contained in:
sithlord48
2025-02-10 21:14:39 -05:00
committed by Nick Bolton
parent cad1243d75
commit a5f28616f4
2 changed files with 3 additions and 21 deletions

View File

@ -237,15 +237,15 @@ void MainWindow::connectSlots()
connect(&m_configScopes, &ConfigScopes::saving, this, &MainWindow::configScopesSaving, Qt::DirectConnection);
connect(&m_appConfig, &AppConfig::tlsChanged, this, &MainWindow::appConfigTlsChanged);
connect(&m_appConfig, &AppConfig::screenNameChanged, this, &MainWindow::appConfigScreenNameChanged);
connect(&m_appConfig, &AppConfig::invertConnectionChanged, this, &MainWindow::appConfigInvertConnection);
connect(&m_appConfig, &AppConfig::screenNameChanged, this, &MainWindow::updateScreenName);
connect(&m_appConfig, &AppConfig::invertConnectionChanged, this, &MainWindow::applyConfig);
connect(&m_coreProcess, &CoreProcess::starting, this, &MainWindow::coreProcessStarting, Qt::DirectConnection);
connect(&m_coreProcess, &CoreProcess::error, this, &MainWindow::coreProcessError);
connect(&m_coreProcess, &CoreProcess::logLine, this, &MainWindow::handleLogLine);
connect(&m_coreProcess, &CoreProcess::processStateChanged, this, &MainWindow::coreProcessStateChanged);
connect(&m_coreProcess, &CoreProcess::connectionStateChanged, this, &MainWindow::coreConnectionStateChanged);
connect(&m_coreProcess, &CoreProcess::secureSocket, this, &MainWindow::coreProcessSecureSocket);
connect(&m_coreProcess, &CoreProcess::secureSocket, this, &MainWindow::secureSocket);
connect(m_actionAbout, &QAction::triggered, this, &MainWindow::openAboutDialog);
connect(m_actionClearSettings, &QAction::triggered, this, &MainWindow::clearSettings);
@ -354,16 +354,6 @@ void MainWindow::versionCheckerUpdateFound(const QString &version)
ui->lblUpdate->setText(text);
}
void MainWindow::appConfigScreenNameChanged()
{
updateScreenName();
}
void MainWindow::appConfigInvertConnection()
{
applyConfig();
}
void MainWindow::coreProcessError(CoreProcess::Error error)
{
if (error == CoreProcess::Error::AddressMissing) {
@ -761,11 +751,6 @@ void MainWindow::showFirstConnectedMessage()
messages::showFirstConnectedMessage(this, m_appConfig.closeToTray(), m_appConfig.enableService(), isServer);
}
void MainWindow::coreProcessSecureSocket(bool enabled)
{
secureSocket(enabled);
}
void MainWindow::updateStatus()
{
const auto connection = m_coreProcess.connectionState();

View File

@ -98,13 +98,10 @@ private:
void configScopesSaving();
void appConfigTlsChanged();
void appConfigScreenNameChanged();
void appConfigInvertConnection();
void coreProcessStarting();
void coreProcessError(CoreProcess::Error error);
void coreConnectionStateChanged(CoreProcess::ConnectionState state);
void coreProcessStateChanged(CoreProcess::ProcessState state);
void coreProcessSecureSocket(bool enabled);
void versionCheckerUpdateFound(const QString &version);
void trayIconActivated(QSystemTrayIcon::ActivationReason reason);
void serverConnectionConfigureClient(const QString &clientName);