| 193 | } |
| 194 | |
| 195 | void SessionListView::runInputDialog(SessionNameInputDialog *dialog, |
| 196 | std::function<void(const QString &)> handler) |
| 197 | { |
| 198 | if (dialog->exec() == QDialog::Accepted) { |
| 199 | const auto name = dialog->sessionName(); |
| 200 | if (name.isEmpty()) |
| 201 | return; |
| 202 | |
| 203 | handler(name); |
| 204 | model.reset(); |
| 205 | if (dialog->isSwitchToRequested()) { |
| 206 | SessionManager::instance()->loadSession(name); |
| 207 | Q_EMIT sessionSwitched(); |
| 208 | } |
| 209 | Q_EMIT sessionCreated(name); |
| 210 | } |
| 211 | } |
nothing calls this directly
no test coverage detected