Drop static_cast from connections

These signals are not overloaded anymore in Qt 6.

Change-Id: Iefe9c588440069120fd71fecbd2b424afbf757c6
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Jarek Kobus
2022-11-02 16:41:19 +01:00
parent c86b86b254
commit a0623a0266
3 changed files with 3 additions and 5 deletions

View File

@@ -91,8 +91,7 @@ void LauncherInterfacePrivate::doStart()
} }
m_process = new LauncherProcess(this); m_process = new LauncherProcess(this);
connect(m_process, &QProcess::errorOccurred, this, &LauncherInterfacePrivate::handleProcessError); connect(m_process, &QProcess::errorOccurred, this, &LauncherInterfacePrivate::handleProcessError);
connect(m_process, connect(m_process, &QProcess::finished,
static_cast<void (QProcess::*)(int, QProcess::ExitStatus)>(&QProcess::finished),
this, &LauncherInterfacePrivate::handleProcessFinished); this, &LauncherInterfacePrivate::handleProcessFinished);
connect(m_process, &QProcess::readyReadStandardError, connect(m_process, &QProcess::readyReadStandardError,
this, &LauncherInterfacePrivate::handleProcessStderr); this, &LauncherInterfacePrivate::handleProcessStderr);

View File

@@ -84,7 +84,7 @@ public:
m_iconButton->setIcon(Icons::REPLACE.icon()); m_iconButton->setIcon(Icons::REPLACE.icon());
m_iconButton->setToolTip(VariableChooser::tr("Insert Variable")); m_iconButton->setToolTip(VariableChooser::tr("Insert Variable"));
m_iconButton->hide(); m_iconButton->hide();
connect(m_iconButton.data(), static_cast<void(QAbstractButton::*)(bool)>(&QAbstractButton::clicked), connect(m_iconButton.data(), &QAbstractButton::clicked,
this, &VariableChooserPrivate::updatePositionAndShow); this, &VariableChooserPrivate::updatePositionAndShow);
} }

View File

@@ -254,8 +254,7 @@ Process *LauncherSocketHandler::setupProcess(quintptr token)
const auto p = new Process(token, this); const auto p = new Process(token, this);
connect(p, &QProcess::started, this, [this, p] { handleProcessStarted(p); }); connect(p, &QProcess::started, this, [this, p] { handleProcessStarted(p); });
connect(p, &QProcess::errorOccurred, this, [this, p] { handleProcessError(p); }); connect(p, &QProcess::errorOccurred, this, [this, p] { handleProcessError(p); });
connect(p, static_cast<void (QProcess::*)(int, QProcess::ExitStatus)>(&QProcess::finished), connect(p, &QProcess::finished, this, [this, p] { handleProcessFinished(p); });
this, [this, p] { handleProcessFinished(p); });
connect(p, &QProcess::readyReadStandardOutput, connect(p, &QProcess::readyReadStandardOutput,
this, [this, p] { handleReadyReadStandardOutput(p); }); this, [this, p] { handleReadyReadStandardOutput(p); });
connect(p, &QProcess::readyReadStandardError, connect(p, &QProcess::readyReadStandardError,