aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorflow <flowlnlnln@gmail.com>2022-12-16 20:19:33 -0300
committerflow <flowlnlnln@gmail.com>2023-01-13 16:23:06 -0300
commitef87bdf18acb549c1ad9a3eda69d8dff5ad8da8e (patch)
treeead43d8f7bfbff4ec32dd2b430ff0169333da395
parent433a802c6ed3070b1b2f4435937a456eb4192f78 (diff)
downloadPrismLauncher-ef87bdf18acb549c1ad9a3eda69d8dff5ad8da8e.tar.gz
PrismLauncher-ef87bdf18acb549c1ad9a3eda69d8dff5ad8da8e.tar.bz2
PrismLauncher-ef87bdf18acb549c1ad9a3eda69d8dff5ad8da8e.zip
fix(RD): prevent weird behavior of progress widget
when i.e. clicking on links or just using the downloader at all, this prevents some flickering and the widget never getting hidden in some cases. Signed-off-by: flow <flowlnlnln@gmail.com>
-rw-r--r--launcher/ui/widgets/ProgressWidget.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/launcher/ui/widgets/ProgressWidget.cpp b/launcher/ui/widgets/ProgressWidget.cpp
index 18b51fc3..f736af08 100644
--- a/launcher/ui/widgets/ProgressWidget.cpp
+++ b/launcher/ui/widgets/ProgressWidget.cpp
@@ -54,7 +54,10 @@ void ProgressWidget::watch(const Task* task)
connect(m_task, &Task::progress, this, &ProgressWidget::handleTaskProgress);
connect(m_task, &Task::destroyed, this, &ProgressWidget::taskDestroyed);
- show();
+ if (m_task->isRunning())
+ show();
+ else
+ connect(m_task, &Task::started, this, &ProgressWidget::show);
}
void ProgressWidget::start(const Task* task)