mirror of
https://github.com/dortania/OpenCore-Legacy-Patcher.git
synced 2026-04-25 04:20:14 +10:00
GUI: Reduce CPU usage II - have smoother UX with faster refresh rate
* Set thread_sleep_interval to 0.01s for better UI responsiveness * Improve thread waiting with thread.join() where applicable (thanks to @sbytnar)
This commit is contained in:
@@ -13,7 +13,7 @@ from .detections import device_probe
|
||||
class Constants:
|
||||
def __init__(self) -> None:
|
||||
# Patcher Versioning
|
||||
self.patcher_version: str = "2.3.2" # OpenCore-Legacy-Patcher
|
||||
self.patcher_version: str = "2.4.0" # OpenCore-Legacy-Patcher
|
||||
self.patcher_support_pkg_version: str = "1.9.3" # PatcherSupportPkg
|
||||
self.copyright_date: str = "Copyright © 2020-2025 Dortania"
|
||||
self.patcher_name: str = "OpenCore Legacy Patcher"
|
||||
@@ -155,8 +155,7 @@ class Constants:
|
||||
self.unpack_thread = None # Determine if unpack thread finished (threading.Thread)
|
||||
self.update_stage: int = 0 # Determine update stage (see gui_support.py)
|
||||
self.log_filepath: Path = None # Path to log file
|
||||
self.thread_sleep_interval: float = 0.1 # Sleep interval between UI updates (seconds) - reduce refresh-rate to reduce CPU-usage
|
||||
self.thread_nap_interval: float = 0.01 # Short Sleep interval between UI updates (seconds) - for faster UI updates of the progress bar
|
||||
self.thread_sleep_interval: float = 0.01 # Sleep interval between UI updates (seconds) - balance between UI responsiveness and CPU usage
|
||||
|
||||
self.commit_info: tuple = (None, None, None) # Commit info (Branch, Commit Date, Commit URL)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user