feat: update history on connect

This commit is contained in:
aclist committed 2026-05-11 21:56:21 +09:00
1 parent cdcd38c326
commit f7fe62e661
5 files changed
+47 -21

No files matched your search

+7 -3
View File
@@ -114,6 +114,7 @@ class ConnectionManager:
self.thread_man.set_cleanup_func(failure_func, destroy_first=True)
return
self.history = res.as_row()
record = res.get_record()
# NOTE: store metadata for later connection
@@ -263,11 +264,14 @@ class ConnectionManager:
if is_dayz_running():
break
time.sleep(1)
# TODO: add self.record to history file and list store
# proxy_model.append_to_history()
func = StoredFunc(self.controller.open_page, NotebookPage.SERVERS)
func = StoredFunc(self._add_to_history_and_return)
self.thread_man.set_cleanup_func(func)
def _add_to_history_and_return(self) -> None:
self.controller.add_to_history(self.history)
self.controller.open_page(NotebookPage.SERVERS)
def _update_mods(self, raise_window: bool) -> None:
# NOTE: fast enqueue all mods in auto mode
prefs = self.controller.get_prefs()