OSDN Git Service

WinGui:
authorsr55 <sr55@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Fri, 14 Mar 2008 15:52:04 +0000 (15:52 +0000)
committersr55 <sr55@b64f7644-9d1e-0410-96f1-a4d463321fa5>
Fri, 14 Mar 2008 15:52:04 +0000 (15:52 +0000)
- Added warning about UNC file paths
- Removed the generate presets.dat function on start-up. (It wasn't really needed)
- Changed a few tooltips
- Switched back to .Net version 2

git-svn-id: svn://localhost/HandBrake/trunk@1337 b64f7644-9d1e-0410-96f1-a4d463321fa5

win/C#/HandBrakeCS.csproj
win/C#/Properties/Settings.Designer.cs
win/C#/Properties/Settings.settings
win/C#/app.config
win/C#/frmMain.Designer.cs
win/C#/frmMain.cs
win/C#/frmMain.resx
win/C#/frmOptions.Designer.cs
win/C#/frmOptions.cs

index 93cd6e8..d9c3fe0 100644 (file)
@@ -18,7 +18,7 @@
     <UpgradeBackupLocation>\r
     </UpgradeBackupLocation>\r
     <OldToolsVersion>2.0</OldToolsVersion>\r
-    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>\r
+    <TargetFrameworkVersion>v2.0</TargetFrameworkVersion>\r
     <PublishUrl>publish\</PublishUrl>\r
     <Install>true</Install>\r
     <InstallFrom>Disk</InstallFrom>\r
@@ -83,9 +83,6 @@
   </PropertyGroup>\r
   <ItemGroup>\r
     <Reference Include="System" />\r
-    <Reference Include="System.Core">\r
-      <RequiredTargetFramework>3.5</RequiredTargetFramework>\r
-    </Reference>\r
     <Reference Include="System.Data" />\r
     <Reference Include="System.Deployment" />\r
     <Reference Include="System.Drawing" />\r
index 0b2a51f..6b014a0 100644 (file)
@@ -146,18 +146,6 @@ namespace Handbrake.Properties {
         [global::System.Configuration.UserScopedSettingAttribute()]\r
         [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\r
         [global::System.Configuration.DefaultSettingValueAttribute("Checked")]\r
-        public string updatePresets {\r
-            get {\r
-                return ((string)(this["updatePresets"]));\r
-            }\r
-            set {\r
-                this["updatePresets"] = value;\r
-            }\r
-        }\r
-        \r
-        [global::System.Configuration.UserScopedSettingAttribute()]\r
-        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]\r
-        [global::System.Configuration.DefaultSettingValueAttribute("Checked")]\r
         public string autoNaming {\r
             get {\r
                 return ((string)(this["autoNaming"]));\r
index 928ae64..c526f7a 100644 (file)
@@ -32,9 +32,6 @@
     <Setting Name="skipversion" Type="System.Int32" Scope="User">\r
       <Value Profile="(Default)">0</Value>\r
     </Setting>\r
-    <Setting Name="updatePresets" Type="System.String" Scope="User">\r
-      <Value Profile="(Default)">Checked</Value>\r
-    </Setting>\r
     <Setting Name="autoNaming" Type="System.String" Scope="User">\r
       <Value Profile="(Default)">Checked</Value>\r
     </Setting>\r
index f39705b..f5213e9 100644 (file)
@@ -37,9 +37,6 @@
             <setting name="skipversion" serializeAs="String">\r
                 <value>0</value>\r
             </setting>\r
-            <setting name="updatePresets" serializeAs="String">\r
-                <value>Checked</value>\r
-            </setting>\r
             <setting name="autoNaming" serializeAs="String">\r
                 <value>Checked</value>\r
             </setting>\r
index 0ce9530..54845cc 100644 (file)
@@ -37,7 +37,7 @@ namespace Handbrake
             this.components = new System.ComponentModel.Container();\r
             System.Windows.Forms.Label Label38;\r
             System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(frmMain));\r
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();\r
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();\r
             this.DVD_Save = new System.Windows.Forms.SaveFileDialog();\r
             this.File_Save = new System.Windows.Forms.SaveFileDialog();\r
             this.ToolTip = new System.Windows.Forms.ToolTip(this.components);\r
@@ -200,7 +200,6 @@ namespace Handbrake
             this.toolStripSeparator4 = new System.Windows.Forms.ToolStripSeparator();\r
             this.btn_ActivityWindow = new System.Windows.Forms.ToolStripButton();\r
             this.toolStripSeparator8 = new System.Windows.Forms.ToolStripSeparator();\r
-            this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);\r
             Label38 = new System.Windows.Forms.Label();\r
             ((System.ComponentModel.ISupportInitialize)(this.slider_videoQuality)).BeginInit();\r
             ((System.ComponentModel.ISupportInitialize)(this.slider_drc)).BeginInit();\r
@@ -442,8 +441,8 @@ namespace Handbrake
             this.check_largeFile.Size = new System.Drawing.Size(82, 17);\r
             this.check_largeFile.TabIndex = 4;\r
             this.check_largeFile.Text = "64Bit MP4";\r
-            this.ToolTip.SetToolTip(this.check_largeFile, "Allows creation of MP4 files greater than 4GB.\r\nWarning: Breaks iPod, Apple TV an" +\r
-                    "d PS3 compatibility.");\r
+            this.ToolTip.SetToolTip(this.check_largeFile, "Allows creation of MP4 files greater than 4GB.\r\nWarning: Breaks iPod, Apple TV Ve" +\r
+                    "rsion 1 and PS3 compatibility.");\r
             this.check_largeFile.UseVisualStyleBackColor = false;\r
             this.check_largeFile.CheckedChanged += new System.EventHandler(this.check_largeFile_CheckedChanged);\r
             // \r
@@ -602,7 +601,6 @@ namespace Handbrake
             this.slider_drc.Size = new System.Drawing.Size(241, 42);\r
             this.slider_drc.TabIndex = 18;\r
             this.slider_drc.TickFrequency = 10;\r
-            this.ToolTip.SetToolTip(this.slider_drc, "Dynamic Range Compression");\r
             this.slider_drc.Scroll += new System.EventHandler(this.slider_drc_Scroll);\r
             // \r
             // rtf_h264advanced\r
@@ -631,7 +629,7 @@ namespace Handbrake
             // \r
             // DVD_Open\r
             // \r
-            this.DVD_Open.Description = "Select the \"VIDEO_TS\" folder from your DVD Drvie.";\r
+            this.DVD_Open.Description = "Select the \"VIDEO_TS\" folder from your DVD Drive.";\r
             // \r
             // File_Open\r
             // \r
@@ -973,6 +971,8 @@ namespace Handbrake
             this.check_optimiseMP4.Size = new System.Drawing.Size(143, 17);\r
             this.check_optimiseMP4.TabIndex = 25;\r
             this.check_optimiseMP4.Text = "HTTP Optimized MP4";\r
+            this.ToolTip.SetToolTip(this.check_optimiseMP4, "MP4 files can be optimized for progressive downloads over the Web, but note that " +\r
+                    "QuickTime can only read the files as long as the file extension is .mp4.");\r
             this.check_optimiseMP4.UseVisualStyleBackColor = false;\r
             this.check_optimiseMP4.CheckedChanged += new System.EventHandler(this.check_optimiseMP4_CheckedChanged);\r
             // \r
@@ -1386,6 +1386,8 @@ namespace Handbrake
             this.check_iPodAtom.Size = new System.Drawing.Size(122, 17);\r
             this.check_iPodAtom.TabIndex = 26;\r
             this.check_iPodAtom.Text = "Insert iPod Atom";\r
+            this.ToolTip.SetToolTip(this.check_iPodAtom, "Required for 5th and 6th Generation iPods. Encodes will not sync if this is not e" +\r
+                    "nabled for H.264 encodes");\r
             this.check_iPodAtom.UseVisualStyleBackColor = false;\r
             this.check_iPodAtom.CheckedChanged += new System.EventHandler(this.check_iPodAtom_CheckedChanged);\r
             // \r
@@ -1844,12 +1846,13 @@ namespace Handbrake
             this.data_chpt.Name = "data_chpt";\r
             this.data_chpt.Size = new System.Drawing.Size(607, 182);\r
             this.data_chpt.TabIndex = 2;\r
+            this.ToolTip.SetToolTip(this.data_chpt, resources.GetString("data_chpt.ToolTip"));\r
             // \r
             // number\r
             // \r
-            dataGridViewCellStyle2.Format = "N0";\r
-            dataGridViewCellStyle2.NullValue = null;\r
-            this.number.DefaultCellStyle = dataGridViewCellStyle2;\r
+            dataGridViewCellStyle3.Format = "N0";\r
+            dataGridViewCellStyle3.NullValue = null;\r
+            this.number.DefaultCellStyle = dataGridViewCellStyle3;\r
             this.number.HeaderText = "Chapter Number";\r
             this.number.MaxInputLength = 3;\r
             this.number.Name = "number";\r
@@ -2104,6 +2107,7 @@ namespace Handbrake
             this.btn_start.Name = "btn_start";\r
             this.btn_start.Size = new System.Drawing.Size(67, 36);\r
             this.btn_start.Text = "Start";\r
+            this.btn_start.ToolTipText = "Start the encoding process";\r
             this.btn_start.Click += new System.EventHandler(this.btn_start_Click);\r
             // \r
             // toolStripSeparator1\r
@@ -2119,6 +2123,7 @@ namespace Handbrake
             this.btn_add2Queue.Name = "btn_add2Queue";\r
             this.btn_add2Queue.Size = new System.Drawing.Size(110, 36);\r
             this.btn_add2Queue.Text = "Add to Queue";\r
+            this.btn_add2Queue.ToolTipText = "Add a new item to the Queue";\r
             this.btn_add2Queue.Click += new System.EventHandler(this.btn_add2Queue_Click);\r
             // \r
             // btn_showQueue\r
@@ -2128,6 +2133,7 @@ namespace Handbrake
             this.btn_showQueue.ImageTransparentColor = System.Drawing.Color.Magenta;\r
             this.btn_showQueue.Name = "btn_showQueue";\r
             this.btn_showQueue.Size = new System.Drawing.Size(104, 36);\r
+            this.btn_showQueue.Tag = "";\r
             this.btn_showQueue.Text = "Show Queue";\r
             this.btn_showQueue.Click += new System.EventHandler(this.btn_showQueue_Click);\r
             // \r
@@ -2144,6 +2150,8 @@ namespace Handbrake
             this.btn_ActivityWindow.Name = "btn_ActivityWindow";\r
             this.btn_ActivityWindow.Size = new System.Drawing.Size(120, 36);\r
             this.btn_ActivityWindow.Text = "Activity Window";\r
+            this.btn_ActivityWindow.ToolTipText = "Displays the activity window which displays the log of the last completed or curr" +\r
+                "ently running encode.";\r
             this.btn_ActivityWindow.Click += new System.EventHandler(this.btn_ActivityWindow_Click);\r
             // \r
             // toolStripSeparator8\r
@@ -2371,7 +2379,6 @@ namespace Handbrake
         private System.Windows.Forms.ToolStripSeparator toolStripSeparator4;\r
         private System.Windows.Forms.ToolStripButton btn_ActivityWindow;\r
         private System.Windows.Forms.ToolStripSeparator toolStripSeparator8;\r
-        private System.Windows.Forms.ToolTip toolTip1;\r
         private System.Windows.Forms.Label lbl_warn_chapt;\r
         private System.Windows.Forms.ToolStripMenuItem mnu_handbrake_home;\r
 \r
index d93bbfa..3c945b9 100644 (file)
@@ -56,9 +56,7 @@ namespace Handbrake
 \r
             // show the form, but leave disabled until preloading is complete then show the main form\r
             this.Enabled = false;\r
-\r
             this.Show();\r
-\r
             // Forces frmMain to draw\r
             Application.DoEvents();\r
 \r
@@ -74,27 +72,20 @@ namespace Handbrake
 \r
             // Load the presets\r
             // Set some defaults for the dropdown menus. Just incase the normal or user presets dont load.\r
-            drp_crop.SelectedIndex = 0;\r
-\r
-            lblStatus.Text = "Loading Presets ...";\r
+            lblStatus.Text = "Loading Presets Bar ...";\r
             Application.DoEvents();\r
-            if (Properties.Settings.Default.updatePresets == "Checked")\r
-            {\r
-                grabCLIPresets();\r
-            }\r
+            drp_crop.SelectedIndex = 0;\r
             loadPresetPanel();\r
             Thread.Sleep(200);\r
       \r
             // Now load the users default if required. (Will overide the above setting)\r
+            lblStatus.Text = "Loading Preset Settings ...";\r
+            Application.DoEvents();\r
             if (Properties.Settings.Default.defaultSettings == "Checked")\r
-            {\r
-                lblStatus.Text = "Loading User Default Settings...";\r
-                Application.DoEvents();\r
                 loadUserDefaults();\r
-                Thread.Sleep(100);\r
-            }\r
             else\r
                 loadNormalPreset();\r
+            Thread.Sleep(100);\r
 \r
             // Enable or disable tooltips\r
             if (Properties.Settings.Default.tooltipEnable == "Checked")\r
@@ -357,18 +348,24 @@ namespace Handbrake
                 filename = ISO_Open.FileName;\r
             }\r
 \r
-            if (filename != "")\r
-            {\r
-                Form frmRD = new frmReadDVD(filename, this, dvdInfoWindow);\r
-                text_source.Text = filename;\r
-                frmRD.ShowDialog();\r
-            }\r
+            if (filename.StartsWith("\\"))\r
+                MessageBox.Show("Sorry, HandBrake does not support UNC file paths. \nTry mounting the share as a network drive in My Computer", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);\r
             else\r
-                text_source.Text = "Click 'Browse' to continue";\r
+            {\r
+                if (filename != "")\r
+                {\r
+                    Form frmRD = new frmReadDVD(filename, this, dvdInfoWindow);\r
+                    text_source.Text = filename;\r
+                    frmRD.ShowDialog();\r
+                }\r
+                else\r
+                    text_source.Text = "Click 'Browse' to continue";\r
 \r
-            // If there are no titles in the dropdown menu then the scan has obviously failed. Display an error message explaining to the user.\r
-            if (drp_dvdtitle.Items.Count == 0)\r
-                MessageBox.Show("No Title(s) found. Please make sure you have selected a valid, non-copy protected source. Please refer to the FAQ (see Help Menu).", "Error", MessageBoxButtons.OK, MessageBoxIcon.Hand);\r
+                // If there are no titles in the dropdown menu then the scan has obviously failed. Display an error message explaining to the user.\r
+                if (drp_dvdtitle.Items.Count == 0)\r
+                    MessageBox.Show("No Title(s) found. Please make sure you have selected a valid, non-copy protected source. Please refer to the FAQ (see Help Menu).", "Error", MessageBoxButtons.OK, MessageBoxIcon.Hand);\r
+\r
+            }\r
         }\r
 \r
         private void btn_destBrowse_Click(object sender, EventArgs e)\r
@@ -379,11 +376,16 @@ namespace Handbrake
 \r
             // Show the dialog and set the main form file path\r
             DVD_Save.ShowDialog();\r
-            text_destination.Text = DVD_Save.FileName;\r
+            if (DVD_Save.FileName.StartsWith("\\"))\r
+                MessageBox.Show("Sorry, HandBrake does not support UNC file paths. \nTry mounting the share as a network drive in My Computer", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);\r
+            else\r
+            {\r
+                text_destination.Text = DVD_Save.FileName;\r
 \r
-            // Quicktime requires .m4v file for chapter markers to work. If checked, change the extension to .m4v (mp4 and m4v are the same thing)\r
-            if (Check_ChapterMarkers.Checked)\r
-                text_destination.Text = text_destination.Text.Replace(".mp4", ".m4v");\r
+                // Quicktime requires .m4v file for chapter markers to work. If checked, change the extension to .m4v (mp4 and m4v are the same thing)\r
+                if (Check_ChapterMarkers.Checked)\r
+                    text_destination.Text = text_destination.Text.Replace(".mp4", ".m4v");\r
+            }\r
         }\r
 \r
         private void btn_h264Clear_Click(object sender, EventArgs e)\r
index e4500ad..807a16b 100644 (file)
@@ -189,6 +189,12 @@ Best used in conjunction with forced subtitles.</value>
   <metadata name="name.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">\r
     <value>True</value>\r
   </metadata>\r
+  <data name="data_chpt.ToolTip" xml:space="preserve">\r
+    <value>Here you can name each chapter that the encoded video will contain.\r
+Make sure you have selected a "Title" from the "Source" box above otherwise \r
+the list will not be populated with the correct amount of chapters.\r
+Note: Do not change any of the chapter numbers!</value>\r
+  </data>\r
   <metadata name="number.UserAddedColumn" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">\r
     <value>True</value>\r
   </metadata>\r
@@ -198,9 +204,6 @@ Best used in conjunction with forced subtitles.</value>
   <metadata name="toolStrip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">\r
     <value>731, 18</value>\r
   </metadata>\r
-  <metadata name="toolTip1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">\r
-    <value>830, 18</value>\r
-  </metadata>\r
   <metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">\r
     <value>56</value>\r
   </metadata>\r
index 97b40d9..94bba95 100644 (file)
@@ -40,7 +40,6 @@ namespace Handbrake
             this.label5 = new System.Windows.Forms.Label();\r
             this.tab_options = new System.Windows.Forms.TabControl();\r
             this.tab_general = new System.Windows.Forms.TabPage();\r
-            this.check_updatePresets = new System.Windows.Forms.CheckBox();\r
             this.check_tooltip = new System.Windows.Forms.CheckBox();\r
             this.check_updateCheck = new System.Windows.Forms.CheckBox();\r
             this.check_userDefaultSettings = new System.Windows.Forms.CheckBox();\r
@@ -127,7 +126,6 @@ namespace Handbrake
             // tab_general\r
             // \r
             this.tab_general.BackColor = System.Drawing.SystemColors.ControlLight;\r
-            this.tab_general.Controls.Add(this.check_updatePresets);\r
             this.tab_general.Controls.Add(this.check_tooltip);\r
             this.tab_general.Controls.Add(this.check_updateCheck);\r
             this.tab_general.Controls.Add(this.check_userDefaultSettings);\r
@@ -140,19 +138,6 @@ namespace Handbrake
             this.tab_general.Text = "Startup";\r
             this.tab_general.UseVisualStyleBackColor = true;\r
             // \r
-            // check_updatePresets\r
-            // \r
-            this.check_updatePresets.AutoSize = true;\r
-            this.check_updatePresets.BackColor = System.Drawing.Color.Transparent;\r
-            this.check_updatePresets.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
-            this.check_updatePresets.Location = new System.Drawing.Point(16, 102);\r
-            this.check_updatePresets.Name = "check_updatePresets";\r
-            this.check_updatePresets.Size = new System.Drawing.Size(112, 17);\r
-            this.check_updatePresets.TabIndex = 59;\r
-            this.check_updatePresets.Text = "Update presets";\r
-            this.check_updatePresets.UseVisualStyleBackColor = false;\r
-            this.check_updatePresets.CheckedChanged += new System.EventHandler(this.check_updatePresets_CheckedChanged);\r
-            // \r
             // check_tooltip\r
             // \r
             this.check_tooltip.AutoSize = true;\r
@@ -447,7 +432,6 @@ namespace Handbrake
         private System.Windows.Forms.Label label8;\r
         private System.Windows.Forms.PictureBox pictureBox2;\r
         private System.Windows.Forms.Label label7;\r
-        internal System.Windows.Forms.CheckBox check_updatePresets;\r
         private System.Windows.Forms.TabPage tabPage1;\r
         private System.Windows.Forms.Label label9;\r
         internal System.Windows.Forms.CheckBox check_autoNaming;\r
index 83bbffb..000afdc 100644 (file)
@@ -40,11 +40,6 @@ namespace Handbrake
                 check_tooltip.CheckState = CheckState.Checked;\r
             }\r
 \r
-            if (Properties.Settings.Default.updatePresets == "Checked")\r
-            {\r
-                check_updatePresets.CheckState = CheckState.Checked;\r
-            }\r
-\r
             if (Properties.Settings.Default.autoNaming == "Checked")\r
             {\r
                 check_autoNaming.CheckState = CheckState.Checked;\r
@@ -93,11 +88,6 @@ namespace Handbrake
             Properties.Settings.Default.CompletionOption = drp_completeOption.Text;\r
         }\r
 \r
-        private void check_updatePresets_CheckedChanged(object sender, EventArgs e)\r
-        {\r
-            Properties.Settings.Default.updatePresets = check_updatePresets.CheckState.ToString();\r
-        }\r
-\r
         private void check_autoNaming_CheckedChanged(object sender, EventArgs e)\r
         {\r
             Properties.Settings.Default.autoNaming = check_autoNaming.CheckState.ToString();\r