c# - Default binding to UserControl for custom DP -


i have custom dp runs or stops animation. want default start , stop based on usercontrol visiblity (the dp of type visibility makes easier)

can in xaml, if how (in such way user can override if want)? if not how do in code?

in straight xaml i'll want this... im not sure how applies defaults / styles etc

animility="{binding relativesource={relativesource mode=findancestor, ancestortype=usercontrol}, path=visibility}" 

edit

would work when set on controls style?

<setter property="animility" value="{binding relativesource={relativesource mode=findancestor, ancestortype=usercontrol}, path=visibility}"/> 


Comments