| 116 | } |
| 117 | |
| 118 | void MainWindow::itemClicked(const QModelIndex &index) |
| 119 | { |
| 120 | QItemSelectionModel::SelectionFlags command = QItemSelectionModel::Clear | QItemSelectionModel::Select; |
| 121 | if (QApplication::keyboardModifiers() & Qt::ControlModifier) |
| 122 | command = QItemSelectionModel::Toggle; |
| 123 | m_selectionModel->setCurrentIndex(static_cast<const QAbstractProxyModel *>(index.model()) |
| 124 | ->mapToSource(index), |
| 125 | command); |
| 126 | } |
| 127 | |
| 128 | void MainWindow::selectionChanged(const QItemSelection &selected, const QItemSelection &deselected) |
| 129 | { |
nothing calls this directly
no test coverage detected