I'm having trouble in developing my windows phone app. It's a game and I'm using XNA.
Here one of the Navigation Page:
The problem is that in the top left the "back" button is at the same place on the page before this one. So when I tap the back button, it doesn't lead me to the previous page but to the first one. (sometimes if I click fast enought it leads me to the previous one). As it works sometimes, I think the error doesn't come from my code. I think as the back_button is at the same place on both pages, it update too fast and the "touch_event" stay for too long maybe. I don't know how to solve this.
There is how I catch the button click:
TouchPanelCapabilities touchCap = TouchPanel.GetCapabilities();
if (touchCap.IsConnected)
{
TouchCollection touches = TouchPanel.GetState();
if (touches.Count >= 1)
{
Vector2 PositionTouch = touches[0].Position;
return (Mouseclik((int)PositionTouch.X, (int)PositionTouch.Y));
}
}
return (Screen.ChooseLevelScreen);