You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
I want to provide custom controls with buttons that close a window. However, this is code outside of Avalonia, so the window closing event will have IsProgrammatic == true. Any logic relying on this flag will then be wrong.
Describe the solution you'd like
Add parameter to Window.Close method to specify IsProgrammatic value (default true?).
Describe alternatives you've considered
As a workaround I wrapped the Window.Close in extension methods and called those instead, wherever needed.
Additional context
Original feature request for IsProgrammatic: #9524
The text was updated successfully, but these errors were encountered:
Measurity
changed the title
Add parameter to Window.Close which sets IsProgrammatic to false, simulating a close by user
Support simulating a Window close by user, which sets IsProgrammatic to false
Dec 30, 2024
Is your feature request related to a problem? Please describe.
I want to provide custom controls with buttons that close a window. However, this is code outside of Avalonia, so the window closing event will have
IsProgrammatic == true
. Any logic relying on this flag will then be wrong.Describe the solution you'd like
Add parameter to
Window.Close
method to specifyIsProgrammatic
value (default true?).Describe alternatives you've considered
As a workaround I wrapped the
Window.Close
in extension methods and called those instead, wherever needed.Additional context
Original feature request for
IsProgrammatic
: #9524The text was updated successfully, but these errors were encountered: