如何防止windows phone 7在用户滚动时将MouseLeftButtonUp事件发送到我的网格(我将其用作Button)?
此问题有时会导致在用户滚动时导航到另一个页面。
或者我应该使用一个Button-Template来做这个?
示例代码:
<ScrollViewer>
<StackPanel>
<Grid x:Name="Button1" MouseLeftButtonUp="Button1_LeftMouseButtonUp">
<TextBlock Margin="12 15" />
</Grid>
</StackPanel>
</ScrollViewer>发布于 2011-05-17 12:40:14
而不是LeftMouseButtonUp事件,尝试如下所示
private void Button1_ManipulationCompleted(object sender, ManipulationCompletedEventArgs e)
{
if (!e.IsInertial)
{
//Button Click Code
}
}https://stackoverflow.com/questions/5676385
复制相似问题