diff --git a/src/plugins/qt4projectmanager/wizards/targetsetuppage.cpp b/src/plugins/qt4projectmanager/wizards/targetsetuppage.cpp index b93e2eb85c2..94cff921422 100644 --- a/src/plugins/qt4projectmanager/wizards/targetsetuppage.cpp +++ b/src/plugins/qt4projectmanager/wizards/targetsetuppage.cpp @@ -68,6 +68,8 @@ TargetSetupPage::TargetSetupPage(QWidget *parent) : connect(m_ui->importButton, SIGNAL(clicked()), this, SLOT(addShadowBuildLocation())); + connect(m_ui->uncheckButton, SIGNAL(clicked()), + this, SLOT(uncheckAll())); connect(m_ui->versionTree, SIGNAL(itemDoubleClicked(QTreeWidgetItem*,int)), this, SLOT(handleDoubleClicks(QTreeWidgetItem*,int))); } @@ -286,7 +288,7 @@ void TargetSetupPage::setProFilePath(const QString &path) { m_proFilePath = path; if (!m_proFilePath.isEmpty()) { - m_ui->descriptionLabel->setText(tr("Qt Creator can set up the following targets for project %1:", + m_ui->descriptionLabel->setText(tr("Qt Creator can set up the following targets for
project %1:", "%1: Project name").arg(QFileInfo(m_proFilePath).baseName())); } // Force regeneration of tree widget contents: @@ -411,6 +413,17 @@ void TargetSetupPage::addShadowBuildLocation() setImportInfos(tmp); } +void TargetSetupPage::uncheckAll() +{ + for (int i = 0; i < m_ui->versionTree->topLevelItemCount(); ++i) { + QTreeWidgetItem *current = m_ui->versionTree->topLevelItem(i); + for (int j = 0; j < current->childCount(); ++j) { + QTreeWidgetItem *child = current->child(j); + child->setCheckState(0, Qt::Unchecked); + } + } +} + void TargetSetupPage::handleDoubleClicks(QTreeWidgetItem *item, int column) { int idx = item->data(NAME_COLUMN, Qt::UserRole).toInt(); diff --git a/src/plugins/qt4projectmanager/wizards/targetsetuppage.h b/src/plugins/qt4projectmanager/wizards/targetsetuppage.h index 464c9399f99..ba535a33164 100644 --- a/src/plugins/qt4projectmanager/wizards/targetsetuppage.h +++ b/src/plugins/qt4projectmanager/wizards/targetsetuppage.h @@ -119,6 +119,7 @@ public slots: private slots: void itemWasChanged(); void addShadowBuildLocation(); + void uncheckAll(); void handleDoubleClicks(QTreeWidgetItem *, int); private: diff --git a/src/plugins/qt4projectmanager/wizards/targetsetuppage.ui b/src/plugins/qt4projectmanager/wizards/targetsetuppage.ui index 42e73387d10..ae002ef76cc 100644 --- a/src/plugins/qt4projectmanager/wizards/targetsetuppage.ui +++ b/src/plugins/qt4projectmanager/wizards/targetsetuppage.ui @@ -6,7 +6,7 @@ 0 0 - 550 + 555 450 @@ -15,17 +15,53 @@ - - - Qt Creator can set up the following targets: - - - true - - - Qt::NoTextInteraction - - + + + + + + 0 + 0 + + + + Qt Creator can set up the following targets: + + + false + + + Qt::NoTextInteraction + + + + + + + Qt::Horizontal + + + QSizePolicy::MinimumExpanding + + + + 13 + 13 + + + + + + + + Uncheck all Qt versions + + + uncheck all + + + +