this.rtf_actLog.Location = new System.Drawing.Point(12, 12);\r
this.rtf_actLog.Name = "rtf_actLog";\r
this.rtf_actLog.ReadOnly = true;\r
- this.rtf_actLog.Size = new System.Drawing.Size(389, 381);\r
+ this.rtf_actLog.Size = new System.Drawing.Size(515, 433);\r
this.rtf_actLog.TabIndex = 29;\r
this.rtf_actLog.Text = "";\r
// \r
this.btn_close.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
this.btn_close.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
this.btn_close.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
- this.btn_close.Location = new System.Drawing.Point(273, 399);\r
+ this.btn_close.Location = new System.Drawing.Point(399, 451);\r
this.btn_close.Name = "btn_close";\r
this.btn_close.Size = new System.Drawing.Size(128, 22);\r
this.btn_close.TabIndex = 28;\r
this.btn_copy.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
this.btn_copy.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
this.btn_copy.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
- this.btn_copy.Location = new System.Drawing.Point(12, 399);\r
+ this.btn_copy.Location = new System.Drawing.Point(12, 451);\r
this.btn_copy.Name = "btn_copy";\r
this.btn_copy.Size = new System.Drawing.Size(134, 23);\r
this.btn_copy.TabIndex = 93;\r
this.btn_refresh.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
this.btn_refresh.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
this.btn_refresh.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
- this.btn_refresh.Location = new System.Drawing.Point(152, 399);\r
+ this.btn_refresh.Location = new System.Drawing.Point(152, 451);\r
this.btn_refresh.Name = "btn_refresh";\r
this.btn_refresh.Size = new System.Drawing.Size(69, 23);\r
this.btn_refresh.TabIndex = 94;\r
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 13F);\r
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;\r
this.BackColor = System.Drawing.SystemColors.ControlLight;\r
- this.ClientSize = new System.Drawing.Size(414, 434);\r
+ this.ClientSize = new System.Drawing.Size(539, 486);\r
this.Controls.Add(this.btn_refresh);\r
this.Controls.Add(this.btn_copy);\r
this.Controls.Add(this.rtf_actLog);\r
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 dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle();\r
+ System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = 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
this.Label32 = new System.Windows.Forms.Label();\r
this.Label18 = new System.Windows.Forms.Label();\r
this.TabPage3 = new System.Windows.Forms.TabPage();\r
+ this.label25 = new System.Windows.Forms.Label();\r
this.lbl_vfr = new System.Windows.Forms.Label();\r
this.check_grayscale = new System.Windows.Forms.CheckBox();\r
this.Label22 = new System.Windows.Forms.Label();\r
this.Label46 = new System.Windows.Forms.Label();\r
this.Label40 = new System.Windows.Forms.Label();\r
this.TabPage1 = new System.Windows.Forms.TabPage();\r
+ this.label6 = new System.Windows.Forms.Label();\r
+ this.drp_anamorphic = new System.Windows.Forms.ComboBox();\r
this.text_bottom = new System.Windows.Forms.NumericUpDown();\r
this.text_top = new System.Windows.Forms.NumericUpDown();\r
this.text_left = new System.Windows.Forms.NumericUpDown();\r
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.label25 = new System.Windows.Forms.Label();\r
- this.drp_anamorphic = new System.Windows.Forms.ComboBox();\r
- this.label6 = new System.Windows.Forms.Label();\r
Label38 = new System.Windows.Forms.Label();\r
((System.ComponentModel.ISupportInitialize)(this.slider_videoQuality)).BeginInit();\r
((System.ComponentModel.ISupportInitialize)(this.data_chpt)).BeginInit();\r
this.text_destination.Size = new System.Drawing.Size(429, 21);\r
this.text_destination.TabIndex = 1;\r
this.ToolTip.SetToolTip(this.text_destination, "Location where the encoded file will be saved.");\r
+ this.text_destination.TextChanged += new System.EventHandler(this.text_destination_TextChanged);\r
// \r
// btn_Browse\r
// \r
// \r
// number\r
// \r
- dataGridViewCellStyle6.Format = "N0";\r
- dataGridViewCellStyle6.NullValue = null;\r
- this.number.DefaultCellStyle = dataGridViewCellStyle6;\r
+ dataGridViewCellStyle1.Format = "N0";\r
+ dataGridViewCellStyle1.NullValue = null;\r
+ this.number.DefaultCellStyle = dataGridViewCellStyle1;\r
this.number.HeaderText = "Chapter Number";\r
this.number.MaxInputLength = 3;\r
this.number.Name = "number";\r
this.TabPage2.Location = new System.Drawing.Point(4, 22);\r
this.TabPage2.Name = "TabPage2";\r
this.TabPage2.Padding = new System.Windows.Forms.Padding(3);\r
- this.TabPage2.Size = new System.Drawing.Size(649, 274);\r
+ this.TabPage2.Size = new System.Drawing.Size(649, 283);\r
this.TabPage2.TabIndex = 3;\r
this.TabPage2.Text = "Audio && Subtitles";\r
// \r
this.TabPage3.Location = new System.Drawing.Point(4, 22);\r
this.TabPage3.Name = "TabPage3";\r
this.TabPage3.Padding = new System.Windows.Forms.Padding(3);\r
- this.TabPage3.Size = new System.Drawing.Size(649, 302);\r
+ this.TabPage3.Size = new System.Drawing.Size(649, 283);\r
this.TabPage3.TabIndex = 2;\r
this.TabPage3.Text = "Video";\r
// \r
+ // label25\r
+ // \r
+ this.label25.AutoSize = true;\r
+ this.label25.BackColor = System.Drawing.Color.Transparent;\r
+ this.label25.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
+ this.label25.Location = new System.Drawing.Point(13, 13);\r
+ this.label25.Name = "label25";\r
+ this.label25.Size = new System.Drawing.Size(76, 13);\r
+ this.label25.TabIndex = 28;\r
+ this.label25.Text = "Framerate";\r
+ // \r
// lbl_vfr\r
// \r
this.lbl_vfr.AutoSize = true;\r
this.TabPage1.TabIndex = 0;\r
this.TabPage1.Text = "Picture Settings";\r
// \r
+ // label6\r
+ // \r
+ this.label6.AutoSize = true;\r
+ this.label6.BackColor = System.Drawing.Color.Transparent;\r
+ this.label6.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
+ this.label6.Location = new System.Drawing.Point(311, 89);\r
+ this.label6.Name = "label6";\r
+ this.label6.Size = new System.Drawing.Size(80, 13);\r
+ this.label6.TabIndex = 37;\r
+ this.label6.Text = "Anamorphic:";\r
+ // \r
+ // drp_anamorphic\r
+ // \r
+ this.drp_anamorphic.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;\r
+ this.drp_anamorphic.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
+ this.drp_anamorphic.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
+ this.drp_anamorphic.FormattingEnabled = true;\r
+ this.drp_anamorphic.Items.AddRange(new object[] {\r
+ "None",\r
+ "Strict",\r
+ "Loose"});\r
+ this.drp_anamorphic.Location = new System.Drawing.Point(414, 86);\r
+ this.drp_anamorphic.Name = "drp_anamorphic";\r
+ this.drp_anamorphic.Size = new System.Drawing.Size(110, 21);\r
+ this.drp_anamorphic.TabIndex = 36;\r
+ this.drp_anamorphic.SelectedIndexChanged += new System.EventHandler(this.drp_anamorphic_SelectedIndexChanged);\r
+ // \r
// text_bottom\r
// \r
this.text_bottom.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;\r
this.tab_chapters.Controls.Add(this.Check_ChapterMarkers);\r
this.tab_chapters.Location = new System.Drawing.Point(4, 22);\r
this.tab_chapters.Name = "tab_chapters";\r
- this.tab_chapters.Size = new System.Drawing.Size(649, 274);\r
+ this.tab_chapters.Size = new System.Drawing.Size(649, 283);\r
this.tab_chapters.TabIndex = 6;\r
this.tab_chapters.Text = "Chapters";\r
// \r
this.h264Tab.Location = new System.Drawing.Point(4, 22);\r
this.h264Tab.Name = "h264Tab";\r
this.h264Tab.Padding = new System.Windows.Forms.Padding(3);\r
- this.h264Tab.Size = new System.Drawing.Size(649, 274);\r
+ this.h264Tab.Size = new System.Drawing.Size(649, 283);\r
this.h264Tab.TabIndex = 5;\r
this.h264Tab.Text = "Advanced";\r
// \r
this.tabPage4.Controls.Add(this.rtf_query);\r
this.tabPage4.Location = new System.Drawing.Point(4, 22);\r
this.tabPage4.Name = "tabPage4";\r
- this.tabPage4.Size = new System.Drawing.Size(649, 274);\r
+ this.tabPage4.Size = new System.Drawing.Size(649, 283);\r
this.tabPage4.TabIndex = 7;\r
this.tabPage4.Text = "Query Editor";\r
// \r
this.toolStripSeparator8.Name = "toolStripSeparator8";\r
this.toolStripSeparator8.Size = new System.Drawing.Size(6, 39);\r
// \r
- // label25\r
- // \r
- this.label25.AutoSize = true;\r
- this.label25.BackColor = System.Drawing.Color.Transparent;\r
- this.label25.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.label25.Location = new System.Drawing.Point(13, 13);\r
- this.label25.Name = "label25";\r
- this.label25.Size = new System.Drawing.Size(76, 13);\r
- this.label25.TabIndex = 28;\r
- this.label25.Text = "Framerate";\r
- // \r
- // drp_anamorphic\r
- // \r
- this.drp_anamorphic.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;\r
- this.drp_anamorphic.FlatStyle = System.Windows.Forms.FlatStyle.Flat;\r
- this.drp_anamorphic.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.drp_anamorphic.FormattingEnabled = true;\r
- this.drp_anamorphic.Items.AddRange(new object[] {\r
- "None",\r
- "Strict",\r
- "Loose"});\r
- this.drp_anamorphic.Location = new System.Drawing.Point(414, 86);\r
- this.drp_anamorphic.Name = "drp_anamorphic";\r
- this.drp_anamorphic.Size = new System.Drawing.Size(110, 21);\r
- this.drp_anamorphic.TabIndex = 36;\r
- this.drp_anamorphic.SelectedIndexChanged += new System.EventHandler(this.drp_anamorphic_SelectedIndexChanged);\r
- // \r
- // label6\r
- // \r
- this.label6.AutoSize = true;\r
- this.label6.BackColor = System.Drawing.Color.Transparent;\r
- this.label6.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.label6.Location = new System.Drawing.Point(311, 89);\r
- this.label6.Name = "label6";\r
- this.label6.Size = new System.Drawing.Size(80, 13);\r
- this.label6.TabIndex = 37;\r
- this.label6.Text = "Anamorphic:";\r
- // \r
// frmMain\r
// \r
this.AllowDrop = true;\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
+ setAudioByContainer(DVD_Save.FileName);\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
\r
#endregion\r
\r
+ #region Reusable Functions\r
+ private void setAudioByContainer(String path)\r
+ {\r
+ if ((path.EndsWith(".mp4")) || (path.EndsWith(".mp4")))\r
+ {\r
+ drp_audioCodec.Items.Clear();\r
+ drp_audioCodec.Items.Add("AAC");\r
+ drp_audioCodec.Items.Add("AAC + AC3");\r
+ drp_audioCodec.SelectedIndex = 0;\r
+ }\r
+ else if (path.EndsWith(".avi"))\r
+ {\r
+ drp_audioCodec.Items.Clear();\r
+ drp_audioCodec.Items.Add("MP3");\r
+ drp_audioCodec.Items.Add("AC3");\r
+ drp_audioCodec.SelectedIndex = 0;\r
+ }\r
+ else if (path.EndsWith(".ogm"))\r
+ {\r
+ drp_audioCodec.Items.Clear();\r
+ drp_audioCodec.Items.Add("Vorbis");\r
+ drp_audioCodec.SelectedIndex = 0;\r
+ }\r
+ else if (path.EndsWith(".mkv"))\r
+ {\r
+ drp_audioCodec.Items.Clear();\r
+ drp_audioCodec.Items.Add("AAC");\r
+ drp_audioCodec.Items.Add("AAC + AC3");\r
+ drp_audioCodec.Items.Add("MP3");\r
+ drp_audioCodec.Items.Add("AC3");\r
+ drp_audioCodec.Items.Add("Vorbis");\r
+ drp_audioCodec.SelectedIndex = 0;\r
+ } \r
+ }\r
+ #endregion\r
+\r
#region frmMain Actions\r
\r
+ private void text_destination_TextChanged(object sender, EventArgs e)\r
+ {\r
+ setAudioByContainer(text_destination.Text);\r
+ }\r
+\r
private void drp_dvdtitle_SelectedIndexChanged(object sender, EventArgs e)\r
{\r
// Reset some values on the form\r
selectedPreset = treeView_presets.SelectedNode.Text;\r
\r
if (!selectedPreset.StartsWith("--"))\r
- MessageBox.Show("Sorry, You can not remove any of the built in presets.","Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);\r
+ MessageBox.Show("Sorry, You can not remove any of the built in presets.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);\r
\r
\r
// Scan through the users presets and dump them all in an arraylist\r
int c = 0;\r
foreach (string item in user_presets)\r
{\r
- string preset_name = selectedPreset.Replace("--","");\r
+ string preset_name = selectedPreset.Replace("--", "");\r
if (item.Contains(preset_name))\r
modified_presets_list.RemoveAt(c);\r
c++;\r
\r
#endregion\r
\r
+\r
// This is the END of the road ------------------------------------------------------------------------------\r
}\r
}
\ No newline at end of file