mirror of
https://github.com/KenanZhu/AutoLibrary.git
synced 2026-06-18 07:23:03 +08:00
refactor(modules): 将 AutoScriptEngine 移至 dsl/,ConfigUtils 移至 managers/config/,修复单一职责和依赖倒置问题
This commit is contained in:
@@ -0,0 +1,9 @@
|
||||
"""
|
||||
DSL module for the AutoLibrary project.
|
||||
|
||||
Contains the AutoScript DSL engine and related components
|
||||
for preprocessing user reservation data in timer tasks.
|
||||
|
||||
Classes:
|
||||
- AutoScriptEngine: AutoScript script engine class.
|
||||
"""
|
||||
@@ -17,7 +17,7 @@ from PySide6.QtWidgets import (
|
||||
QGroupBox, QSizePolicy
|
||||
)
|
||||
|
||||
from utils.AutoScriptEngine import AutoScriptEngine
|
||||
from dsl.AutoScriptEngine import AutoScriptEngine
|
||||
|
||||
|
||||
VARIABLE_META = AutoScriptEngine.VARIABLE_META
|
||||
|
||||
@@ -24,7 +24,7 @@ import managers.config.ConfigManager as ConfigManager
|
||||
|
||||
from utils.JSONReader import JSONReader
|
||||
from utils.JSONWriter import JSONWriter
|
||||
from utils.ConfigUtils import ConfigUtils
|
||||
from managers.config.ConfigUtils import ConfigUtils
|
||||
|
||||
from gui.resources.ui.Ui_ALConfigWidget import Ui_ALConfigWidget
|
||||
from gui.ALSeatMapSelectDialog import ALSeatMapSelectDialog
|
||||
|
||||
@@ -20,7 +20,7 @@ from PySide6.QtGui import (
|
||||
)
|
||||
|
||||
from base.MsgBase import MsgBase
|
||||
from utils.ConfigUtils import ConfigUtils
|
||||
from managers.config.ConfigUtils import ConfigUtils
|
||||
|
||||
from gui.resources.ui.Ui_ALMainWindow import Ui_ALMainWindow
|
||||
from gui.resources import ALResource
|
||||
|
||||
@@ -18,7 +18,7 @@ from PySide6.QtCore import (
|
||||
from base.MsgBase import MsgBase
|
||||
from operators.AutoLib import AutoLib
|
||||
from utils.JSONReader import JSONReader
|
||||
from utils.AutoScriptEngine import AutoScriptEngine
|
||||
from dsl.AutoScriptEngine import AutoScriptEngine
|
||||
|
||||
|
||||
class AutoLibWorker(MsgBase, QThread):
|
||||
|
||||
@@ -43,4 +43,4 @@ class ConfigUtils:
|
||||
data = {"current": index, "paths": paths}
|
||||
auto_config[f"{cfg_type}_path"] = data
|
||||
cfg_mgr.set(ConfigManager.ConfigType.GLOBAL, "automation", auto_config)
|
||||
return config_paths
|
||||
return config_paths
|
||||
@@ -5,6 +5,4 @@
|
||||
- TimerUtils: Timer utils class for the AutoLibrary project.
|
||||
- JSONReader: JSON reader class for the AutoLibrary project.
|
||||
- JSONWriter: JSON writer class for the AutoLibrary project.
|
||||
- ConfigUtils: Config utils class for the AutoLibrary project.
|
||||
- AutoScriptEngine: AutoScript script engine class for the AutoLibrary project.
|
||||
"""
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user