Exemple #1
0
        void ReleaseDesignerOutlets()
        {
            if (ResponseLabel != null)
            {
                ResponseLabel.Dispose();
                ResponseLabel = null;
            }

            if (ResultTextView != null)
            {
                ResultTextView.Dispose();
                ResultTextView = null;
            }

            if (TestButton != null)
            {
                TestButton.Dispose();
                TestButton = null;
            }

            if (TestPostButton != null)
            {
                TestPostButton.Dispose();
                TestPostButton = null;
            }
        }
        void ReleaseDesignerOutlets()
        {
            if (TestText != null)
            {
                TestText.Dispose();
                TestText = null;
            }

            if (TestButton != null)
            {
                TestButton.Dispose();
                TestButton = null;
            }
        }
        void ReleaseDesignerOutlets()
        {
            if (EventTextField != null)
            {
                EventTextField.Dispose();
                EventTextField = null;
            }

            if (LoginButton != null)
            {
                LoginButton.Dispose();
                LoginButton = null;
            }

            if (ScreenTextField != null)
            {
                ScreenTextField.Dispose();
                ScreenTextField = null;
            }

            if (SetButton != null)
            {
                SetButton.Dispose();
                SetButton = null;
            }

            if (TestButton != null)
            {
                TestButton.Dispose();
                TestButton = null;
            }

            if (TrackButton != null)
            {
                TrackButton.Dispose();
                TrackButton = null;
            }

            if (UserIdTextField != null)
            {
                UserIdTextField.Dispose();
                UserIdTextField = null;
            }
        }
        private void Form1_Load(object sender, EventArgs e)
        {
            CheckIfErrorOccured();
            TestButton.Dispose();
            CopyrightInfo.Dispose();

            Saving.CopyCSS();

            try
            {
                using (FileStream fs = new FileStream(@"ConfigurationFiles\OwnMAttack.txt", FileMode.Open))
                {
                    lock (fs)
                    {
                        using (StreamReader sr = new StreamReader(fs, Encoding.Unicode))
                        {
                            string s = "";
                            s = sr.ReadToEnd();
                            OwnMAttack.Text = s;
                        }
                    }
                }
            }
            catch
            {
                using (FileStream fs = new FileStream(@"ConfigurationFiles\OwnMAttack.txt", FileMode.Create))
                {
                    lock (fs)
                    {
                        using (StreamWriter sw = new StreamWriter(fs, Encoding.Unicode))
                        {
                            string toSave = OwnMAttack.Text = Microsoft.VisualBasic.Interaction.InputBox("What's your magic attack?\n (Without buffs and weapon)", "Need informations from user to proceed...");
                            sw.WriteLine(toSave);

                            while (OwnMAttack.Text.Length == 0)
                            {
                                sw.WriteLine(OwnMAttack.Text = Microsoft.VisualBasic.Interaction.InputBox("What's your magic attack?\n(Without buffs and weapon)", "This field cannot be empty!"));
                            }
                        }
                    }
                }
                RefreshCalculations();
            }
        }
Exemple #5
0
 public void AfterEach()
 {
     _binder.Dispose();
     _button.Dispose();
 }
Exemple #6
0
        void ReleaseDesignerOutlets()
        {
            if (RunAllTests != null)
            {
                RunAllTests.Dispose();
                RunAllTests = null;
            }

            if (ConsoleText != null)
            {
                ConsoleText.Dispose();
                ConsoleText = null;
            }

            if (CppFileList != null)
            {
                CppFileList.Dispose();
                CppFileList = null;
            }

            if (CPPFilename != null)
            {
                CPPFilename.Dispose();
                CPPFilename = null;
            }

            if (CPPRunButton != null)
            {
                CPPRunButton.Dispose();
                CPPRunButton = null;
            }

            if (CPPTextEditor != null)
            {
                CPPTextEditor.Dispose();
                CPPTextEditor = null;
            }

            if (CSharpFilename != null)
            {
                CSharpFilename.Dispose();
                CSharpFilename = null;
            }

            if (CSharpRunButton != null)
            {
                CSharpRunButton.Dispose();
                CSharpRunButton = null;
            }

            if (CSharpTextEditor != null)
            {
                CSharpTextEditor.Dispose();
                CSharpTextEditor = null;
            }

            if (IntermediateText != null)
            {
                IntermediateText.Dispose();
                IntermediateText = null;
            }

            if (OpenFileButton != null)
            {
                OpenFileButton.Dispose();
                OpenFileButton = null;
            }

            if (TestButton != null)
            {
                TestButton.Dispose();
                TestButton = null;
            }

            if (TestStatusButton != null)
            {
                TestStatusButton.Dispose();
                TestStatusButton = null;
            }
        }