0
我有一个数据模板内的图像,我想调用一个方法时,它获得焦点,但gotfocus事件不会触发。下面是代码:GotFocus事件没有触发
<DataTemplate>
<Canvas x:Name="cv">
<Image x:Name="img1" Source = "{Binding ModelImage}" Stretch="Fill" Width="432" Height="357" MaxWidth="432" MaxHeight="357"/>
<Image Source = "{Binding HairStyleImage}" Stretch="Fill" ManipulationMode="All" ManipulationDelta="ResourceImage_ManipulationDelta" GotFocus="focussed" LostFocus="lostFocus">
<Image.RenderTransform>
<CompositeTransform />
</Image.RenderTransform>
</Image>
</Canvas>
</DataTemplate>