summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Murzeau <amubtdx@gmail.com>2019-10-11 23:46:08 +0200
committerAlexis Murzeau <amubtdx@gmail.com>2019-10-15 19:37:10 +0000
commitc7cb7672f0c0457477bbcd0fbd64af9874e42a98 (patch)
tree391fdd72b1eb7dbe0f3bfc472f03bb5023905a8b
parent9dd96adb7c0f2e551fd0d804a44e49f577685f77 (diff)
downloadqt-creator-c7cb7672f0c0457477bbcd0fbd64af9874e42a98.tar.gz
AbiWidget: Fix custom abi comboboxes' enabled state when mainComboBox is changed
When the mainComboBox is updated and its current selection changed via setAbis, the custom ABI comboboxes weren't updated accordingly. This is because in setAbis when doing d->m_abi->setCurrentIndex(), the m_ignoreChanges guard is held which inhibit mainComboBoxChanged function from doing anything for performance reasons. But the effect of this is that custom ABI comboboxes were left in their previous state (enabled or disabled). This commit ensures the custom ABI comboboxes are updated according to the new selected item in the mainComboBox at the end of setAbis function. Change-Id: Iedabde412a42985697d2cba33ddb6c154f10a68f Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
-rw-r--r--src/plugins/projectexplorer/abiwidget.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/plugins/projectexplorer/abiwidget.cpp b/src/plugins/projectexplorer/abiwidget.cpp
index 5df9a3ee05..319926dd54 100644
--- a/src/plugins/projectexplorer/abiwidget.cpp
+++ b/src/plugins/projectexplorer/abiwidget.cpp
@@ -188,7 +188,10 @@ void AbiWidget::setAbis(const Abis &abiList, const Abi &currentAbi)
setCustomAbiComboBoxes(defaultAbi);
}
- emitAbiChanged(defaultAbi);
+
+ // Update disabled state according to new automatically selected item in main ABI combobox.
+ // This will call emitAbiChanged with the actual selected ABI.
+ mainComboBoxChanged();
}
Abis AbiWidget::supportedAbis() const