summaryrefslogtreecommitdiffstats
path: root/src/gui.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui.cpp')
-rw-r--r--src/gui.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/gui.cpp b/src/gui.cpp
index ed0f54c..08b4475 100644
--- a/src/gui.cpp
+++ b/src/gui.cpp
@@ -25,6 +25,7 @@ static QString STATE_UPLOAD_DONE("UPLOAD_DONE"); // dnbd3-fuse signaled merge re
static QString STATE_PROCESSING("PROCESSING"); // Hashing, renaming, creating DB entry
static QString STATE_ERROR("ERROR");
static QString STATE_COMPLETELY_DONE("COMPLETELY_DONE");
+static QString STATE_CONN_ERROR("CONN_ERROR"); // Not a remote error, used when remote is unreachable
Gui::Gui(const QString &urlbase, const QString &uuid, int dnbd3pid, const QString &statusFile, QWidget *parent)
: QDialog(parent)
@@ -71,6 +72,7 @@ void Gui::queryRemoteStatus()
} else if (str.length() > 0 && str.length() < 160) {
_status->setText(QLatin1String("Server: ") + str);
} else {
+ _remoteState = STATE_CONN_ERROR;
_status->setText(tr("Fehler beim Statusabruf"));
}
return;
@@ -200,6 +202,9 @@ void Gui::updateButtons()
_btnAbort->setEnabled(false);
_btnOk->setEnabled(true);
_btnOk->setText(tr("Schließen"));
+ QFont f(_btnOk->font());
+ f.setBold(true);
+ _btnOk->setFont(f);
} else if (_remoteState == STATE_UPLOAD_DONE) {
setProgressState(tr("Änderungen hochladen"), 100, QString());
_btnAbort->setEnabled(true);
@@ -209,6 +214,9 @@ void Gui::updateButtons()
_btnOk->setEnabled(false);
_tmrStatus->stop();
_btnAbort->setText(tr("Schließen"));
+ QFont f(_btnAbort->font());
+ f.setBold(true);
+ _btnAbort->setFont(f);
} else {
_btnAbort->setEnabled(true);
_btnOk->setEnabled(false);