private async void Button_Click(object sender, RoutedEventArgs e)
        {
            string MatchId = (string)(((Button)sender).CommandParameter);

            if (MatchId != null)
            {
                await WeBallAPI.getMatch(MatchId, 1);
                System.Diagnostics.Debug.WriteLine("aaa");
                if (WeBallAPI.Success == false)
                    return;
                Match currentMatch = WeBallAPI.FiveList[WeBallAPI.returnedIndex].matchs.FirstOrDefault(s => s._id == MatchId);
                (Application.Current.RootVisual as PhoneApplicationFrame).Navigate(new Uri("/ProfileMatchPage.xaml?match=" + JsonConvert.SerializeObject(currentMatch) + "&five=" + WeBallAPI.FiveList[WeBallAPI.returnedIndex]._id, UriKind.Relative));
            }
        }
Ejemplo n.º 2
0
        private async void ListMatchs_DoubleTap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            Match   match;
            creator creator;

            match = (Match)(((ListBox)sender).SelectedItem);
            if (match != null)
            {
//                creator = match.createdBy;
                await WeBallAPI.getMatch(match._id);

                if (WeBallAPI.Success == false)
                {
                    return;
                }
                var five = WeBallAPI.FiveList.FirstOrDefault(s => s._id == fiveId);

                NavigationService.Navigate(new Uri("/ProfileMatchPage.xaml?match=" + JsonConvert.SerializeObject(five.matchs.FirstOrDefault(s => s._id == match._id)) + "&five=" + fiveId, UriKind.Relative));
            }
        }