I am scratching my head to understand the dependency property.
The queries I do have is as following;
As Depenedency property is declared as static, static means class level property, only single instance would be created and all object would be sharing the same object.
I have a user control and I have added dependency property IsHighlighted to that user control. this dependency property is bind to some view model property and I have registered a callback for dependency property value changes. So, as soon as somebody changes the view model property, dependency properties callback would be invoked and it would start an animation if value is true as it a boolean value.
Now, I have created 5 objects view and when i set the viewmodel property for object1 to true, then animation runs for the last node object5 not for object1. view model's property is non static.
I am confused dependency property would be created for each object or it would be single for all the object.
In case it is single for all the objects, then what would be way to track the changes in the user control property on which I need to run the simulation because for normal CLR property in user control no change handler would be called.
Summary: Dependency properties are created at class level or object level. if it is created at class level as it is declared as static, then what is the way to create a property that is at object level( non-static) but it would not be having any value change callback for normal CLR propety. So How to do that.