Repository navigation
fix(native): open Notification Center from the clock while a notification shows - #537
Merged
Merged
Conversation
…tion shows On macOS 27 a notification left on screen across a collapse keeps up the same Notification Center window the panel uses (same owner, layer and screen-tall bounds). The window-list check took it for an open panel, so a click on the clock was never replayed and the replay reported the panel shown without pressing. Reproduced on 27.0.1 with 1.13.0 and the login "App Background Activity" notification. The panel check now also asks Accessibility for the panel's Edit Widgets control (widget-editor-button) while a window is up, and falls back to the window alone when Accessibility cannot be read.
tieubao
force-pushed
the
fix/notification-center
branch
from
November 17, 2026 14:30
ed7b22d to
2cfd2ea
Compare
tieubao
marked this pull request as ready for review
November 17, 2026 14:30
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
On macOS 27 (direct build), clicking the clock while the bar is collapsed did nothing when a notification was still on screen. Report (email, Nov 5): "Hidden Bar prevents the macOS notification center from displaying when icons are hidden."
Cause
A notification that stays up across a collapse (reproduced with macOS's "App Background Activity" notification at login) keeps up the same Notification Center window the panel uses: same owner, layer 21, screen-tall bounds, same window number.
SystemMenuBarClockdecided "panel open" from the window list alone, so:.panelShownwithout pressing.MenuBarAgent ignores the clock under the restriction (assessment mode), so nothing opened.
Fix
NotificationCenterPanel.isOpenkeeps the window-list read and, only while a window is up, reads Notification Center's AXIdentifiers: the panel haswidget-editor-button(Edit Widgets), a notification alone never does (trees measured on 27.0.1). If Accessibility cannot be read, the window alone decides, as before.Evidence (hb-macos2701, macOS 27.0.1)
Closing the panel collapses the bar again:
Open and close were repeated twice on the fixed build; the AX tree showed the panel controls after each open and none after each close.
Tests
NotificationCenterPanelTests(5 cases). Red before the fix:testANotificationOnScreenIsNotThePanelfailed.scripts/test.shin the mac-ui VM: direct 693 passed, App Store 459 passed, 0 failed.testANotificationOnScreenIsNotThePanelfails, restore green. Verdict: PASS.Not covered