From ed989b753d79f018c9d955e5e7f518b25ac8ab51 Mon Sep 17 00:00:00 2001 From: sr55 Date: Sun, 6 Apr 2008 22:56:40 +0000 Subject: WinGui: - Instead of highlighting checkboxes red if their selection is invalid. Display a MessageBox explaining the error. git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1382 b64f7644-9d1e-0410-96f1-a4d463321fa5 --- win/C#/frmMain.cs | 27 +++++++-------------------- 1 file changed, 7 insertions(+), 20 deletions(-) (limited to 'win/C#/frmMain.cs') diff --git a/win/C#/frmMain.cs b/win/C#/frmMain.cs index cd0005e3a..06d1e3c29 100644 --- a/win/C#/frmMain.cs +++ b/win/C#/frmMain.cs @@ -666,41 +666,25 @@ namespace Handbrake { if ((!text_destination.Text.Contains(".mp4")) && (!text_destination.Text.Contains(".m4v"))) { - check_largeFile.BackColor = Color.LightCoral; + MessageBox.Show("You can only use this option with the .mp4/.m4v file container.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning); check_largeFile.CheckState = CheckState.Unchecked; } - else - { - check_largeFile.BackColor = Color.Transparent; - } } private void check_iPodAtom_CheckedChanged(object sender, EventArgs e) { if ((!text_destination.Text.Contains(".mp4")) && (!text_destination.Text.Contains(".m4v"))) { - text_destination.BackColor = Color.LightCoral; - check_iPodAtom.BackColor = Color.LightCoral; + MessageBox.Show("You can only use this option with the .mp4/.m4v file container.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning); check_iPodAtom.CheckState = CheckState.Unchecked; } - else - { - check_iPodAtom.BackColor = Color.Transparent; - text_destination.BackColor = Color.White; - } } - private void check_optimiseMP4_CheckedChanged(object sender, EventArgs e) + private void check_optimiseMP4_Clicked(object sender, EventArgs e) { if ((!text_destination.Text.Contains(".mp4")) && (!text_destination.Text.Contains(".m4v"))) { - check_optimiseMP4.BackColor = Color.LightCoral; - text_destination.BackColor = Color.LightCoral; + MessageBox.Show("You can only use this option with the .mp4/.m4v file container.","Warning",MessageBoxButtons.OK,MessageBoxIcon.Warning); check_optimiseMP4.CheckState = CheckState.Unchecked; } - else - { - check_optimiseMP4.BackColor = Color.Transparent; - text_destination.BackColor = Color.White; - } } //Video Tab @@ -1667,6 +1651,9 @@ namespace Handbrake #endregion + + + // This is the END of the road ------------------------------------------------------------------------------ } } \ No newline at end of file -- cgit v1.2.3