diff options
| author | Felix (xq) Queißner <git@mq32.de> | 2020-06-17 10:22:08 +0200 |
|---|---|---|
| committer | Felix (xq) Queißner <git@mq32.de> | 2020-06-17 10:22:08 +0200 |
| commit | 0b86b204209d78f496721ac14ed33691d2c5db1e (patch) | |
| tree | b17f1cddc3820d260dda4d450c7b71c7dbd503ac /src/browsertab.cpp | |
| parent | 5b14fc424462a5d3a5a509bd177c04e9cba2ce17 (diff) | |
| download | kristall-0b86b204209d78f496721ac14ed33691d2c5db1e.tar.gz | |
Makes cancelling gemini requests more robust.
Diffstat (limited to 'src/browsertab.cpp')
| -rw-r--r-- | src/browsertab.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/browsertab.cpp b/src/browsertab.cpp index 09bb56c..359fd7c 100644 --- a/src/browsertab.cpp +++ b/src/browsertab.cpp @@ -570,8 +570,10 @@ void BrowserTab::updateUI() this->ui->back_button->setEnabled(history.oneBackward(current_history_index).isValid()); this->ui->forward_button->setEnabled(history.oneForward(current_history_index).isValid()); - this->ui->refresh_button->setVisible(this->successfully_loaded); - this->ui->stop_button->setVisible(not this->successfully_loaded); + bool in_progress = (this->current_handler != nullptr) and this->current_handler->isInProgress(); + + this->ui->refresh_button->setVisible(not in_progress); + this->ui->stop_button->setVisible(in_progress); this->ui->fav_button->setEnabled(this->successfully_loaded); this->ui->fav_button->setChecked(global_favourites.contains(this->current_location)); |
