using System;
using System.IO;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Navigation;

namespace FingersDance.Control.Pivot
{
	public partial class UserControlPivot
	{
        //Events pour chaque Boutton du Pivot
        public event EventHandler EH_SurfaceButtonPlayer_ContactDown;

		public UserControlPivot()
		{
			this.InitializeComponent();
            
			// Insert code required on object creation below this point.
		}

        private void SurfaceButtonPlayer1_ContactDown(object sender, Microsoft.Surface.Presentation.ContactEventArgs e)
        {
            if(EH_SurfaceButtonPlayer_ContactDown!=null)
                EH_SurfaceButtonPlayer_ContactDown(1, new EventArgs());
        }

        private void SurfaceButtonPlayer2_ContactDown(object sender, Microsoft.Surface.Presentation.ContactEventArgs e)
        {
            if (EH_SurfaceButtonPlayer_ContactDown != null)
                EH_SurfaceButtonPlayer_ContactDown(2, new EventArgs());
        }

        private void SurfaceButtonPlayer3_ContactDown(object sender, Microsoft.Surface.Presentation.ContactEventArgs e)
        {
            if (EH_SurfaceButtonPlayer_ContactDown != null)
                EH_SurfaceButtonPlayer_ContactDown(3, new EventArgs());
        }

        private void SurfaceButtonPlayer4_ContactDown(object sender, Microsoft.Surface.Presentation.ContactEventArgs e)
        {
            if (EH_SurfaceButtonPlayer_ContactDown != null)
                EH_SurfaceButtonPlayer_ContactDown(4, new EventArgs());
        }

        private void SurfaceButtonPlayer1_Click(object sender, RoutedEventArgs e)
        {
            SurfaceButtonPlayer1_ContactDown(this,null);
        }

        private void SurfaceButtonPlayer2_Click(object sender, RoutedEventArgs e)
        {
            SurfaceButtonPlayer2_ContactDown(this, null);
        }

        private void SurfaceButtonPlayer3_Click(object sender, RoutedEventArgs e)
        {
            SurfaceButtonPlayer3_ContactDown(this, null);
        }

        private void SurfaceButtonPlayer4_Click(object sender, RoutedEventArgs e)
        {
            SurfaceButtonPlayer4_ContactDown(this, null);
        }
	}
}