feat(core): 更新配置管理和文件忽略规则

- 修改.gitignore文件,添加对Python缓存文件、虚拟环境和系统文件的忽略规则,提升项目整洁性。
- 更新主窗口和相关模块的导入路径,确保从新的配置模块中正确导入配置项,增强代码结构的清晰度。
- 删除不再使用的图片和模块,优化项目资源,减少冗余文件,提升维护效率。
This commit is contained in:
hyb-oyqq
2025-08-11 16:13:58 +08:00
parent 6a4c6ca1f1
commit 4d847f58d0
65 changed files with 50 additions and 8164 deletions

View File

@@ -8,7 +8,7 @@ from PySide6 import QtWidgets, QtCore
from PySide6.QtCore import QTimer
from PySide6.QtWidgets import QMessageBox
from data.config import PLUGIN, PLUGIN_HASH, GAME_INFO
from config.config import PLUGIN, PLUGIN_HASH, GAME_INFO
from utils import msgbox_frame
from utils.logger import setup_logger
@@ -140,7 +140,7 @@ class OfflineModeManager:
# 更新窗口标题
if hasattr(self.main_window, 'setWindowTitle'):
from data.config import APP_NAME, APP_VERSION
from config.config import APP_NAME, APP_VERSION
mode_indicator = "[离线模式]" if enabled else "[在线模式]"
self.main_window.setWindowTitle(f"{APP_NAME} v{APP_VERSION} {mode_indicator}")
@@ -245,7 +245,7 @@ class OfflineModeManager:
# 创建进度对话框
from utils.helpers import ProgressHashVerifyDialog
from data.config import PLUGIN_HASH
from config.config import PLUGIN_HASH
from workers.hash_thread import OfflineHashVerifyThread
# 创建并显示进度对话框
@@ -327,7 +327,7 @@ class OfflineModeManager:
debug_mode = self._is_debug_mode()
# 导入所需模块
from data.config import GAME_INFO, PLUGIN
from config.config import GAME_INFO, PLUGIN
# 存储结果到对话框以便在exec()返回后获取
dialog.hash_result = result
@@ -476,7 +476,7 @@ class OfflineModeManager:
debug_mode = self._is_debug_mode()
# 导入所需模块
from data.config import GAME_INFO, PLUGIN_HASH
from config.config import GAME_INFO, PLUGIN_HASH
from workers.hash_thread import HashThread
# 获取安装路径
@@ -557,7 +557,7 @@ class OfflineModeManager:
self.main_window.download_manager.selected_folder
)
from data.config import GAME_INFO
from config.config import GAME_INFO
if game_version in game_dirs and game_version in GAME_INFO:
game_dir = game_dirs[game_version]
install_path = os.path.join(game_dir, os.path.basename(GAME_INFO[game_version]["install_path"]))