Skip to content

Make window close independent from back-blocked UI state#2131

Open
chenx-dust wants to merge 1 commit into
chen08209:mainfrom
chenx-dust:fix-back-block
Open

Make window close independent from back-blocked UI state#2131
chenx-dust wants to merge 1 commit into
chen08209:mainfrom
chenx-dust:fix-back-block

Conversation

@chenx-dust

Copy link
Copy Markdown

问题

连接/请求页面进入筛选搜索时会设置 backBlock = true,原来的 handleBackOrExit() 内部会读取这个状态并直接返回。桌面窗口关闭、标题栏关闭按钮、Ctrl+W 也都走 handleBackOrExit(),所以搜索态下窗口关闭被误拦截,表现为窗口无法关闭。

修复

backBlock 判断从 SystemAction.handleBackOrExit() 移到普通系统返回入口 HomeBackScopeContainer。这样:

  • 手机/系统返回仍会先让 CommonPopScope 处理搜索/编辑状态,必要时由 backBlock 阻止继续最小化/退出。
  • 桌面窗口关闭、标题栏关闭、Ctrl+W 直接执行应用级关闭策略,不再被搜索/编辑态拦住。
  • handleBackOrExit() 职责更清晰,只负责根据 minimizeOnExit 决定隐藏到后台/托盘或真正退出。

EyKettle added a commit to EyKettle/FlClash that referenced this pull request Jun 29, 2026
Cherry-pick 8 selected PRs fixing critical bugs and security issues:

  chen08209#2136  fix: new rule overwrites existing rule with duplicate id -1
  chen08209#2131  fix: window close blocked by back-blocked UI state
  chen08209#2103  fix: propagate UID from getConnectionOwnerUid through JNI
  chen08209#1996  fix: Android :remote process SIGABRT on VPN start
  chen08209#2018  fix: unsafe malloc() dereference in jni_helper.cpp
  chen08209#1938  fix: Zip Slip path traversal in backup restore
  chen08209#2132  fix: Android QR scanning difficulty

Additionally:
- Custom _fixRules patch for subscription rules missing TARGET field
  (upstream chen08209#2028 original approach, redesigned for minimal diff)
- Switch submodule URLs from SSH to HTTPS for CI compatibility
EyKettle added a commit to EyKettle/FlClash that referenced this pull request Jun 30, 2026
Cherry-pick 8 selected PRs fixing critical bugs and security issues:

  chen08209#2136  fix: new rule overwrites existing rule with duplicate id -1
  chen08209#2131  fix: window close blocked by back-blocked UI state
  chen08209#2103  fix: propagate UID from getConnectionOwnerUid through JNI
  chen08209#1996  fix: Android :remote process SIGABRT on VPN start
  chen08209#2018  fix: unsafe malloc() dereference in jni_helper.cpp
  chen08209#1938  fix: Zip Slip path traversal in backup restore
  chen08209#2132  fix: Android QR scanning difficulty

Additionally:
- Custom _fixRules patch for subscription rules missing TARGET field
  (upstream chen08209#2028 original approach, redesigned for minimal diff)
- Switch submodule URLs from SSH to HTTPS for CI compatibility
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.

1 participant