Browse Source

SDX talks to dragonxd

pull/112/head
Duke 1 year ago
parent
commit
3da01807e5
  1. 17
      src/connection.cpp

17
src/connection.cpp

@ -68,7 +68,11 @@ void ConnectionLoader::doAutoConnect(bool tryEhushdStart) {
// Refused connection. So try and start embedded hushd
if (Settings::getInstance()->useEmbedded()) {
if (tryEhushdStart) {
this->showInformation(QObject::tr("Starting embedded hushd"));
if(isdragonx) {
this->showInformation(QObject::tr("Starting embedded dragonxd"));
} else {
this->showInformation(QObject::tr("Starting embedded hushd"));
}
if (this->startEmbeddedHushd()) {
// Embedded hushd started up. Wait a second and then refresh the connection
main->logger->write("Embedded hushd started up, trying autoconnect in 1 sec");
@ -544,6 +548,11 @@ void ConnectionLoader::refreshHushdState(Connection* connection, std::function<v
QString explanation = QString() %
QObject::tr("Authentication failed. The username / password you specified was "
"not accepted by hushd. Try changing it in the Edit->Settings menu");
if(isdragonx) {
explanation = QString() %
QObject::tr("Authentication failed. The username / password you specified was "
"not accepted by dragonxd. Try changing it in the Edit->Settings menu");
}
this->showError(explanation);
} else if (err == QNetworkReply::NetworkError::InternalServerError &&
@ -557,7 +566,11 @@ void ConnectionLoader::refreshHushdState(Connection* connection, std::function<v
if (dots > 3)
dots = 0;
}
this->showInformation(QObject::tr("Your hushd is starting up. Please wait."), status);
if(isdragonx) {
this->showInformation(QObject::tr("Your dragonxd is starting up. Please wait."), status);
} else {
this->showInformation(QObject::tr("Your hushd is starting up. Please wait."), status);
}
main->logger->write("Waiting for hushd to come online.");
// Refresh after one second
QTimer::singleShot(1000, [=]() { this->refreshHushdState(connection, refused); });

Loading…
Cancel
Save