Skip to content

Fix Calendar mouse capture preventing dialog close on first click - #4117

Merged
Keboo merged 2 commits into
MaterialDesignInXAML:masterfrom
MORTEM3845:fix/calendar-dialog-mouse-capture
Nov 20, 2026
Merged

Keboo merged 2 commits into
MaterialDesignInXAML:masterfrom
MORTEM3845:fix/calendar-dialog-mouse-capture

Conversation

@MORTEM3845

@MORTEM3845 MORTEM3845 commented Oct 25, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #3971.

Release CalendarItem's own mouse capture after left mouse-up, including handled events, so the first click on OK closes the dialog. Selection finishes before capture is released, preserving range dragging.

Validation: builds for net462, net8.0-windows and net10.0-windows. Local XamlTest checks passed on .NET 10 with MD2/MD3: both DialogHost styles, SingleRange/MultipleRange dragging, keyboard and month navigation, and standalone Calendar clicks. Disabling the fix reproduced the lost first click. The main UI test project could not build locally due to TUnit compilation errors.

@Keboo Keboo self-assigned this Oct 26, 2026
@MORTEM3845 MORTEM3845 closed this Oct 27, 2026
@MORTEM3845 MORTEM3845 reopened this Oct 27, 2026
@Keboo Keboo added this to the 5.5.0 milestone Nov 20, 2026
@Keboo
Keboo enabled auto-merge (squash) November 20, 2026 07:10
@Keboo
Keboo merged commit ebd1fcf into MaterialDesignInXAML:master Nov 20, 2026
2 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.

Focus issue with Calendar in Dialog

2 participants