Esempio n. 1
0
        // bottone: opzioni gestione SPOT per l'iserimento delle informazioni sugli spot
        protected void OnButton11Released(object sender, EventArgs e)
        {
            if (this.NumeroSpot == 0)
            {
                InformationWin.InsertSomeText("MAIN WINDOW: WARNING !! INSERIRE UN NUMERO DI SPOT MAGGIORE DI 0");
            }
            else
            {
                // creazione della finestra inserimento del cago
                if (this._spotFlagWindow == false)
                {
                    // creazione della finestra inserimento dati Spot
                    SpotOpt = SpotOptions.Instance(this.NumeroSpot, InformationWin); // richiama l'istanza singleton
                    this._spotFlagWindow = true;                                     // schermata segnalata aperta

                    SpotOpt.ShowWin();                                               //viene visualizzata la schermata elicotteri e nascosta la schermata principale
                }
                else
                {
                    SpotOpt.ShowWin();
                }
                if (SpotOpt.SpotM.Spotlist != null && SpotOpt.SpotM.Spotlist.Count > 0)
                {
                    SpotOpt.ShowRecord(SpotOpt._spotRec);                      // se la finestra gia' esiste mostra il record
                }
            }
        }
Esempio n. 2
0
        public static SpotOptions Instance(int TotSpot, InfoWindow winI)

        {
            // crea il costruttore se non esiste
            if (instance == null)
            {
                instance = new SpotOptions(TotSpot, winI);
            }
            return(instance);            // ritorno il costruttore
        }