From 4ddaa0603d06691e1bf3e8f9342c95379abdccbb Mon Sep 17 00:00:00 2001 From: tian <11429339@qq.com> Date: Tue, 30 Sep 2025 22:21:41 +0800 Subject: [PATCH] =?UTF-8?q?=E9=98=B6=E6=AE=B5=E5=9B=9B=EF=BC=9A=E5=88=A0?= =?UTF-8?q?=E9=99=A4=E6=89=80=E6=9C=89=E5=90=91=E5=90=8E=E5=85=BC=E5=AE=B9?= =?UTF-8?q?=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 删除的旧版兼容代码: 1. PathAnimationManager.cs - AnimationCompleted事件声明 (line 143-144) - AnimationCompleted事件触发 (line 901-902) 2. ModelSplitterManager.cs - GenerateFileName旧版重载方法 (line 1583-1593) 3. LayerManagementViewModel.cs - GenerateFileName旧版重载方法 (line 1711-1721) 遵循"明确拒绝向后兼容性"原则,统一使用新版本API 编译验证通过 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude --- src/Core/Animation/PathAnimationManager.cs | 6 ------ src/Core/ModelSplitterManager.cs | 12 ------------ src/UI/WPF/ViewModels/LayerManagementViewModel.cs | 12 ------------ 3 files changed, 30 deletions(-) diff --git a/src/Core/Animation/PathAnimationManager.cs b/src/Core/Animation/PathAnimationManager.cs index e90161a..cedeb53 100644 --- a/src/Core/Animation/PathAnimationManager.cs +++ b/src/Core/Animation/PathAnimationManager.cs @@ -139,9 +139,6 @@ namespace NavisworksTransport.Core.Animation /// 当动画进度更新时触发 (0.0-100.0) /// public event EventHandler ProgressChanged; - - // 动画完成事件 (旧版,保留兼容性) - public event EventHandler AnimationCompleted; /// /// 当检测到碰撞时触发 @@ -901,9 +898,6 @@ namespace NavisworksTransport.Core.Animation var actualTotalFrames = _animationFrames?.Count ?? 0; LogManager.Info($"动画播放完成,总帧数: {actualTotalFrames}, 平均FPS: {_actualFPS:F1}"); - // 触发旧版完成事件(保持兼容性) - AnimationCompleted?.Invoke(this, EventArgs.Empty); - // 更新 TimeLiner 任务状态 if (_timeLinerManager != null && !string.IsNullOrEmpty(_currentTaskId)) { diff --git a/src/Core/ModelSplitterManager.cs b/src/Core/ModelSplitterManager.cs index 4d17d0e..d56cbc3 100644 --- a/src/Core/ModelSplitterManager.cs +++ b/src/Core/ModelSplitterManager.cs @@ -1580,18 +1580,6 @@ namespace NavisworksTransport } } - /// - /// 生成文件名(旧版本兼容性方法) - /// - /// 分层名称 - /// 配置信息 - /// 文件名(不包括路径) - private string GenerateFileName(string layerName, SplitConfiguration config) - { - // 使用默认策略调用新版本方法 - return GenerateFileName(layerName, config.Strategy, config); - } - /// /// 获取根节点名称 - 新的智能文件名格式使用 /// 逻辑:文档文件名 → 第一个模型根项DisplayName → "NavisworksModel" diff --git a/src/UI/WPF/ViewModels/LayerManagementViewModel.cs b/src/UI/WPF/ViewModels/LayerManagementViewModel.cs index e5c4a3a..ee83926 100644 --- a/src/UI/WPF/ViewModels/LayerManagementViewModel.cs +++ b/src/UI/WPF/ViewModels/LayerManagementViewModel.cs @@ -1708,18 +1708,6 @@ namespace NavisworksTransport.UI.WPF.ViewModels } } - /// - /// 生成文件名(旧版本兼容性方法) - /// - /// 分层名称 - /// 配置信息 - /// 文件名(不包括路径) - private string GenerateFileName(string layerName, ModelSplitterManager.SplitConfiguration config) - { - // 使用默认策略调用新版本方法 - return GenerateFileName(layerName, config.Strategy, config); - } - /// /// 导出分层到NWD文件 ///