-
Notifications
You must be signed in to change notification settings - Fork 140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
FluidMoveBehavior memory leak #38
Comments
Per our issue requirements. A sample must be provided in order for the Behaviors team to evaluate the issue. Please submit an app that can reproduce the issue, and it will be reopened. |
Actually, I found one here: https://github.com/microsoft/XamlBehaviorsWpf/tree/master/samples/XAMLBehaviorsSample |
This is absolutely a memory leak! There is some code that uses a timer to remove objects from the static dictionary to help limit the number of objects in the TagDictionary when the layout updates. I'm worried about that static TagDictionary. I didn't write this behavior, and I am unaware of it's usage when dealing with many FluidMoveBehaviors. I was first thinking that we could clear the TagDictionary on Detaching or Unloading, but that might impact other FluidMoveBehavior instances in other areas of the app. @DVaughan @branh do you have any knowledge with this behavior? |
How about using WeakReferences instead of the UI Elements. |
Might a Would be the simplest change: |
@tibel , I like your approach. You should put in a pull request. |
I can create a pull request if the change is accepted as-is (no tests)? |
Hey @tibel was there a specific reason you closed your PR? Did you determine that your approach does not solve the problem? |
I've moved on as I haven't done WPF development in the last few years. |
As described in https://social.msdn.microsoft.com/Forums/lync/en-US/f14d1486-24ba-447b-9712-e16f5457a08b/fluidmovebehavior-memory-leak-bug there is a memory leak with the static
TagDictionary
.I write this as a reminder/question, as I think this issue is still existing in the current code base.
The text was updated successfully, but these errors were encountered: