Interaction
is the class, Triggers
the attached property, access is always like that for attached properties, they can be set on any control. I would recommend reading the documentation.
How does is the blend interaction functionality implemented?
-
04-06-2022 - |
質問
Out of curiosity, I'd like to know how the Blend
interaction (such as in the following example) functionality works behind the hood.
- Is
Interaction
some kind of attached property? - How do you have elements of a control using a different namespace?
Does anyone know of a tutorial or something that goes through an implementation of something like this? i.e how you would do this yourself with just the barebones wpf framework and no other frameworks
<TextBox>
<i:Interaction.Triggers>
<i:EventTrigger EventName="LostFocus">
...
</i:EventTrigger>
</i:Interaction.Triggers>
</TextBox>
解決
他のヒント
1 - The System.Windows.Interactivity.Interaction
Class defines 2 attached properties:
- Triggers
- Behaviors
2 - Those are not "elements of a control", those are Attached Properties, which can be applied to any UI element regardless of the namespace.
所属していません StackOverflow