feat(core): 优化解压和哈希验证流程

- 在解压线程中添加已解压文件路径参数,支持直接使用已解压的补丁文件,提升解压效率。
- 更新下载管理器,简化下载成功后的处理逻辑,直接进入解压阶段,去除冗余的哈希验证步骤。
- 在离线模式管理器中增强哈希验证功能,确保在解压后进行哈希校验,提升补丁文件的完整性检查。
- 增强日志记录,确保在关键操作中提供详细的调试信息,便于后续排查和用户反馈。
This commit is contained in:
hyb-oyqq
2025-08-08 11:27:11 +08:00
parent ee72f76952
commit 09d6883432
6 changed files with 657 additions and 249 deletions

View File

@@ -367,7 +367,7 @@ class MainWindow(QMainWindow):
return progress_window
def create_extraction_thread(self, _7z_path, game_folder, plugin_path, game_version):
def create_extraction_thread(self, _7z_path, game_folder, plugin_path, game_version, extracted_path=None):
"""创建解压线程
Args:
@@ -375,11 +375,12 @@ class MainWindow(QMainWindow):
game_folder: 游戏文件夹路径
plugin_path: 插件路径
game_version: 游戏版本
extracted_path: 已解压的补丁文件路径,如果提供则直接使用它而不进行解压
Returns:
ExtractionThread: 解压线程实例
"""
return ExtractionThread(_7z_path, game_folder, plugin_path, game_version, self)
return ExtractionThread(_7z_path, game_folder, plugin_path, game_version, self, extracted_path)
def show_result(self):
"""显示安装结果调用patch_manager的show_result方法"""