Drop Qt5: BareMetal: Get rid of QOverload

Change-Id: I023dee34b3b3556376c3cad5cbff919e6a85769c
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Jarek Kobus
2022-07-19 22:46:47 +02:00
parent 2e4188900f
commit ae4db886f3
12 changed files with 21 additions and 35 deletions

View File

@@ -57,7 +57,7 @@ DebugServerProviderChooser::DebugServerProviderChooser(
layout->addWidget(m_manageButton);
setFocusProxy(m_manageButton);
connect(m_chooser, QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_chooser, &QComboBox::currentIndexChanged,
this, &DebugServerProviderChooser::currentIndexChanged);
connect(m_manageButton, &QAbstractButton::clicked,
this, &DebugServerProviderChooser::manageButtonClicked);

View File

@@ -304,11 +304,9 @@ EBlinkGdbServerProviderConfigWidget::EBlinkGdbServerProviderConfigWidget(
this, &GdbServerProviderConfigWidget::dirty);
connect(m_scriptFileChooser, &Utils::PathChooser::rawPathChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_verboseLevelSpinBox,
QOverload<int>::of(&QSpinBox::valueChanged),
connect(m_verboseLevelSpinBox, &QSpinBox::valueChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_interfaceSpeedSpinBox,
QOverload<int>::of(&QSpinBox::valueChanged),
connect(m_interfaceSpeedSpinBox, &QSpinBox::valueChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_notUseCacheCheckBox, &QAbstractButton::clicked,
this, &GdbServerProviderConfigWidget::dirty);
@@ -316,8 +314,7 @@ EBlinkGdbServerProviderConfigWidget::EBlinkGdbServerProviderConfigWidget(
this, &GdbServerProviderConfigWidget::dirty);
connect(m_resetOnConnectCheckBox, &QAbstractButton::clicked,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_interfaceTypeComboBox,
QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_interfaceTypeComboBox, &QComboBox::currentIndexChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_initCommandsTextEdit, &QPlainTextEdit::textChanged,
this, &GdbServerProviderConfigWidget::dirty);

View File

@@ -239,10 +239,8 @@ GdbServerProviderConfigWidget::GdbServerProviderConfigWidget(
populateStartupModes();
setFromProvider();
connect(m_startupModeComboBox,
QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_startupModeComboBox, &QComboBox::currentIndexChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_peripheralDescriptionFileChooser, &PathChooser::filePathChanged,
this, &GdbServerProviderConfigWidget::dirty);
}

View File

@@ -280,11 +280,11 @@ JLinkGdbServerProviderConfigWidget::JLinkGdbServerProviderConfigWidget(
connect(m_targetInterfaceSpeedComboBox, &QComboBox::currentTextChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_hostInterfaceComboBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_hostInterfaceComboBox, &QComboBox::currentIndexChanged,
this, &JLinkGdbServerProviderConfigWidget::updateAllowedControls);
connect(m_targetInterfaceComboBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_targetInterfaceComboBox, &QComboBox::currentIndexChanged,
this, &JLinkGdbServerProviderConfigWidget::updateAllowedControls);
connect(m_targetInterfaceSpeedComboBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_targetInterfaceSpeedComboBox, &QComboBox::currentIndexChanged,
this, &JLinkGdbServerProviderConfigWidget::updateAllowedControls);
}

View File

@@ -247,7 +247,7 @@ OpenOcdGdbServerProviderConfigWidget::OpenOcdGdbServerProviderConfigWidget(
connect(m_resetCommandsTextEdit, &QPlainTextEdit::textChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_startupModeComboBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_startupModeComboBox, &QComboBox::currentIndexChanged,
this, &OpenOcdGdbServerProviderConfigWidget::startupModeChanged);
}

View File

@@ -230,15 +230,13 @@ StLinkUtilGdbServerProviderConfigWidget::StLinkUtilGdbServerProviderConfigWidget
connect(m_executableFileChooser, &Utils::PathChooser::rawPathChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_verboseLevelSpinBox,
QOverload<int>::of(&QSpinBox::valueChanged),
connect(m_verboseLevelSpinBox, &QSpinBox::valueChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_extendedModeCheckBox, &QAbstractButton::clicked,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_resetBoardCheckBox, &QAbstractButton::clicked,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_transportLayerComboBox,
QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_transportLayerComboBox, &QComboBox::currentIndexChanged,
this, &GdbServerProviderConfigWidget::dirty);
connect(m_initCommandsTextEdit, &QPlainTextEdit::textChanged,

View File

@@ -297,13 +297,11 @@ JLinkUvscAdapterOptionsWidget::JLinkUvscAdapterOptionsWidget(QWidget *parent)
populatePorts();
connect(m_portBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
this, [this](int index) {
Q_UNUSED(index);
connect(m_portBox, &QComboBox::currentIndexChanged, this, [this] {
populateSpeeds();
emit optionsChanged();
});
connect(m_speedBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_speedBox, &QComboBox::currentIndexChanged,
this, &JLinkUvscAdapterOptionsWidget::optionsChanged);
}

View File

@@ -253,13 +253,11 @@ StLinkUvscAdapterOptionsWidget::StLinkUvscAdapterOptionsWidget(QWidget *parent)
populatePorts();
connect(m_portBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
this, [this](int index) {
Q_UNUSED(index);
connect(m_portBox, &QComboBox::currentIndexChanged, this, [this] {
populateSpeeds();
emit optionsChanged();
});
connect(m_speedBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_speedBox, &QComboBox::currentIndexChanged,
this, &StLinkUvscAdapterOptionsWidget::optionsChanged);
}

View File

@@ -427,13 +427,12 @@ DeviceSelectionAlgorithmView::DeviceSelectionAlgorithmView(DeviceSelection &sele
mapper->addMapping(ramStartEdit, DeviceSelectionAlgorithmItem::RamStartColumn);
mapper->addMapping(ramSizeEdit, DeviceSelectionAlgorithmItem::RamSizeColumn);
connect(m_comboBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
this, [mapper, this](int index) {
connect(m_comboBox, &QComboBox::currentIndexChanged, this, [mapper, this](int index) {
mapper->setCurrentIndex(index);
emit algorithmChanged(index);
});
connect(model, &DeviceSelectionAlgorithmModel::dataChanged, this, [this]() {
connect(model, &DeviceSelectionAlgorithmModel::dataChanged, this, [this] {
emit algorithmChanged(-1);
});

View File

@@ -136,7 +136,7 @@ DeviceSelector::DeviceSelector(QWidget *parent)
const auto detailsPanel = new DeviceSelectorDetailsPanel(m_selection);
setWidget(detailsPanel);
connect(toolPanel, &DeviceSelectorToolPanel::clicked, this, [this]() {
connect(toolPanel, &DeviceSelectorToolPanel::clicked, this, [this] {
DeviceSelectionDialog dialog(m_toolsIniFile, this);
const int result = dialog.exec();
if (result != QDialog::Accepted)

View File

@@ -132,7 +132,7 @@ DriverSelectionCpuDllView::DriverSelectionCpuDllView(DriverSelection &selection,
layout->addWidget(m_comboBox);
setLayout(layout);
connect(m_comboBox, QOverload<int>::of(&QComboBox::currentIndexChanged),
connect(m_comboBox, &QComboBox::currentIndexChanged,
this, &DriverSelectionCpuDllView::dllChanged);
}

View File

@@ -348,10 +348,8 @@ HostWidget::HostWidget(QWidget *parent)
layout->addWidget(m_hostLineEdit);
layout->addWidget(m_portSpinBox);
connect(m_hostLineEdit, &QLineEdit::textChanged,
this, &HostWidget::dataChanged);
connect(m_portSpinBox, QOverload<int>::of(&QSpinBox::valueChanged),
this, &HostWidget::dataChanged);
connect(m_hostLineEdit, &QLineEdit::textChanged, this, &HostWidget::dataChanged);
connect(m_portSpinBox, &QSpinBox::valueChanged, this, &HostWidget::dataChanged);
}
void HostWidget::setChannel(const QUrl &channel)