mirror of
https://github.com/KenanZhu/AutoLibrary.git
synced 2026-06-18 07:23:03 +08:00
refactor(config): 新增 ConfigUtils 工具类并优化配置管理逻辑
- 新增 ConfigUtils 工具类,提供配置路径获取等工具方法 - 将 ConfigManager.getValidateAutomationConfigPaths() 重构为 ConfigUtils.getAutomationConfigPaths() - 优化 MsgBase 中 LogManager 的导入方式,使用模块导入替代函数导入 - 规范化 TimerUtils.py 中 calculate_next_repeat_time() 的文档字符串格式
This commit is contained in:
@@ -24,6 +24,7 @@ import managers.config.ConfigManager as ConfigManager
|
||||
|
||||
from utils.JSONReader import JSONReader
|
||||
from utils.JSONWriter import JSONWriter
|
||||
from utils.ConfigUtils import ConfigUtils
|
||||
|
||||
from gui.resources.ui.Ui_ALConfigWidget import Ui_ALConfigWidget
|
||||
from gui.ALSeatMapSelectDialog import ALSeatMapSelectDialog
|
||||
@@ -43,7 +44,7 @@ class ALConfigWidget(QWidget, Ui_ALConfigWidget):
|
||||
|
||||
super().__init__(parent)
|
||||
self.__cfg_mgr = ConfigManager.instance()
|
||||
self.__config_paths = ConfigManager.getValidateAutomationConfigPaths()
|
||||
self.__config_paths = ConfigUtils.getAutomationConfigPaths()
|
||||
self.__config_data = {"run": {}, "user": {}}
|
||||
|
||||
self.setupUi(self)
|
||||
|
||||
Reference in New Issue
Block a user