feat: Implement 30-minute timeout protection and unify path configurations
- Introduced a 30-minute timeout mechanism to prevent the script from getting stuck in invalid states, with configurable timeout settings. - Unified path configurations across the project to enhance maintainability and avoid hardcoded paths. - Updated documentation and flowcharts to reflect the new timeout feature and improved path management. - Fixed issues with template and screenshot path configurations to ensure consistency across the project.
This commit is contained in:
1 parent
686dde5cc0
commit
26df350755
64 files changed
+7568
-414
No files matched your search
@@ -0,0 +1,48 @@
|
||||
"""配置管理组件
|
||||
|
||||
包含配置加载、保存等功能的GUI组件。
|
||||
"""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
from typing import Any, Callable
|
||||
import tkinter as tk
|
||||
from tkinter import ttk
|
||||
|
||||
from gui.gui_core import read_config, write_config
|
||||
|
||||
|
||||
def load_config_to_ui(
|
||||
cfg: dict[str, Any],
|
||||
vars_dict: dict[str, Any],
|
||||
on_line: Callable[[str], None],
|
||||
) -> None:
|
||||
"""从配置文件加载到UI变量。
|
||||
|
||||
参数:
|
||||
cfg: 配置字典
|
||||
vars_dict: UI变量字典
|
||||
on_line: 日志输出回调
|
||||
"""
|
||||
# TODO: 实现配置加载逻辑
|
||||
# 临时从原文件导入
|
||||
pass
|
||||
|
||||
|
||||
def save_ui_to_config(
|
||||
vars_dict: dict[str, Any],
|
||||
on_line: Callable[[str], None],
|
||||
) -> None:
|
||||
"""将UI变量保存到配置文件。
|
||||
|
||||
参数:
|
||||
vars_dict: UI变量字典
|
||||
on_line: 日志输出回调
|
||||
"""
|
||||
# TODO: 实现配置保存逻辑
|
||||
# 临时从原文件导入
|
||||
pass
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user