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
Open the ContextMenu of the "Quick search" text box
Close the window
Expected behavior
When the parent is unloaded the memory is liberated
Actual behavior
The CleanWindowDemo window is retained in memory via the ContextMenu (see screenshot below)
Setting the MahApps.TextBox.ContextMenu as x:Shared="False" fixes the issue (PR coming)
PS. It's funny how I didn't notice it the last time- but then I must have only profiled the context menu of the "seek bar" and the DropShadowEffect of the text box, but not the context menu of the text box.
Describe the bug
There is a memory leak with the default context menu (MahApps.TextBox.ContextMenu) of all text boxes (as well as the VS one).
Steps to reproduce
Expected behavior
When the parent is unloaded the memory is liberated
Actual behavior
The CleanWindowDemo window is retained in memory via the ContextMenu (see screenshot below)
Setting the MahApps.TextBox.ContextMenu as
x:Shared="False"
fixes the issue (PR coming)PS. It's funny how I didn't notice it the last time- but then I must have only profiled the context menu of the "seek bar" and the DropShadowEffect of the text box, but not the context menu of the text box.
Environment
Screenshots
The text was updated successfully, but these errors were encountered: