| 201 | } |
| 202 | |
| 203 | void SessionNameInputDialog::handleButtonClicked(int index) |
| 204 | { |
| 205 | if (index == 0) |
| 206 | return reject(); |
| 207 | |
| 208 | const auto name = sessionName(); |
| 209 | if (SessionManager::instance()->sessionList().contains(name)) { |
| 210 | QString msg = tr("The session already exists, please re-enter."); |
| 211 | lineEdit->showAlertMessage(msg); |
| 212 | return; |
| 213 | } |
| 214 | |
| 215 | if (index == 2) |
| 216 | isSwitchTo = true; |
| 217 | |
| 218 | accept(); |
| 219 | } |
| 220 | |
| 221 | void SessionNameInputDialog::setSessionName(const QString &name) |
| 222 | { |
nothing calls this directly
no test coverage detected