| 151 | } |
| 152 | |
| 153 | void CursorDock::resultCopy() { |
| 154 | QString str; |
| 155 | auto* model = ui->tvCursorData->model(); |
| 156 | auto* selection = ui->tvCursorData->selectionModel(); |
| 157 | const auto& indices = selection->selectedRows(); |
| 158 | for (auto& index : indices) { |
| 159 | int row = index.row(); |
| 160 | auto parent = index.parent(); |
| 161 | for (int col = 0; col < model->columnCount(); ++col) { |
| 162 | if (col != 0) |
| 163 | str += QLatin1Char('\t'); |
| 164 | str += model->data(model->index(row, col, parent)).toString(); |
| 165 | } |
| 166 | |
| 167 | str += QLatin1Char('\n'); |
| 168 | } |
| 169 | |
| 170 | QApplication::clipboard()->setText(str); |
| 171 | } |
| 172 | |
| 173 | void CursorDock::resultCopyAll() { |
| 174 | QString str; |
nothing calls this directly
no test coverage detected