diff options
-rw-r--r-- | win/C#/HandBrakeCS.csproj | 1 | ||||
-rw-r--r-- | win/C#/Parsing/Title.cs | 14 | ||||
-rw-r--r-- | win/C#/Presets/Export.cs | 177 | ||||
-rw-r--r-- | win/C#/frmMain.Designer.cs | 210 | ||||
-rw-r--r-- | win/C#/frmMain.cs | 8 | ||||
-rw-r--r-- | win/C#/frmMain.resx | 43 |
6 files changed, 324 insertions, 129 deletions
diff --git a/win/C#/HandBrakeCS.csproj b/win/C#/HandBrakeCS.csproj index 00cc4970b..a00d53034 100644 --- a/win/C#/HandBrakeCS.csproj +++ b/win/C#/HandBrakeCS.csproj @@ -219,6 +219,7 @@ <Compile Include="Functions\Main.cs" />
<Compile Include="Functions\UpdateCheckInformation.cs" />
<Compile Include="Functions\Win32.cs" />
+ <Compile Include="Presets\Export.cs" />
<Compile Include="Presets\Import.cs" />
<Compile Include="Presets\preset.cs" />
<Compile Include="Presets\PresetsHandler.cs" />
diff --git a/win/C#/Parsing/Title.cs b/win/C#/Parsing/Title.cs index a88b7bab7..f81819d43 100644 --- a/win/C#/Parsing/Title.cs +++ b/win/C#/Parsing/Title.cs @@ -25,6 +25,7 @@ namespace Handbrake.Parsing private List<String> m_angles = new List<string>();
private float m_aspectRatio;
private int[] m_autoCrop;
+ private string source;
private TimeSpan m_duration;
private Size m_resolution;
private int m_titleNumber;
@@ -72,6 +73,11 @@ namespace Handbrake.Parsing get { return m_titleNumber; }
}
+ public string SourceName
+ {
+ get { return source; }
+ }
+
/// <summary>
/// The length in time of this Title
/// </summary>
@@ -144,8 +150,12 @@ namespace Handbrake.Parsing if (m.Success)
thisTitle.m_titleNumber = int.Parse(m.Groups[1].Value.Trim());
- output.ReadLine();
-
+ // If we are scanning a groupd of files, we'll want to get the source name.
+ string path = output.ReadLine();
+ m = Regex.Match(path, @"^ \+ stream:");
+ if (m.Success)
+ thisTitle.source = path.Replace("+ stream:", "").Trim();
+
if (!Properties.Settings.Default.noDvdNav)
{
// Get the Angles for the title.
diff --git a/win/C#/Presets/Export.cs b/win/C#/Presets/Export.cs new file mode 100644 index 000000000..a2facd1a6 --- /dev/null +++ b/win/C#/Presets/Export.cs @@ -0,0 +1,177 @@ +/* Export.cs $
+
+ This file is part of the HandBrake source code.
+ Homepage: <http://handbrake.fr/>.
+ It may be used under the terms of the GNU General Public License. */
+
+using System;
+using System.Text;
+using System.Xml;
+
+namespace Handbrake.Presets
+{
+ class Export
+ {
+ // WARNING This file is not complete!!!!!!
+
+ // TODO
+ // 1. Hookup all the widgets in the GUI so it exports real values.
+ // 2. Check for any missing key/value pairs
+ // 3. Test with MacGui / Cleanup code / Retest
+
+ private XmlTextWriter writer;
+
+ public void ExportMacPreset(string path)
+ {
+ writer = new XmlTextWriter("C:\\test.xml", Encoding.UTF8);
+
+ // Header
+ writer.WriteStartDocument();
+ writer.WriteDocType("plist", "-//Apple//DTD PLIST 1.0//EN", @"http://www.apple.com/DTDs/PropertyList-1.0.dtd", null);
+
+ writer.WriteStartElement("plist");
+ writer.WriteStartElement("array");
+
+ // Add New Preset Here. Can write multiple presets here if required in future.
+ WritePreset();
+
+ // Footer
+ writer.WriteEndElement();
+ writer.WriteEndElement();
+
+ writer.WriteEndDocument();
+
+ // Closeout
+ writer.Close();
+ }
+
+ // Primary function for writing dict.
+ private void WritePreset()
+ {
+ writer.WriteStartElement("dict");
+ AudioListArrayDict();
+ AddEncodeSettings();
+
+ writer.WriteEndElement();
+ }
+
+ // Add all the encode settings to the preset
+ private void AddEncodeSettings()
+ {
+ AddEncodeElement("ChapterMarkers", "integer", "");
+ AddEncodeElement("Default", "integer", "");
+ AddEncodeElement("FileFormat", "String", "");
+ AddBooleanElement("Folder", true);
+ AddEncodeElement("Mp4HttpOptimize", "integer", "");
+ AddEncodeElement("Mp4LargeFile", "integer", "");
+ AddEncodeElement("Mp4iPodCompatible", "integer", "");
+ AddEncodeElement("PictureAutoCrop", "integer", "");
+ AddEncodeElement("PictureBottomCrop", "integer", "");
+ AddEncodeElement("PictureDeblock", "integer", "");
+ AddEncodeElement("PictureDecomb", "integer", "");
+ AddEncodeElement("PictureDecombCustom", "string", "");
+ AddEncodeElement("PictureDecombDeinterlace", "integer", "");
+ AddEncodeElement("PictureDeinterlace", "integer", "");
+ AddEncodeElement("PictureDeinterlaceCustom", "string", "");
+ AddEncodeElement("PictureDenoise", "integer", "");
+ AddEncodeElement("PictureDenoiseCustom", "string", "");
+ AddEncodeElement("PictureDetelecine", "integer", "");
+ AddEncodeElement("PictureDetelecineCustom", "string", "");
+ AddEncodeElement("PictureHeight", "integer", "");
+ AddEncodeElement("PictureKeepRatio", "integer", "");
+ AddEncodeElement("PictureLeftCrop", "integer", "");
+ AddEncodeElement("PicturePAR", "integer", "");
+ AddEncodeElement("PictureRightCrop", "integer", "");
+ AddEncodeElement("PictureTopCrop", "integer", "");
+ AddEncodeElement("PictureWidth", "integer", "");
+ AddEncodeElement("PresetBuildNumber", "string", "");
+ AddEncodeElement("PresetDescription", "string", "");
+ AddEncodeElement("PresetName", "string", "");
+ AddEncodeElement("Type", "integer", "");
+ AddEncodeElement("UsesMaxPictureSettings", "integer", "");
+ AddEncodeElement("UsesPictureFilters", "integer", "");
+ AddEncodeElement("UsesPictureSettings", "integer", "");
+ AddEncodeElement("VideoAvgBitrate", "string", "");
+ AddEncodeElement("VideoEncoder", "string", "");
+ AddEncodeElement("VideoFramerate", "string", "");
+ AddEncodeElement("VideoGrayScale", "integer", "");
+ AddEncodeElement("VideoQualitySlider", "real", "");
+ AddEncodeElement("VideoQualityType", "integer", "");
+ AddEncodeElement("VideoTargetSize", "string", "");
+ AddEncodeElement("VideoTurboTwoPass", "integer", "");
+ AddEncodeElement("VideoTwoPass", "integer", "");
+ AddEncodeElement("x264Option", "string", "");
+ }
+
+ // Add Preset setting + value
+ private void AddBooleanElement(string keyName, Boolean value)
+ {
+ writer.WriteStartElement("key");
+ writer.WriteString(keyName);
+ writer.WriteEndElement();
+ if (value)
+ {
+ writer.WriteStartElement("true");
+ writer.WriteEndElement();
+ }
+ else
+ {
+ writer.WriteStartElement("false");
+ writer.WriteEndElement();
+ }
+ }
+ private void AddEncodeElement(string keyName, string type, string value)
+ {
+ writer.WriteElementString("key", keyName);
+ writer.WriteElementString(type, value);
+ }
+
+ // Add List of audio tracks
+ private void AudioListArrayDict()
+ {
+ writer.WriteStartElement("key");
+ writer.WriteString("AudioList");
+ writer.WriteEndElement();
+
+ writer.WriteStartElement("array");
+ AddAudioItem();
+ AddAudioItem();
+ writer.WriteEndElement();
+ }
+ private void AddAudioItem()
+ {
+ int bitrate = 448;
+ string encoder = "AC3 Passthru";
+ string mixdown = "AC3 Passthru";
+ string sample = "Auto";
+ int track = 1;
+ double drc = 0.0;
+ string desc = "English (AC3) (5.1 ch)";
+
+ writer.WriteStartElement("dict");
+
+ writer.WriteElementString("key", "AudioBitrate");
+ writer.WriteElementString("string", bitrate.ToString());
+
+ writer.WriteElementString("key", "AudioEncoder");
+ writer.WriteElementString("string", encoder);
+
+ writer.WriteElementString("key", "AudioMixdown");
+ writer.WriteElementString("string", mixdown);
+
+ writer.WriteElementString("key", "AudioSamplerate");
+ writer.WriteElementString("string", sample);
+
+ writer.WriteElementString("key", "AudioTrack");
+ writer.WriteElementString("integer", track.ToString());
+
+ writer.WriteElementString("key", "AudioTrackDRCSlider");
+ writer.WriteElementString("real", drc.ToString());
+
+ writer.WriteElementString("key", "AudioTrackDescription");
+ writer.WriteElementString("string", desc);
+
+ writer.WriteEndElement();
+ }
+ }
+}
\ No newline at end of file diff --git a/win/C#/frmMain.Designer.cs b/win/C#/frmMain.Designer.cs index d1446b1e0..0c791c248 100644 --- a/win/C#/frmMain.Designer.cs +++ b/win/C#/frmMain.Designer.cs @@ -67,6 +67,7 @@ namespace Handbrake this.drop_chapterStart = new System.Windows.Forms.ComboBox();
this.drop_angle = new System.Windows.Forms.ComboBox();
this.drp_dvdtitle = new System.Windows.Forms.ComboBox();
+ this.btn_importChapters = new System.Windows.Forms.Button();
this.DVD_Open = new System.Windows.Forms.FolderBrowserDialog();
this.File_Open = new System.Windows.Forms.OpenFileDialog();
this.ISO_Open = new System.Windows.Forms.OpenFileDialog();
@@ -99,7 +100,6 @@ namespace Handbrake this.Label47 = new System.Windows.Forms.Label();
this.Label3 = new System.Windows.Forms.Label();
this.tab_audio = new System.Windows.Forms.TabPage();
- this.AudioSettings = new Handbrake.Controls.AudioPanel();
this.AudioMenuRowHeightHack = new System.Windows.Forms.ImageList(this.components);
this.tab_video = new System.Windows.Forms.TabPage();
this.radio_cq = new System.Windows.Forms.RadioButton();
@@ -111,18 +111,13 @@ namespace Handbrake this.SliderValue = new System.Windows.Forms.Label();
this.Label46 = new System.Windows.Forms.Label();
this.tab_picture = new System.Windows.Forms.TabPage();
- this.PictureSettings = new Handbrake.Controls.PictureSettings();
this.Check_ChapterMarkers = new System.Windows.Forms.CheckBox();
this.tabs_panel = new System.Windows.Forms.TabControl();
this.tab_filters = new System.Windows.Forms.TabPage();
- this.Filters = new Handbrake.Controls.Filters();
this.tab_subtitles = new System.Windows.Forms.TabPage();
- this.Subtitles = new Handbrake.Controls.Subtitles();
this.tab_chapters = new System.Windows.Forms.TabPage();
- this.btn_importChapters = new System.Windows.Forms.Button();
this.label31 = new System.Windows.Forms.Label();
this.tab_advanced = new System.Windows.Forms.TabPage();
- this.x264Panel = new Handbrake.Controls.x264Panel();
this.tab_query = new System.Windows.Forms.TabPage();
this.btn_clear = new System.Windows.Forms.Button();
this.label34 = new System.Windows.Forms.Label();
@@ -176,6 +171,11 @@ namespace Handbrake this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel();
this.openPreset = new System.Windows.Forms.OpenFileDialog();
this.File_ChapterImport = new System.Windows.Forms.OpenFileDialog();
+ this.PictureSettings = new Handbrake.Controls.PictureSettings();
+ this.Filters = new Handbrake.Controls.Filters();
+ this.AudioSettings = new Handbrake.Controls.AudioPanel();
+ this.Subtitles = new Handbrake.Controls.Subtitles();
+ this.x264Panel = new Handbrake.Controls.x264Panel();
notifyIconMenu = new System.Windows.Forms.ContextMenuStrip(this.components);
notifyIconMenu.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.slider_videoQuality)).BeginInit();
@@ -210,12 +210,12 @@ namespace Handbrake this.btn_restore});
notifyIconMenu.Name = "notifyIconMenu";
notifyIconMenu.RenderMode = System.Windows.Forms.ToolStripRenderMode.Professional;
- notifyIconMenu.Size = new System.Drawing.Size(124, 26);
+ notifyIconMenu.Size = new System.Drawing.Size(114, 26);
//
// btn_restore
//
this.btn_restore.Name = "btn_restore";
- this.btn_restore.Size = new System.Drawing.Size(123, 22);
+ this.btn_restore.Size = new System.Drawing.Size(113, 22);
this.btn_restore.Text = "Restore";
this.btn_restore.Click += new System.EventHandler(this.btn_restore_Click);
//
@@ -421,13 +421,13 @@ namespace Handbrake this.ChaptersMenu.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.mnu_resetChapters});
this.ChaptersMenu.Name = "presets_menu";
- this.ChaptersMenu.Size = new System.Drawing.Size(191, 26);
+ this.ChaptersMenu.Size = new System.Drawing.Size(188, 26);
this.ChaptersMenu.Text = ";";
//
// mnu_resetChapters
//
this.mnu_resetChapters.Name = "mnu_resetChapters";
- this.mnu_resetChapters.Size = new System.Drawing.Size(190, 22);
+ this.mnu_resetChapters.Size = new System.Drawing.Size(187, 22);
this.mnu_resetChapters.Text = "Reset Chapter Names";
this.mnu_resetChapters.Click += new System.EventHandler(this.mnu_resetChapters_Click);
//
@@ -522,6 +522,20 @@ namespace Handbrake this.drp_dvdtitle.SelectedIndexChanged += new System.EventHandler(this.drp_dvdtitle_SelectedIndexChanged);
this.drp_dvdtitle.Click += new System.EventHandler(this.drp_dvdtitle_Click);
//
+ // btn_importChapters
+ //
+ this.btn_importChapters.AutoSize = true;
+ this.btn_importChapters.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.btn_importChapters.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));
+ this.btn_importChapters.Location = new System.Drawing.Point(625, 26);
+ this.btn_importChapters.Name = "btn_importChapters";
+ this.btn_importChapters.Size = new System.Drawing.Size(75, 23);
+ this.btn_importChapters.TabIndex = 14;
+ this.btn_importChapters.Text = "Import";
+ this.ToolTip.SetToolTip(this.btn_importChapters, resources.GetString("btn_importChapters.ToolTip"));
+ this.btn_importChapters.UseVisualStyleBackColor = true;
+ this.btn_importChapters.Click += new System.EventHandler(this.btn_importChapters_Click);
+ //
// DVD_Open
//
this.DVD_Open.Description = "Select the \"VIDEO_TS\" folder from your DVD Drive.";
@@ -544,13 +558,13 @@ namespace Handbrake this.mnu_killCLI,
this.mnu_exit});
this.FileToolStripMenuItem.Name = "FileToolStripMenuItem";
- this.FileToolStripMenuItem.Size = new System.Drawing.Size(35, 20);
+ this.FileToolStripMenuItem.Size = new System.Drawing.Size(37, 20);
this.FileToolStripMenuItem.Text = "&File";
//
// mnu_killCLI
//
this.mnu_killCLI.Name = "mnu_killCLI";
- this.mnu_killCLI.Size = new System.Drawing.Size(143, 22);
+ this.mnu_killCLI.Size = new System.Drawing.Size(138, 22);
this.mnu_killCLI.Text = "Cancel Scan";
this.mnu_killCLI.Visible = false;
this.mnu_killCLI.Click += new System.EventHandler(this.mnu_killCLI_Click);
@@ -558,7 +572,7 @@ namespace Handbrake // mnu_exit
//
this.mnu_exit.Name = "mnu_exit";
- this.mnu_exit.Size = new System.Drawing.Size(143, 22);
+ this.mnu_exit.Size = new System.Drawing.Size(138, 22);
this.mnu_exit.Text = "E&xit";
this.mnu_exit.Click += new System.EventHandler(this.mnu_exit_Click);
//
@@ -575,7 +589,7 @@ namespace Handbrake this.ToolStripSeparator5,
this.mnu_options});
this.ToolsToolStripMenuItem.Name = "ToolsToolStripMenuItem";
- this.ToolsToolStripMenuItem.Size = new System.Drawing.Size(44, 20);
+ this.ToolsToolStripMenuItem.Size = new System.Drawing.Size(48, 20);
this.ToolsToolStripMenuItem.Text = "&Tools";
//
// mnu_encode
@@ -583,7 +597,7 @@ namespace Handbrake this.mnu_encode.Image = global::Handbrake.Properties.Resources.Queue_Small;
this.mnu_encode.Name = "mnu_encode";
this.mnu_encode.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Q)));
- this.mnu_encode.Size = new System.Drawing.Size(186, 22);
+ this.mnu_encode.Size = new System.Drawing.Size(184, 22);
this.mnu_encode.Text = "Show Queue";
this.mnu_encode.Click += new System.EventHandler(this.mnu_encode_Click);
//
@@ -591,20 +605,20 @@ namespace Handbrake //
this.mnu_encodeLog.Image = global::Handbrake.Properties.Resources.ActivityWindow_small;
this.mnu_encodeLog.Name = "mnu_encodeLog";
- this.mnu_encodeLog.Size = new System.Drawing.Size(186, 22);
+ this.mnu_encodeLog.Size = new System.Drawing.Size(184, 22);
this.mnu_encodeLog.Text = "Activity Window";
this.mnu_encodeLog.Click += new System.EventHandler(this.mnu_encodeLog_Click);
//
// ToolStripSeparator5
//
this.ToolStripSeparator5.Name = "ToolStripSeparator5";
- this.ToolStripSeparator5.Size = new System.Drawing.Size(183, 6);
+ this.ToolStripSeparator5.Size = new System.Drawing.Size(181, 6);
//
// mnu_options
//
this.mnu_options.Image = global::Handbrake.Properties.Resources.Pref_Small;
this.mnu_options.Name = "mnu_options";
- this.mnu_options.Size = new System.Drawing.Size(186, 22);
+ this.mnu_options.Size = new System.Drawing.Size(184, 22);
this.mnu_options.Text = "Options";
this.mnu_options.Click += new System.EventHandler(this.mnu_options_Click);
//
@@ -618,7 +632,7 @@ namespace Handbrake this.mnu_importMacPreset,
this.mnu_SelectDefault});
this.PresetsToolStripMenuItem.Name = "PresetsToolStripMenuItem";
- this.PresetsToolStripMenuItem.Size = new System.Drawing.Size(55, 20);
+ this.PresetsToolStripMenuItem.Size = new System.Drawing.Size(56, 20);
this.PresetsToolStripMenuItem.Text = "&Presets";
//
// mnu_presetReset
@@ -674,14 +688,14 @@ namespace Handbrake this.toolStripSeparator6,
this.mnu_about});
this.HelpToolStripMenuItem.Name = "HelpToolStripMenuItem";
- this.HelpToolStripMenuItem.Size = new System.Drawing.Size(40, 20);
+ this.HelpToolStripMenuItem.Size = new System.Drawing.Size(44, 20);
this.HelpToolStripMenuItem.Text = "&Help";
//
// mnu_user_guide
//
this.mnu_user_guide.Image = global::Handbrake.Properties.Resources.Help16;
this.mnu_user_guide.Name = "mnu_user_guide";
- this.mnu_user_guide.Size = new System.Drawing.Size(192, 22);
+ this.mnu_user_guide.Size = new System.Drawing.Size(194, 22);
this.mnu_user_guide.Text = "HandBrake User Guide";
this.mnu_user_guide.Click += new System.EventHandler(this.mnu_user_guide_Click);
//
@@ -689,39 +703,39 @@ namespace Handbrake //
this.mnu_handbrake_home.Image = global::Handbrake.Properties.Resources.info16;
this.mnu_handbrake_home.Name = "mnu_handbrake_home";
- this.mnu_handbrake_home.Size = new System.Drawing.Size(192, 22);
+ this.mnu_handbrake_home.Size = new System.Drawing.Size(194, 22);
this.mnu_handbrake_home.Text = "HandBrake Homepage";
this.mnu_handbrake_home.Click += new System.EventHandler(this.mnu_handbrake_home_Click);
//
// mnu_handbrake_forums
//
this.mnu_handbrake_forums.Name = "mnu_handbrake_forums";
- this.mnu_handbrake_forums.Size = new System.Drawing.Size(192, 22);
+ this.mnu_handbrake_forums.Size = new System.Drawing.Size(194, 22);
this.mnu_handbrake_forums.Text = "HandBrake Forums";
this.mnu_handbrake_forums.Click += new System.EventHandler(this.mnu_handbrake_forums_Click);
//
// ToolStripSeparator3
//
this.ToolStripSeparator3.Name = "ToolStripSeparator3";
- this.ToolStripSeparator3.Size = new System.Drawing.Size(189, 6);
+ this.ToolStripSeparator3.Size = new System.Drawing.Size(191, 6);
//
// mnu_UpdateCheck
//
this.mnu_UpdateCheck.Name = "mnu_UpdateCheck";
- this.mnu_UpdateCheck.Size = new System.Drawing.Size(192, 22);
+ this.mnu_UpdateCheck.Size = new System.Drawing.Size(194, 22);
this.mnu_UpdateCheck.Text = "Check for Updates";
this.mnu_UpdateCheck.Click += new System.EventHandler(this.mnu_UpdateCheck_Click);
//
// toolStripSeparator6
//
this.toolStripSeparator6.Name = "toolStripSeparator6";
- this.toolStripSeparator6.Size = new System.Drawing.Size(189, 6);
+ this.toolStripSeparator6.Size = new System.Drawing.Size(191, 6);
//
// mnu_about
//
this.mnu_about.Image = global::Handbrake.Properties.Resources.hb16;
this.mnu_about.Name = "mnu_about";
- this.mnu_about.Size = new System.Drawing.Size(192, 22);
+ this.mnu_about.Size = new System.Drawing.Size(194, 22);
this.mnu_about.Text = "About...";
this.mnu_about.Click += new System.EventHandler(this.mnu_about_Click);
//
@@ -784,15 +798,6 @@ namespace Handbrake this.tab_audio.Text = "Audio";
this.tab_audio.UseVisualStyleBackColor = true;
//
- // AudioSettings
- //
- this.AudioSettings.BackColor = System.Drawing.Color.Transparent;
- this.AudioSettings.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.AudioSettings.Location = new System.Drawing.Point(0, 0);
- this.AudioSettings.Name = "AudioSettings";
- this.AudioSettings.Size = new System.Drawing.Size(715, 310);
- this.AudioSettings.TabIndex = 0;
- //
// AudioMenuRowHeightHack
//
this.AudioMenuRowHeightHack.ColorDepth = System.Windows.Forms.ColorDepth.Depth8Bit;
@@ -929,16 +934,6 @@ namespace Handbrake this.tab_picture.Text = "Picture";
this.tab_picture.UseVisualStyleBackColor = true;
//
- // PictureSettings
- //
- this.PictureSettings.BackColor = System.Drawing.Color.Transparent;
- this.PictureSettings.Enabled = false;
- this.PictureSettings.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.PictureSettings.Location = new System.Drawing.Point(0, 0);
- this.PictureSettings.Name = "PictureSettings";
- this.PictureSettings.Size = new System.Drawing.Size(666, 279);
- this.PictureSettings.TabIndex = 0;
- //
// Check_ChapterMarkers
//
this.Check_ChapterMarkers.AutoSize = true;
@@ -978,15 +973,6 @@ namespace Handbrake this.tab_filters.Text = "Video Filters";
this.tab_filters.UseVisualStyleBackColor = true;
//
- // Filters
- //
- this.Filters.BackColor = System.Drawing.Color.Transparent;
- this.Filters.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.Filters.Location = new System.Drawing.Point(0, 0);
- this.Filters.Name = "Filters";
- this.Filters.Size = new System.Drawing.Size(713, 310);
- this.Filters.TabIndex = 0;
- //
// tab_subtitles
//
this.tab_subtitles.Controls.Add(this.Subtitles);
@@ -998,15 +984,6 @@ namespace Handbrake this.tab_subtitles.Text = "Subtitles";
this.tab_subtitles.UseVisualStyleBackColor = true;
//
- // Subtitles
- //
- this.Subtitles.BackColor = System.Drawing.Color.Transparent;
- this.Subtitles.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.Subtitles.Location = new System.Drawing.Point(0, 0);
- this.Subtitles.Name = "Subtitles";
- this.Subtitles.Size = new System.Drawing.Size(722, 310);
- this.Subtitles.TabIndex = 0;
- //
// tab_chapters
//
this.tab_chapters.BackColor = System.Drawing.Color.Transparent;
@@ -1021,20 +998,6 @@ namespace Handbrake this.tab_chapters.Text = "Chapters";
this.tab_chapters.UseVisualStyleBackColor = true;
//
- // btn_importChapters
- //
- this.btn_importChapters.AutoSize = true;
- this.btn_importChapters.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.btn_importChapters.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));
- this.btn_importChapters.Location = new System.Drawing.Point(625, 26);
- this.btn_importChapters.Name = "btn_importChapters";
- this.btn_importChapters.Size = new System.Drawing.Size(75, 23);
- this.btn_importChapters.TabIndex = 14;
- this.btn_importChapters.Text = "Import";
- this.ToolTip.SetToolTip(this.btn_importChapters, resources.GetString("btn_importChapters.ToolTip"));
- this.btn_importChapters.UseVisualStyleBackColor = true;
- this.btn_importChapters.Click += new System.EventHandler(this.btn_importChapters_Click);
- //
// label31
//
this.label31.AutoSize = true;
@@ -1058,16 +1021,6 @@ namespace Handbrake this.tab_advanced.Text = "Advanced";
this.tab_advanced.UseVisualStyleBackColor = true;
//
- // x264Panel
- //
- this.x264Panel.BackColor = System.Drawing.Color.Transparent;
- this.x264Panel.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
- this.x264Panel.Location = new System.Drawing.Point(0, 0);
- this.x264Panel.Name = "x264Panel";
- this.x264Panel.Size = new System.Drawing.Size(720, 306);
- this.x264Panel.TabIndex = 0;
- this.x264Panel.x264Query = "";
- //
// tab_query
//
this.tab_query.Controls.Add(this.btn_clear);
@@ -1198,52 +1151,52 @@ namespace Handbrake this.pmnu_saveChanges,
this.pmnu_delete});
this.presets_menu.Name = "presets_menu";
- this.presets_menu.Size = new System.Drawing.Size(155, 126);
+ this.presets_menu.Size = new System.Drawing.Size(148, 126);
this.presets_menu.Text = ";";
this.presets_menu.Opening += new System.ComponentModel.CancelEventHandler(this.presets_menu_Opening);
//
// pmnu_expandAll
//
this.pmnu_expandAll.Name = "pmnu_expandAll";
- this.pmnu_expandAll.Size = new System.Drawing.Size(154, 22);
+ this.pmnu_expandAll.Size = new System.Drawing.Size(147, 22);
this.pmnu_expandAll.Text = "Expand All";
this.pmnu_expandAll.Click += new System.EventHandler(this.pmnu_expandAll_Click);
//
// pmnu_collapse
//
this.pmnu_collapse.Name = "pmnu_collapse";
- this.pmnu_collapse.Size = new System.Drawing.Size(154, 22);
+ this.pmnu_collapse.Size = new System.Drawing.Size(147, 22);
this.pmnu_collapse.Text = "Collapse All";
this.pmnu_collapse.Click += new System.EventHandler(this.pmnu_collapse_Click);
//
// sep1
//
this.sep1.Name = "sep1";
- this.sep1.Size = new System.Drawing.Size(151, 6);
+ this.sep1.Size = new System.Drawing.Size(144, 6);
//
// pmnu_import
//
this.pmnu_import.Name = "pmnu_import";
- this.pmnu_import.Size = new System.Drawing.Size(154, 22);
+ this.pmnu_import.Size = new System.Drawing.Size(147, 22);
this.pmnu_import.Text = "Import";
this.pmnu_import.Click += new System.EventHandler(this.pmnu_import_Click);
//
// toolStripSeparator2
//
this.toolStripSeparator2.Name = "toolStripSeparator2";
- this.toolStripSeparator2.Size = new System.Drawing.Size(151, 6);
+ this.toolStripSeparator2.Size = new System.Drawing.Size(144, 6);
//
// pmnu_saveChanges
//
this.pmnu_saveChanges.Name = "pmnu_saveChanges";
- this.pmnu_saveChanges.Size = new System.Drawing.Size(154, 22);
+ this.pmnu_saveChanges.Size = new System.Drawing.Size(147, 22);
this.pmnu_saveChanges.Text = "Save Changes";
this.pmnu_saveChanges.Click += new System.EventHandler(this.pmnu_saveChanges_Click);
//
// pmnu_delete
//
this.pmnu_delete.Name = "pmnu_delete";
- this.pmnu_delete.Size = new System.Drawing.Size(154, 22);
+ this.pmnu_delete.Size = new System.Drawing.Size(147, 22);
this.pmnu_delete.Text = "Delete";
this.pmnu_delete.Click += new System.EventHandler(this.pmnu_delete_click);
//
@@ -1277,7 +1230,7 @@ namespace Handbrake this.btn_source.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
this.btn_source.ImageTransparentColor = System.Drawing.Color.Magenta;
this.btn_source.Name = "btn_source";
- this.btn_source.Size = new System.Drawing.Size(85, 36);
+ this.btn_source.Size = new System.Drawing.Size(88, 36);
this.btn_source.Text = "Source";
this.btn_source.ToolTipText = "Open a new source file or folder.";
this.btn_source.Click += new System.EventHandler(this.btn_source_Click);
@@ -1286,7 +1239,7 @@ namespace Handbrake //
this.btn_file_source.Image = global::Handbrake.Properties.Resources.Movies_Small;
this.btn_file_source.Name = "btn_file_source";
- this.btn_file_source.Size = new System.Drawing.Size(194, 22);
+ this.btn_file_source.Size = new System.Drawing.Size(192, 22);
this.btn_file_source.Text = "Video File";
this.btn_file_source.Click += new System.EventHandler(this.btn_file_source_Click);
//
@@ -1295,20 +1248,20 @@ namespace Handbrake this.btn_dvd_source.Image = ((System.Drawing.Image)(resources.GetObject("btn_dvd_source.Image")));
this.btn_dvd_source.ImageTransparentColor = System.Drawing.Color.Magenta;
this.btn_dvd_source.Name = "btn_dvd_source";
- this.btn_dvd_source.Size = new System.Drawing.Size(194, 22);
+ this.btn_dvd_source.Size = new System.Drawing.Size(192, 22);
this.btn_dvd_source.Text = "DVD/ VIDEO_TS Folder";
this.btn_dvd_source.Click += new System.EventHandler(this.btn_dvd_source_Click);
//
// toolStripSeparator1
//
this.toolStripSeparator1.Name = "toolStripSeparator1";
- this.toolStripSeparator1.Size = new System.Drawing.Size(191, 6);
+ this.toolStripSeparator1.Size = new System.Drawing.Size(189, 6);
//
// mnu_dvd_drive
//
this.mnu_dvd_drive.Image = global::Handbrake.Properties.Resources.disc_small;
this.mnu_dvd_drive.Name = "mnu_dvd_drive";
- this.mnu_dvd_drive.Size = new System.Drawing.Size(194, 22);
+ this.mnu_dvd_drive.Size = new System.Drawing.Size(192, 22);
this.mnu_dvd_drive.Text = "[No DVD Drive Ready]";
this.mnu_dvd_drive.Visible = false;
this.mnu_dvd_drive.Click += new System.EventHandler(this.mnu_dvd_drive_Click);
@@ -1335,7 +1288,7 @@ namespace Handbrake this.btn_add2Queue.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
this.btn_add2Queue.ImageTransparentColor = System.Drawing.Color.Magenta;
this.btn_add2Queue.Name = "btn_add2Queue";
- this.btn_add2Queue.Size = new System.Drawing.Size(110, 36);
+ this.btn_add2Queue.Size = new System.Drawing.Size(117, 36);
this.btn_add2Queue.Text = "Add to Queue";
this.btn_add2Queue.ToolTipText = "Add a new item to the Queue";
this.btn_add2Queue.Click += new System.EventHandler(this.btn_add2Queue_Click);
@@ -1346,7 +1299,7 @@ namespace Handbrake this.btn_showQueue.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
this.btn_showQueue.ImageTransparentColor = System.Drawing.Color.Magenta;
this.btn_showQueue.Name = "btn_showQueue";
- this.btn_showQueue.Size = new System.Drawing.Size(104, 36);
+ this.btn_showQueue.Size = new System.Drawing.Size(110, 36);
this.btn_showQueue.Tag = "";
this.btn_showQueue.Text = "Show Queue";
this.btn_showQueue.Click += new System.EventHandler(this.btn_showQueue_Click);
@@ -1362,7 +1315,7 @@ namespace Handbrake this.tb_preview.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
this.tb_preview.ImageTransparentColor = System.Drawing.Color.Magenta;
this.tb_preview.Name = "tb_preview";
- this.tb_preview.Size = new System.Drawing.Size(81, 36);
+ this.tb_preview.Size = new System.Drawing.Size(84, 36);
this.tb_preview.Text = "Preview";
this.tb_preview.Click += new System.EventHandler(this.tb_preview_Click);
//
@@ -1372,7 +1325,7 @@ namespace Handbrake this.btn_ActivityWindow.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None;
this.btn_ActivityWindow.ImageTransparentColor = System.Drawing.Color.Magenta;
this.btn_ActivityWindow.Name = "btn_ActivityWindow";
- this.btn_ActivityWindow.Size = new System.Drawing.Size(120, 36);
+ this.btn_ActivityWindow.Size = new System.Drawing.Size(130, 36);
this.btn_ActivityWindow.Text = "Activity Window";
this.btn_ActivityWindow.ToolTipText = "Displays the activity window which displays the log of the last completed or curr" +
"ently running encode.";
@@ -1641,6 +1594,53 @@ namespace Handbrake //
this.File_ChapterImport.Filter = "CSV Files|*.csv";
//
+ // PictureSettings
+ //
+ this.PictureSettings.BackColor = System.Drawing.Color.Transparent;
+ this.PictureSettings.Enabled = false;
+ this.PictureSettings.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.PictureSettings.Location = new System.Drawing.Point(0, 0);
+ this.PictureSettings.Name = "PictureSettings";
+ this.PictureSettings.Size = new System.Drawing.Size(666, 279);
+ this.PictureSettings.TabIndex = 0;
+ //
+ // Filters
+ //
+ this.Filters.BackColor = System.Drawing.Color.Transparent;
+ this.Filters.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.Filters.Location = new System.Drawing.Point(0, 0);
+ this.Filters.Name = "Filters";
+ this.Filters.Size = new System.Drawing.Size(713, 310);
+ this.Filters.TabIndex = 0;
+ //
+ // AudioSettings
+ //
+ this.AudioSettings.BackColor = System.Drawing.Color.Transparent;
+ this.AudioSettings.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.AudioSettings.Location = new System.Drawing.Point(0, 0);
+ this.AudioSettings.Name = "AudioSettings";
+ this.AudioSettings.Size = new System.Drawing.Size(715, 310);
+ this.AudioSettings.TabIndex = 0;
+ //
+ // Subtitles
+ //
+ this.Subtitles.BackColor = System.Drawing.Color.Transparent;
+ this.Subtitles.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.Subtitles.Location = new System.Drawing.Point(0, 0);
+ this.Subtitles.Name = "Subtitles";
+ this.Subtitles.Size = new System.Drawing.Size(722, 310);
+ this.Subtitles.TabIndex = 0;
+ //
+ // x264Panel
+ //
+ this.x264Panel.BackColor = System.Drawing.Color.Transparent;
+ this.x264Panel.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
+ this.x264Panel.Location = new System.Drawing.Point(0, 0);
+ this.x264Panel.Name = "x264Panel";
+ this.x264Panel.Size = new System.Drawing.Size(720, 306);
+ this.x264Panel.TabIndex = 0;
+ this.x264Panel.x264Query = "";
+ //
// frmMain
//
this.AllowDrop = true;
diff --git a/win/C#/frmMain.cs b/win/C#/frmMain.cs index 9cf29a270..f379ffd19 100644 --- a/win/C#/frmMain.cs +++ b/win/C#/frmMain.cs @@ -952,6 +952,10 @@ namespace Handbrake Subtitles.Clear();
Subtitles.SetSubtitleTrackAuto();
}
+ // Update the source label if we have multiple streams
+ if (selectedTitle != null)
+ if (!string.IsNullOrEmpty(selectedTitle.SourceName))
+ labelSource.Text = labelSource.Text = Path.GetFileName(selectedTitle.SourceName);
// Run the autoName & chapterNaming functions
if (Properties.Settings.Default.autoNaming)
@@ -1603,6 +1607,10 @@ namespace Handbrake private void UpdateSourceLabel()
{
labelSource.Text = string.IsNullOrEmpty(sourcePath) ? "Select \"Source\" to continue." : this.SourceName;
+
+ if (selectedTitle != null)
+ if (!string.IsNullOrEmpty(selectedTitle.SourceName)) // If it's one of multiple source files, make sure we don't use the folder name
+ labelSource.Text = Path.GetFileName(selectedTitle.SourceName);
}
#endregion
diff --git a/win/C#/frmMain.resx b/win/C#/frmMain.resx index be71f9252..057cc5471 100644 --- a/win/C#/frmMain.resx +++ b/win/C#/frmMain.resx @@ -144,6 +144,16 @@ Make sure you have selected a "Title" from the "Source" box above otherwise the list will not be populated with the correct amount of chapters.
Note: Do not change any of the chapter numbers!</value>
</data>
+ <data name="btn_importChapters.ToolTip" xml:space="preserve">
+ <value>Import a comma separated file containing the chapter information.
+The CSV should be formatted as follows:
+
+1,Chapter 1 Name
+2,Chapter 2 Name
+3,Chapter 3 Name
+
+Note: Currently, if you wish to use a , in your chapter name, you must escape it with a \</value>
+ </data>
<metadata name="DVD_Open.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>232, 15</value>
</metadata>
@@ -159,16 +169,6 @@ Note: Do not change any of the chapter numbers!</value> <metadata name="AudioMenuRowHeightHack.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>392, 54</value>
</metadata>
- <data name="btn_importChapters.ToolTip" xml:space="preserve">
- <value>Import a comma separated file containing the chapter information.
-The CSV should be formatted as follows:
-
-1,Chapter 1 Name
-2,Chapter 2 Name
-3,Chapter 3 Name
-
-Note: Currently, if you wish to use a , in your chapter name, you must escape it with a \</value>
- </data>
<metadata name="presets_menu.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>265, 54</value>
</metadata>
@@ -179,18 +179,17 @@ Note: Currently, if you wish to use a , in your chapter name, you must escape it <data name="btn_dvd_source.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
- YQUAAAAgY0hSTQAAeiYAAICEAAD6AAAAgOgAAHUwAADqYAAAOpgAABdwnLpRPAAAAlpJREFUOE+tk21I
- k1EYhif0oyA0sqIQCix/+GcQFFH9CCmiUBTLLEjShJofVBgL2fxoU9Pp5ubUlS5rU9f8rCyjsA+pUCRC
- TR1ppmVFUSlmhq78unrnQF1KGHTg/nEOz30993PO+7qJFrmUeiv2n+Mij+XLRLLYULdF2pxlEVIDcw0p
- AsyxD5fmI/rQ94pqi26eOlsfuZj+7BgSm01QdA4ih7m73Yx9qGpavwatjPebqCzOprPt8YKQgzFagqL0
- BEjyEFWVaBkdLHMxT34uYNwWR9nVTEoL0zHlp2DMSeaSRk6eKt4VWm5WM/rVPNN5SjDTLQebZEHNA1wr
- UvHjk3E6tsNcV62e1r3KLGqtKm6WplNpSsVqVFJsOM8VfSKFWjkGtcyZptSYzvC7XByx3zQoqCnTMvlG
- CX1prnornPUmQJcUXsbSVhGK5bIOkcmQyveeTHiv4VZ5Nk33Nc6iuSO8CIfmECYa/bE/8ON1iRipJNh5
- F0V6Bd86lfQ1JlFj1TDVq4COKCegLVIwHmGiKRB7/V6G7+5koHozymgfYRy5E1CgTWKgXcZ1i5qWp0KS
- rjgBcAJawph6FszYk/2M1O1isGYLX8p9ab6wgqP+3rMvYciS01GfzA1LFvQkQ6sQ9/khxhoCGHnox1Dt
- NvorxXw0b8Km8UQh2cip6GOzgNyMeKqKM7HdjqFZJ5pRk2YJ9aql3EnxoCJxNaZ4Ly6e3UDY3O6OEXRp
- 59ApTpIhiyDh9GHORAZyPHQPB/ZtZ/cOMVvFPvh6e7F+3SrWrHRnraf7Xz/xf/rJ/kvxb84I3U1y+9/W
- AAAAAElFTkSuQmCC
+ YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAJQSURBVDhPlZNdSNNRGMb/F110ZZEVhVBgeeHNICiiuggp
+ olAUyyxI0oSaH1QYC3N+tKnp5ubm1JUua5uuqdPKMgr7kApFItTUkWZqVhSVYmao5Nev/xyoQ4k88Nyc
+ 8z6/93nP4QjCfy6lwc4ltZVso4P/tMyXRcmMHqZ0EeY6jZQVInzuf0e1Tb9Ina3P/tkpLD6XkNg8BJe5
+ u93C+HDVrP4M2ZkcMOOw5tLZ9nxJyJE4HSExBoKkBQhVpTrGhso9zNPfiph0JlB+U01ZcRbmwnRMeWlc
+ 08opUCV6QissGsZ+WOY6z4hmuuXglC6pRYBbJSp+fzXNxnaZ66o1s3rkyKHWruJuWRYOcwZ2kxKr8TI3
+ DCkU6+QYNUnuNGWmLEY+5uOK3degoKZcx3SfEvozPfVB3OtNhi4ZvI2nrTIc23U9gtmYwa8eNXzScq8i
+ l6bHWnfRwhHeREJzGFONgYw/CeB9qQSZNNR9FyUGBT87lfQ3plJj1zLTq4COGDegLVo0HmeqKZjx+gOM
+ PNzDYPU2lLF+4jhyN6BIl8pgexK3bRpaXopJuhJEwGloiWDmVSgTLw4xWreXoZrtfK/wp/nKak4E+s6/
+ hDFHTkd9GndsOdCTBq1i3NdHmWgIYvRpAMO1OxlwSPhi2YpT641CuoWzsSfnAfnZiVRZ1Tjvx9GsF+bU
+ pF1BvWolD9JXUZmyDnOiD1cvbCZiYXfXCPrMi+gVZ8hOiiL53DHORwdzKnw/hw/uYt9uCTskfvj7+rBp
+ 41rWr/Fig7fX8j/Tsn/fcgx/ARfG3ml6M3rzAAAAAElFTkSuQmCC
</value>
</data>
<metadata name="notifyIcon.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|