private void Team_Tap(object sender, System.Windows.Input.GestureEventArgs e)
        {
            Ellipse el = new Ellipse();
            string teamtype = "";
            Image i = new Image();

            if (sender.GetType() == el.GetType())
            {
                el = sender as Ellipse;
                teamtype = el.Name;
            }
            else if (sender.GetType() == i.GetType())
            {
                i = sender as Image;
                teamtype = i.Name;
            }

            NavigationService.Navigate(new Uri("/SelectTeam.xaml?action=" + teamtype + "&league=" + CurrentLeague, UriKind.Relative));
        }
Exemple #2
0
 /// <summary>
 /// Resetear las bolas segun configuracion
 /// </summary>
 /// <param name="can"></param>
 private void resetBall(Canvas can)
 {
     Ellipse eli = new Ellipse();
     foreach (Object c in can.Children)
     {
         if (Object.ReferenceEquals(c.GetType(), eli.GetType()))
         {
             //Console.WriteLine("oh yeah!!");
             ((Ellipse)c).Fill = new SolidColorBrush(this.colorBall);
             if (this.ballVisivility)
             {
                 ((Ellipse)c).Visibility = Visibility.Visible;
             }
             else
             {
                 ((Ellipse)c).Visibility = Visibility.Hidden;
             }
         }
     }
 }