| 408 | } |
| 409 | |
| 410 | void App::handleConnectionError( |
| 411 | const QString &errorMessage, Data::SyncthingErrorCategory category, int networkError, const QNetworkRequest &request, const QByteArray &response) |
| 412 | { |
| 413 | if (!InternalError::isRelevant(*m_data.connection(), category, errorMessage, networkError, false, m_isManuallyStopped)) { |
| 414 | return; |
| 415 | } |
| 416 | qWarning() << "Connection error: " << errorMessage; |
| 417 | auto error = InternalError(errorMessage, request.url(), response); |
| 418 | emit internalError(error); |
| 419 | const auto emitHasInternalErrorsChanged = m_internalErrors.isEmpty(); |
| 420 | m_internalErrors.emplace_back(QVariant::fromValue(std::move(error))); |
| 421 | if (emitHasInternalErrorsChanged) { |
| 422 | invalidateStatus(); |
| 423 | emit hasInternalErrorsChanged(); |
| 424 | } |
| 425 | } |
| 426 | |
| 427 | void App::setCurrentControls(bool visible, int tabIndex) |
| 428 | { |
nothing calls this directly
no test coverage detected