| 95 | } |
| 96 | |
| 97 | void ProjectSelectionPage::typeChanged(const QModelIndex& idx) |
| 98 | { |
| 99 | if (!idx.model()) |
| 100 | { |
| 101 | qCDebug(PLUGIN_APPWIZARD) << "Index with no model"; |
| 102 | return; |
| 103 | } |
| 104 | int children = idx.model()->rowCount(idx); |
| 105 | ui->templateType->setVisible(children); |
| 106 | ui->templateType->setEnabled(children > 1); |
| 107 | if (children) { |
| 108 | ui->templateType->setModel(m_templatesModel); |
| 109 | ui->templateType->setRootModelIndex(idx); |
| 110 | ui->templateType->setCurrentIndex(0); |
| 111 | itemChanged(idx.model()->index(0, 0, idx)); |
| 112 | } else { |
| 113 | itemChanged(idx); |
| 114 | } |
| 115 | } |
| 116 | |
| 117 | void ProjectSelectionPage::templateChanged(int current) |
| 118 | { |
nothing calls this directly
no test coverage detected