Commit 3c4122b8 authored by con's avatar con
Browse files

Fix showing MWC path in Qt preference page.

parent 7b04fc45
...@@ -301,13 +301,13 @@ void QtOptionsPageWidget::showEnvironmentPage(QTreeWidgetItem *item) ...@@ -301,13 +301,13 @@ void QtOptionsPageWidget::showEnvironmentPage(QTreeWidgetItem *item)
return; return;
} }
m_ui->errorLabel->setText(""); m_ui->errorLabel->setText("");
ProjectExplorer::ToolChain::ToolChainType t = m_versions.at(index)->defaultToolchainType(); QList<ProjectExplorer::ToolChain::ToolChainType> types = m_versions.at(index)->possibleToolChainTypes();
if (t == ProjectExplorer::ToolChain::MinGW) { if (types.contains(ProjectExplorer::ToolChain::MinGW)) {
makeMSVCVisible(false); makeMSVCVisible(false);
makeMingwVisible(true); makeMingwVisible(true);
makeMWCVisible(false); makeMWCVisible(false);
m_ui->mingwPath->setPath(m_versions.at(index)->mingwDirectory()); m_ui->mingwPath->setPath(m_versions.at(index)->mingwDirectory());
} else if (t == ProjectExplorer::ToolChain::MSVC || t == ProjectExplorer::ToolChain::WINCE){ } else if (types.contains(ProjectExplorer::ToolChain::MSVC) || types.contains(ProjectExplorer::ToolChain::WINCE)){
makeMSVCVisible(false); makeMSVCVisible(false);
makeMingwVisible(false); makeMingwVisible(false);
makeMWCVisible(false); makeMWCVisible(false);
...@@ -328,13 +328,13 @@ void QtOptionsPageWidget::showEnvironmentPage(QTreeWidgetItem *item) ...@@ -328,13 +328,13 @@ void QtOptionsPageWidget::showEnvironmentPage(QTreeWidgetItem *item)
m_ui->msvcComboBox->blockSignals(block); m_ui->msvcComboBox->blockSignals(block);
} }
#ifdef QTCREATOR_WITH_S60 #ifdef QTCREATOR_WITH_S60
} else if (t == ProjectExplorer::ToolChain::WINSCW) { } else if (types.contains(ProjectExplorer::ToolChain::WINSCW)) {
makeMSVCVisible(false); makeMSVCVisible(false);
makeMingwVisible(false); makeMingwVisible(false);
makeMWCVisible(true); makeMWCVisible(true);
m_ui->mwcPath->setPath(m_versions.at(index)->mwcDirectory()); m_ui->mwcPath->setPath(m_versions.at(index)->mwcDirectory());
#endif #endif
} else if (t == ProjectExplorer::ToolChain::INVALID) { } else if (types.contains(ProjectExplorer::ToolChain::INVALID)) {
makeMSVCVisible(false); makeMSVCVisible(false);
makeMingwVisible(false); makeMingwVisible(false);
makeMWCVisible(false); makeMWCVisible(false);
......
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