diff options
| author | Max Christian Pohle | 2015-11-28 01:18:21 +0100 |
|---|---|---|
| committer | Max Christian Pohle | 2015-11-28 01:18:21 +0100 |
| commit | 89fada0440c1e3b72afc01cb3052995446a2857d (patch) | |
| tree | acfdc8646bbc7fcbe37280296be197853785acad /mainwindow.cpp | |
| parent | 84ddfad36dc961e987fd15a7433594ccb837fddf (diff) | |
| download | qspacestatus-89fada0440c1e3b72afc01cb3052995446a2857d.tar.bz2 qspacestatus-89fada0440c1e3b72afc01cb3052995446a2857d.zip | |
refresh button fixes issues caused by former network connection error
Diffstat (limited to 'mainwindow.cpp')
| -rw-r--r-- | mainwindow.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/mainwindow.cpp b/mainwindow.cpp index 9385cd6..6149e0c 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp | |||
| @@ -55,6 +55,11 @@ void MainWindow::updateSpaceList() | |||
| 55 | ui->comboBox->setCurrentIndex(ui->comboBox->count()-1); | 55 | ui->comboBox->setCurrentIndex(ui->comboBox->count()-1); |
| 56 | } | 56 | } |
| 57 | ui->comboBox->setDisabled(false); | 57 | ui->comboBox->setDisabled(false); |
| 58 | |||
| 59 | // in case of a bad network connection the combobox might show an element | ||
| 60 | // but does not download data. clicking refresh does not solve that, because | ||
| 61 | // setCurrentIndex does not trigger a refresh in that (rare) case... | ||
| 62 | this->updateStatus(); // fixes case where setCurrentIndex does not call on_comboBox_currentIndexChanged | ||
| 58 | } | 63 | } |
| 59 | 64 | ||
| 60 | QJsonObject json_find(QJsonObject json, QStringList list) | 65 | QJsonObject json_find(QJsonObject json, QStringList list) |
