Esempio n. 1
0
        private void playButton_Click_1(object sender, EventArgs e)
        {
            ReadSettingsFile readedSettings = new ReadSettingsFile();

            readedSettings.Read();
            if (readedSettings.wowPath() == "" || readedSettings.wowPath() == null)
            {
                MessageBox.Show("WoW dir not set! Configure it in settings menu.");
            }
            else
            {
                try
                {
                    System.Diagnostics.Process.Start(readedSettings.wowPath() + "wow.exe");
                    this.Hide();
                    trayIcon.Visible = true;
                    trayIcon.ShowBalloonTip(1000);
                }
                catch (FileNotFoundException)
                {
                    MessageBox.Show("ERROR: can't find wow.exe in: \n\n '" + readedSettings.wowPath() + "' \n\n Use settings button to set World of Warcraft directory!", "Error!");
                }
                catch (DirectoryNotFoundException)
                {
                    MessageBox.Show("ERROR: can't find wow.exe in: \n\n '" + readedSettings.wowPath() + "' \n\n Use settings button to set World of Warcraft directory!", "Error!");
                }
            }
        }
Esempio n. 2
0
 private void Form3_Shown(object sender, EventArgs e)
 {
     if (this.Owner.Name == "mainForm")
     {
         ReadSettingsFile settingsFile = new ReadSettingsFile();
         settingsFile.Read();
         wowPathInput.Text              = settingsFile.wowPath();
         startUpSoundCheckBox.Checked   = settingsFile.startUpSound();
         minimizeToTrayCheckBox.Checked = settingsFile.minimizeToTray();
     }
 }
Esempio n. 3
0
 private void Form3_Shown(object sender, EventArgs e)
 {
     if (this.Owner.Name == "mainForm")
     {
         ReadSettingsFile settingsFile = new ReadSettingsFile();
         settingsFile.Read();
         wowPathInput.Text = settingsFile.wowPath();
         startUpSoundCheckBox.Checked = settingsFile.startUpSound();
         minimizeToTrayCheckBox.Checked = settingsFile.minimizeToTray();
     }
 }
Esempio n. 4
0
 private void playButton_Click_1(object sender, EventArgs e)
 {
     ReadSettingsFile readedSettings = new ReadSettingsFile();
     readedSettings.Read();
     if (readedSettings.wowPath() == "" || readedSettings.wowPath() == null)
     {
         MessageBox.Show("WoW dir not set! Configure it in settings menu.");
     }
     else
     {
         try
         {
             System.Diagnostics.Process.Start(readedSettings.wowPath() + "wow.exe");
             this.Hide();
             trayIcon.Visible = true;
             trayIcon.ShowBalloonTip(1000);
         }
         catch (FileNotFoundException)
         {
             MessageBox.Show("ERROR: can't find wow.exe in: \n\n '" + readedSettings.wowPath() + "' \n\n Use settings button to set World of Warcraft directory!", "Error!");
         }
         catch (DirectoryNotFoundException)
         {
             MessageBox.Show("ERROR: can't find wow.exe in: \n\n '" + readedSettings.wowPath() + "' \n\n Use settings button to set World of Warcraft directory!", "Error!");
         }
     }
 }