Hide() public abstract method

public abstract Hide ( ) : void
return void
Example #1
0
        public void endTutorial()
        {
            // post del tour
            if (countStep == 0)
            {
                new PopupNotification("Error", "Debe agregar al menos un paso.");
            }
            else
            {
                loadingForm = new LoadingForm();
                loadingForm.Show();

                var tourController = new TourController();

                tour.user_id = Constants.user._id;
                var tourResponse = tourController.PostAsync(tour).Result;

                // post de los audios
                var allAudioResponse = true;
                for (int i = 0; i < countStep; i++)
                {
                    var nameTourWithoutSpace = tour.name.Replace(" ", "");
                    var audioName            = "/Audio" + nameTourWithoutSpace + i + ".wav";
                    var filename             = Constants.audioPath + audioName;
                    if (File.Exists(filename))
                    {
                        allAudioResponse = allAudioResponse && tourController.PostAudio(filename, tourResponse._id, tourResponse.steps[i]._id).Result;
                    }
                }

                loadingForm.Close();

                webBrowser.Refresh();

                if (tourResponse._id != null && allAudioResponse)
                {
                    new PopupNotification("Fin del tutorial", "Tutorial Terminado! Se guardaron " + countStep.ToString() + " pasos");
                }
                else
                {
                    new PopupNotification("Error", "Un error ha ocurrido tratando de conectar al servidor.");
                }

                formBar.Hide();
                stepsBar.Hide();
                tourBar.Hide();
                if (!(textPopup == null))
                {
                    textPopup.Hide();
                }

                Constants.tours = tourController.GetAllToursAsync().Result;
                asistimeAppBar.Show();
            }
        }
Example #2
0
        public void drawForm(String form)
        {
            formBar.Location = new System.Drawing.Point(asistimeAppBar.Location.X + 30, asistimeAppBar.Location.Y + asistimeAppBar.Height + 30);
            iconBar.Location = new System.Drawing.Point(asistimeAppBar.Location.X + 30, asistimeAppBar.Location.Y + asistimeAppBar.Height + 30);
            //formBar.Show();
            formBar.BringToFront();
            iconBar.BringToFront();
            asistimeAppBar.Hide();
            //stepsBar.Show();

            switch (form)
            {
            case "circulo":
                if (!(textPopup == null))
                {
                    textPopup.Hide();
                }
                iconBar.Hide();
                formBar.ShowControlsCircle();
                circle();
                break;

            case "rectangulo":
                if (!(textPopup == null))
                {
                    textPopup.Hide();
                }
                iconBar.Hide();
                formBar.ShowControlsRect();
                rectangle();
                break;

            case "div":
                if (!(textPopup == null))
                {
                    textPopup.Hide();
                }
                iconBar.Hide();
                formBar.Hide();
                div();
                break;

            case "borrador":
                if (!(textPopup == null))
                {
                    textPopup.Hide();
                }
                iconBar.Hide();
                formBar.Hide();
                erase();
                break;

            case "texto":
                iconBar.Hide();
                formBar.Hide();
                textPopup = new TextElement()
                {
                    Parent = this
                };
                this.Controls.Add(textPopup);
                textPopup.Location = new System.Drawing.Point(this.Width / 2 - textPopup.Width / 2, this.Height / 2 - textPopup.Height / 2);
                textPopup.BringToFront();
                textPopup.Show();
                break;

            case "icono":
                if (!(textPopup == null))
                {
                    textPopup.Hide();
                }
                formBar.Hide();
                iconBar.Show();
                break;
            }
        }