diff --git a/apps/terminal/applets/chrome/ChangeLog b/apps/terminal/applets/chrome/ChangeLog index d59b31125..4144ddc2f 100644 --- a/apps/terminal/applets/chrome/ChangeLog +++ b/apps/terminal/applets/chrome/ChangeLog @@ -1,3 +1,7 @@ +# 2023-09-15 Version 0.9 +## 功能优化 + - 进度条显示最大超时 + # 2023-08-16 Version 0.8 ## 功能优化 - 修复代填失败,造成页面卡住的问题 diff --git a/apps/terminal/applets/chrome/code_dialog.py b/apps/terminal/applets/chrome/code_dialog.py index 862e80986..ed5ca05a7 100644 --- a/apps/terminal/applets/chrome/code_dialog.py +++ b/apps/terminal/applets/chrome/code_dialog.py @@ -35,15 +35,23 @@ class CodeDialog(object): class TkProgressBar(object): + # 30s + wait_max_time = 3000 * 10 + def __init__(self, wait_func=None): self._wait_func = wait_func self._done = threading.Event() self._root = None + self._wait_time = 0 def _check(self): if self._done.isSet(): self._root.destroy() return + if self._wait_time >= self.wait_max_time: + self._root.destroy() + return + self._wait_time += 100 self._root.after(100, self._check) def stop(self): diff --git a/apps/terminal/applets/chrome/manifest.yml b/apps/terminal/applets/chrome/manifest.yml index 89b35a7dc..8e648831c 100644 --- a/apps/terminal/applets/chrome/manifest.yml +++ b/apps/terminal/applets/chrome/manifest.yml @@ -1,6 +1,6 @@ name: chrome display_name: "{{ 'Chrome Browser' | trans }}" -version: 0.8 +version: 0.9 comment: "{{ 'Chrome Browser Open URL Page Address' | trans }}" author: JumpServer Team exec_type: python