.NET-4.5 を使用した WPF Canvas があります。
イベント (自動作成されたメソッド)MouseLeftButtonDownとを追加しましMouseDownた。を使用しMessageBoxて、ユーザーがキャンバスをクリックしたときにこれらのメソッドが呼び出されることを確認しましたが、 からマウスの位置を取得する方法が見つかりませんMouseButtonEventArgs。
イベント (および自動作成されたメソッド) を追加したときにManipulationStarted、ManipulationStartingそれらのMessageBoxes が表示されません。
private void CenterCanvas_ManipulationStarted(object sender, ManipulationStartedEventArgs e)
{
MessageBox.Show("Doesn't show up"); // never shows up
}
private void CenterCanvas_MouseDown(object sender, MouseButtonEventArgs e)
{
MessageBox.Show("Shows up"); // shows up, but can't seem to get click position
}