Browse Source

increase sleep duration to 0.016 (see #2482)

Falko Schindler 1 năm trước cách đây
mục cha
commit
d4c22cdfd0
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      nicegui/native/native_mode.py

+ 1 - 1
nicegui/native/native_mode.py

@@ -87,7 +87,7 @@ def _start_window_method_executor(window: webview.Window,
                     else:
                         log.error(f'window.{method_name} is not callable')
             except queue.Empty:
-                time.sleep(0.01)
+                time.sleep(0.016)  # NOTE: avoid issue https://github.com/zauberzeug/nicegui/issues/2482 on Windows
             except Exception:
                 log.exception(f'error in window.{method_name}')