diff options
| author | Alex-TIMEHACK <[email protected]> | 2017-08-27 11:32:44 +0100 |
|---|---|---|
| committer | Alex-TIMEHACK <[email protected]> | 2017-08-27 11:32:44 +0100 |
| commit | f8f3bd0b1eb57c5a289513200b192e1d54d58292 (patch) | |
| tree | c9b79515fb81d90320ef386a522a5830875f6d49 /TimeHACK.Engine/Template/Infobox95.cs | |
| parent | bffcb720f811623015ed4795032e5c57d1064c8a (diff) | |
| parent | cd6273d7c95098e0e0dd9948c6b5cec1c5f9cd3f (diff) | |
| download | histacom2-f8f3bd0b1eb57c5a289513200b192e1d54d58292.tar.gz histacom2-f8f3bd0b1eb57c5a289513200b192e1d54d58292.tar.bz2 histacom2-f8f3bd0b1eb57c5a289513200b192e1d54d58292.zip | |
Updated my fork!
Diffstat (limited to 'TimeHACK.Engine/Template/Infobox95.cs')
| -rw-r--r-- | TimeHACK.Engine/Template/Infobox95.cs | 87 |
1 files changed, 0 insertions, 87 deletions
diff --git a/TimeHACK.Engine/Template/Infobox95.cs b/TimeHACK.Engine/Template/Infobox95.cs deleted file mode 100644 index 314d8d3..0000000 --- a/TimeHACK.Engine/Template/Infobox95.cs +++ /dev/null @@ -1,87 +0,0 @@ -using System; -using System.Drawing; -using System.Media; -using System.Runtime.InteropServices; -using System.Windows.Forms; - -namespace TimeHACK.Engine.Template -{ - public partial class Infobox95 : UserControl - { - int btnStatus = 0; - - public Infobox95(InfoboxType type, InfoboxButtons btns) - { - InitializeComponent(); - button1.Paint += (sender, args) => Paintbrush.PaintClassicBorders(sender, args, 2); - button2.Paint += (sender, args) => Paintbrush.PaintClassicBorders(sender, args, 2); - button3.Paint += (sender, args) => Paintbrush.PaintClassicBorders(sender, args, 2); - - switch (type) - { - case InfoboxType.Info: - pictureBox1.Image = Properties.Resources.Win95Info; - SoundPlayer spa = new SoundPlayer(SaveSystem.currentTheme.asteriskSound); - spa.Play(); - break; - case InfoboxType.Question: - pictureBox1.Image = Properties.Resources.Win95Question; - SoundPlayer spq = new SoundPlayer(SaveSystem.currentTheme.questionSound); - spq.Play(); - break; - case InfoboxType.Warning: - pictureBox1.Image = Properties.Resources.Win95Warning; - SoundPlayer spw = new SoundPlayer(SaveSystem.currentTheme.exclamationSound); - spw.Play(); - break; - case InfoboxType.Error: - pictureBox1.Image = Properties.Resources.Win95Error; - SoundPlayer spe = new SoundPlayer(SaveSystem.currentTheme.critStopSound); - spe.Play(); - break; - } - - btnStatus = (int)btns; - switch (btns) - { - case InfoboxButtons.OK: - button1.Text = "OK"; - button2.Hide(); - button3.Hide(); - break; - } - } - - private void button2_Click(object sender, EventArgs e) - { - this.ParentForm.Close(); - } - - private void button3_Click(object sender, EventArgs e) - { - - } - - private void button1_Click(object sender, EventArgs e) - { - if (btnStatus == 0) this.ParentForm.Close(); - } - } - - public enum InfoboxType - { - Info, - Question, - Warning, - Error - } - - public enum InfoboxButtons - { - OK, - OKCancel, - YesNo, - YesNoCancel, - AbortRetryFail - } -} |
