Skip to content

fix: 关闭 “启用鼠标点击特效” 时无法显示常驻拖尾#122

Merged
DoomVoss merged 2 commits into
DoomVoss:mainfrom
ABA2396:fix/trail-effect-independent
Jun 30, 2026
Merged

fix: 关闭 “启用鼠标点击特效” 时无法显示常驻拖尾#122
DoomVoss merged 2 commits into
DoomVoss:mainfrom
ABA2396:fix/trail-effect-independent

Conversation

@ABA2396

@ABA2396 ABA2396 commented Jun 27, 2026

Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI review requested due to automatic review settings June 27, 2026 10:47

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

该 PR 旨在修复“关闭「启用鼠标点击特效」后,仍应能显示「常驻拖尾」但实际无法显示”的问题,并同步优化控制面板在关闭点击特效开关时的选项显示逻辑,使点击特效与拖尾效果的开关语义更清晰。

Changes:

  • 将点击特效与拖尾渲染的开关判断拆分:点击仅受点击特效开关影响,拖尾受“点击特效或常驻拖尾”任一开关影响。
  • 调整 CanRenderEffects():仅保留渲染环境条件检查,将业务开关判断下放到调用点。
  • 控制面板在主开关关闭时隐藏点击特效相关选项面板,并在加载设置时同步刷新可见性。

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
src/OverlayManager.cs 拆分点击/拖尾的开关判断,并调整渲染前置条件检查逻辑以支持常驻拖尾独立生效。
src/ConfigManager.cs 新增语义化的派生开关属性,区分点击特效激活与拖尾激活状态。
src/ControlPanelWindow.xaml.cs 加载设置时及主开关切换时,动态更新点击特效选项面板可见性。
src/ControlPanelWindow.xaml 为主开关添加 Checked/Unchecked 事件,并为点击特效选项面板命名以便代码控制可见性。
Comments suppressed due to low confidence (1)

src/OverlayManager.cs:537

  • OnMouseMoveExt still blocks rendering when the cursor is hidden and _isPrimaryPointerDown is false. With the new IsTrailEffectActive gate, this means “常驻拖尾” can still fail to render in cursor-hidden environments (e.g., touchscreen mode / apps that hide the cursor), because _isPrimaryPointerDown may never become true when click effects are disabled. Consider allowing move rendering when the always-trail switch is enabled, regardless of _isPrimaryPointerDown.
            if (!ConfigManager.IsTrailEffectActive) return;
            if (!CanRenderEffects()) return;

            bool cursorVisible = CursorIsVisible();
            if (!cursorVisible && !_isPrimaryPointerDown) return;

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@DoomVoss DoomVoss requested a review from Akiha-Official June 30, 2026 06:46
@Akiha-Official Akiha-Official requested a review from DoomVoss June 30, 2026 07:51
@DoomVoss DoomVoss merged commit 473eba2 into DoomVoss:main Jun 30, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants