Skip to content

Fix input handling and map popup light-dismiss - #39

Merged
emosaru merged 1 commit into
avaloniafrom
claude/hungry-jones
Apr 13, 2026
Merged

Fix input handling and map popup light-dismiss#39
emosaru merged 1 commit into
avaloniafrom
claude/hungry-jones

Conversation

@emosaru

@emosaru emosaru commented Apr 13, 2026

Copy link
Copy Markdown
Contributor

Summary

  • MaskInput: TrackableItemControl now uses standard Image (rectangular hit test) by default, only switching to InputMaskingImage (per-pixel alpha hit test) when MaskInput is true
  • IgnoreUserInput: Enforced at three levels — IsHitTestVisible binding on the outer Grid, CanExecute checks on both left/right click commands, and an early guard in Grid_PointerReleased
  • Map popup light-dismiss: Location details popup now closes on clicks anywhere in the window (not just within the map control) using a tunneling PointerPressed handler on the top-level window, fixing the issue where clicking items outside the map wouldn't dismiss the popup

Test plan

  • Load a pack with MaskInput items — verify per-pixel alpha hit testing works only on those items
  • Verify items with IgnoreUserInput=true cannot be clicked (left or right)
  • Open a map location popup, then click on a tracker item — popup should close
  • Open a map location popup, click on another map location — popup should switch to new location
  • Double-click a map location — should still pin correctly
  • Rapid pack switching — no crashes or stale handlers

🤖 Generated with Claude Code

…t, and popup light-dismiss

TrackableItemControl now uses a standard Image (rectangular hit test) by default
and only uses InputMaskingImage (per-pixel alpha) when MaskInput is true.
IgnoreUserInput is enforced via IsHitTestVisible binding, CanExecute checks,
and an early guard in Grid_PointerReleased.

LocationMapControl popup dismiss now uses a tunneling PointerPressed handler on
the top-level window so clicks on controls outside the map (e.g. tracker items)
properly close the location details popup.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@emosaru
emosaru requested a review from a team April 13, 2026 08:01
@emosaru
emosaru merged commit 097832f into avalonia Apr 13, 2026
3 checks 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.

1 participant