public void selectColor(ref couleur couleurEquipe, GHIElectronics.NETMF.Glide.Display.Window windowA) { // Do one-time tasks here GlideTouch.Initialize(); // Load the Window XML window = GlideLoader.LoadWindow(Resources.GetString(Resources.StringResources.windowSelectColor)); // Resize any loaded Window to the LCD's size. Glide.FitToScreen = true; // Assign the Window to MainWindow; rendering it to the LCD. Glide.MainWindow = window; Tween.SlideWindow(windowA, window, Direction.Up); // Get the Buttons GHIElectronics.NETMF.Glide.UI.Button boutonRed = (GHIElectronics.NETMF.Glide.UI.Button)window.GetChildByName("boutonRed"); GHIElectronics.NETMF.Glide.UI.Button boutonBlue = (GHIElectronics.NETMF.Glide.UI.Button)window.GetChildByName("boutonBlue"); // Set up event handlers boutonRed.TapEvent += new OnTap(buttonRed_TapEvent); boutonBlue.TapEvent += new OnTap(buttonBlue_TapEvent); while (m_couleur == couleur.NONE) ; couleurEquipe = m_couleur; }
public void selectPos(ref short choix, GHIElectronics.NETMF.Glide.Display.Window windowA) { // Do one-time tasks here GlideTouch.Initialize(); // Load the Window XML window = GlideLoader.LoadWindow(Resources.GetString(Resources.StringResources.windowSelectPos)); // Resize any loaded Window to the LCD's size. Glide.FitToScreen = true; // Assign the Window to MainWindow; rendering it to the LCD. Glide.MainWindow = window; Tween.SlideWindow(windowA, window, Direction.Up); // Get the Buttons GHIElectronics.NETMF.Glide.UI.Button bouton1 = (GHIElectronics.NETMF.Glide.UI.Button)window.GetChildByName("bouton1"); GHIElectronics.NETMF.Glide.UI.Button bouton2 = (GHIElectronics.NETMF.Glide.UI.Button)window.GetChildByName("bouton2"); GHIElectronics.NETMF.Glide.UI.Button bouton3 = (GHIElectronics.NETMF.Glide.UI.Button)window.GetChildByName("bouton3"); GHIElectronics.NETMF.Glide.UI.Button bouton4 = (GHIElectronics.NETMF.Glide.UI.Button)window.GetChildByName("bouton4"); GHIElectronics.NETMF.Glide.UI.Button bouton5 = (GHIElectronics.NETMF.Glide.UI.Button)window.GetChildByName("bouton5"); // Set up event handlers bouton1.TapEvent += new OnTap(bouton1_TapEvent); bouton2.TapEvent += new OnTap(bouton2_TapEvent); bouton3.TapEvent += new OnTap(bouton3_TapEvent); bouton4.TapEvent += new OnTap(bouton4_TapEvent); bouton5.TapEvent += new OnTap(bouton5_TapEvent); //Wait while (m_boutonSelect == false) ; //init selector m_boutonSelect = false; //return choix choix = m_choix; }
/// <summary> /// Draw a rectangle /// </summary> /// <param name="x">x start position</param> /// <param name="y">y stat postion</param> /// <param name="width">Width rectangle size</param> /// <param name="height">Height rectangle size</param> /// <param name="col">Inner rectangle fill colo</param> public void FillRectangle(int x, int y, int width, int height, GHIElectronics.NETMF.FEZ.FEZ_Components.FEZTouch.Color col) { this.screen.FillRectangle(x + xOffset, y + yOffset, width, height, col); }
public ESC(GHIElectronics.NETMF.FEZ.FEZ_Pin.Digital pin) : base(pin) { this.SetPosition((byte)DriveState.Stop); }