ProjectExplorer: Limit the usage of qMakePair

Make the code less verbose.

Change-Id: If9fe08a6a7538d34c80ca97a2aec21a2bd6e5d22
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
Jarek Kobus
2022-09-30 15:57:27 +02:00
parent 50f2f57f6a
commit 898053533a
14 changed files with 56 additions and 61 deletions

View File

@@ -306,9 +306,8 @@ private:
parserCheckBoxes.clear();
for (const CustomParserSettings &s : ProjectExplorerPlugin::customParsers()) {
const auto checkBox = new QCheckBox(s.displayName, this);
connect(checkBox, &QCheckBox::stateChanged,
this, &SelectionWidget::selectionChanged);
parserCheckBoxes << qMakePair(checkBox, s.id);
connect(checkBox, &QCheckBox::stateChanged, this, &SelectionWidget::selectionChanged);
parserCheckBoxes.push_back({checkBox, s.id});
layout->addWidget(checkBox);
}
setSelectedParsers(parsers);