Skip show-on-click when an overlay covers the menu bar#933
Open
AlexandrosAlexiou wants to merge 1 commit into
Open
Skip show-on-click when an overlay covers the menu bar#933AlexandrosAlexiou wants to merge 1 commit into
AlexandrosAlexiou wants to merge 1 commit into
Conversation
isMouseInsideEmptyMenuBarSpace already excludes the hardware notch but not third-party overlay windows whose level is above the menu bar, causing show-on-click to toggle when the user clicks the overlay's UI. Add an isMouseInsideOverlayAboveMenuBar gate that checks the on-screen window list for any non-Ice window with a layer above the menu bar at the click point.
emindeniz99
pushed a commit
to emindeniz99/Ice
that referenced
this pull request
Apr 30, 2026
* .github/workflows/build.yml runs on every push/PR.
- swift-parse: Linux job. Installs Swift 6.0.3 and runs
`swiftc -parse -enable-bare-slash-regex` on every .swift file in
Ice / MenuBarItemService / Shared. Catches raw syntax errors
cheaply on free runners before we burn macOS minutes.
- build: matrix over macos-26 (has the macOS 26 SDK and Xcode 26)
and macos-15 (sanity check that we haven't quietly leaked a
macOS 26-only API into an unguarded code path). Both build the
Ice and MenuBarItemService schemes in Debug with code signing
fully disabled, since we don't have Jordan's team identifier on
CI runners. Logs uploaded as artifacts on every run, errors
grepped out and surfaced in the job output.
* HIDEventManager.isMouseInsideEmptyMenuBarSpace now also rejects
"an overlay whose level is above the menu bar at the cursor". This
is AlexandrosAlexiou's PR jordanbaird#933, ported to the current codebase
(the file was renamed EventManager -> HIDEventManager and the
helper namespace MouseCursor -> MouseHelpers in the macos-26
branch refactor; the WindowInfo helper for getting on-screen
windows is also named differently here). Without it,
show-on-click toggles a section when the click was meant for a
third-party HUD/notification overlay drawn above the menu bar.
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.
isMouseInsideEmptyMenuBarSpace already excludes the hardware notch, but it doesn't account for third‑party windows whose level sits above the menu bar (e.g. notch‑extension apps like boring.notch, which uses level = .mainMenu + 3). When the user clicks one of those overlays' UI elements, Ice's NSEvent global monitor fires (the click was delivered to "another app"), the overlap with the menu‑bar Y range satisfies isMouseInsideMenuBar, none of the existing exclusions match and Show on Click toggles a hidden section even though the user never clicked the menu bar.
This adds a generic gate that asks the WindowServer for windows occluding the click point above menu‑bar level (and below the cursor), excluding Ice's own windows. If one is found, the click is treated as not inside an empty menu bar space.
Repro