From 646ba94d1031e9ded5763b585a075595a4722e1a Mon Sep 17 00:00:00 2001 From: Dan Albert Date: Sat, 30 Jan 2021 20:25:34 -0800 Subject: [PATCH] Make UI update faster on TOT change. Fixes https://github.com/Khopa/dcs_liberation/issues/815 --- qt_ui/models.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/qt_ui/models.py b/qt_ui/models.py index 7155b3e0..670c52ad 100644 --- a/qt_ui/models.py +++ b/qt_ui/models.py @@ -168,6 +168,8 @@ class PackageModel(QAbstractListModel): def set_tot(self, tot: datetime.timedelta) -> None: self.package.time_over_target = tot self.update_tot() + # For some reason this is needed to make the UI update quickly. + self.layoutChanged.emit() def set_asap(self, asap: bool) -> None: self.package.auto_asap = asap