Commit 5cbd34b0 authored by dt_'s avatar dt_

Show icon for invalid qt's without name

Task-Nr: QTCREATORBUG-4899
parent db2dd3e2
......@@ -667,11 +667,6 @@ void QtOptionsPageWidget::userChangedCurrentVersion()
void QtOptionsPageWidget::qtVersionChanged()
{
QTreeWidgetItem *item = m_ui->qtdirList->currentItem();
if (item) {
BaseQtVersion *version = currentVersion();
item->setIcon(0, version->isValid()? m_validVersionIcon : m_invalidVersionIcon);
}
updateDescriptionLabel();
updateDebuggingHelperUi();
}
......@@ -686,6 +681,9 @@ void QtOptionsPageWidget::updateDescriptionLabel()
version->description()));
else
m_versionUi->errorLabel->setText(version->invalidReason());
QTreeWidgetItem *item = m_ui->qtdirList->currentItem();
if (item)
item->setIcon(0, version->isValid()? m_validVersionIcon : m_invalidVersionIcon);
}
int QtOptionsPageWidget::indexForTreeItem(const QTreeWidgetItem *item) const
......@@ -777,6 +775,8 @@ void QtOptionsPageWidget::fixQtVersionName(int index)
return;
int count = m_versions.count();
QString name = m_versions.at(index)->displayName();
if (name.isEmpty())
return;
for (int i = 0; i < count; ++i) {
if (i != index) {
if (m_versions.at(i)->displayName() == m_versions.at(index)->displayName()) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment