Qt6: Fixed connections (#4436)

In UserChart and DownloadRideDialog the deprecated signal QComboBox::currentIndexChanged(QString)
was connected to a slot without parameters. In Qt6 this created a warning.
Changed to signal QComboBox::currentIndexChanged(int)
This commit is contained in:
Joachim Kohlhammer
2024-01-14 16:44:29 +01:00
committed by GitHub
parent b9e6542a90
commit 138c68a4e6
3 changed files with 5 additions and 7 deletions

View File

@@ -958,9 +958,9 @@ UserChartSettings::UserChartSettings(Context *context, bool rangemode, GenericCh
// watch for chartinfo edits (the series/axis stuff is managed by separate dialogs)
connect(title, SIGNAL(textChanged(QString)), this, SLOT(updateChartInfo()));
connect(description, SIGNAL(textChanged()), this, SLOT(updateChartInfo()));
connect(type, SIGNAL(currentIndexChanged(QString)), this, SLOT(updateChartInfo()));
connect(type, SIGNAL(currentIndexChanged(int)), this, SLOT(updateChartInfo()));
connect(animate, SIGNAL(stateChanged(int)), this, SLOT(updateChartInfo()));
connect(legpos, SIGNAL(currentIndexChanged(QString)), this, SLOT(updateChartInfo()));
connect(legpos, SIGNAL(currentIndexChanged(int)), this, SLOT(updateChartInfo()));
connect(stack, SIGNAL(stateChanged(int)), this, SLOT(updateChartInfo()));
connect(intervalrefresh, SIGNAL(stateChanged(int)), this, SLOT(updateChartInfo()));
connect(orientation, SIGNAL(currentIndexChanged(int)), this, SLOT(updateChartInfo()));

View File

@@ -50,7 +50,7 @@ DownloadRideDialog::DownloadRideDialog(Context *context, bool embedded) :
int idx = deviceCombo->findText( defaultDevice );
if( idx >= 0 )
deviceCombo->setCurrentIndex( idx );
connect(deviceCombo, SIGNAL(currentIndexChanged(QString)), this, SLOT(deviceChanged(QString)));
connect(deviceCombo, SIGNAL(currentIndexChanged(int)), this, SLOT(deviceChanged()));
portCombo = new QComboBox(this);
@@ -270,10 +270,8 @@ DownloadRideDialog::updateProgress( const QString &progressText )
void
DownloadRideDialog::deviceChanged( QString deviceType )
DownloadRideDialog::deviceChanged()
{
(void)deviceType;
updateAction(action); // adjust erase button visibility
updatePort();
}

View File

@@ -56,7 +56,7 @@ class DownloadRideDialog : public QDialog
void closeClicked();
void setReadyInstruct();
void scanCommPorts();
void deviceChanged(QString);
void deviceChanged();
void updateStatus(const QString &statusText);
void updateProgress(const QString &progressText);