this.btn_down = new System.Windows.Forms.Button();\r
this.btn_up = new System.Windows.Forms.Button();\r
this.btn_delete = new System.Windows.Forms.Button();\r
- this.list_queue = new System.Windows.Forms.ListBox();\r
- this.btn_Close = new System.Windows.Forms.Button();\r
- this.progressBar = new System.Windows.Forms.ProgressBar();\r
- this.label2 = new System.Windows.Forms.Label();\r
- this.lbl_progressValue = new System.Windows.Forms.Label();\r
- this.lbl_status = new System.Windows.Forms.Label();\r
this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);\r
- this.text_edit = new System.Windows.Forms.TextBox();\r
- this.btn_updateQuery = new System.Windows.Forms.Button();\r
this.label4 = new System.Windows.Forms.Label();\r
this.lbl_chapt = new System.Windows.Forms.Label();\r
this.lbl_title = new System.Windows.Forms.Label();\r
this.btn_batch = new System.Windows.Forms.ToolStripButton();\r
this.SaveFile = new System.Windows.Forms.SaveFileDialog();\r
this.pictureBox1 = new System.Windows.Forms.PictureBox();\r
+ this.list_queue = new System.Windows.Forms.ListView();\r
+ this.Title = new System.Windows.Forms.ColumnHeader();\r
+ this.Chapters = new System.Windows.Forms.ColumnHeader();\r
+ this.Source = new System.Windows.Forms.ColumnHeader();\r
+ this.Destination = new System.Windows.Forms.ColumnHeader();\r
+ this.EncoderVideo = new System.Windows.Forms.ColumnHeader();\r
+ this.Audio = new System.Windows.Forms.ColumnHeader();\r
+ this.lbl_progressValue = new System.Windows.Forms.Label();\r
+ this.progressBar = new System.Windows.Forms.ProgressBar();\r
+ this.label2 = new System.Windows.Forms.Label();\r
+ this.lbl_status = new System.Windows.Forms.Label();\r
this.toolStrip1.SuspendLayout();\r
((System.ComponentModel.ISupportInitialize)(this.pictureBox1)).BeginInit();\r
this.SuspendLayout();\r
this.btn_down.FlatAppearance.BorderColor = System.Drawing.Color.Black;\r
this.btn_down.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
this.btn_down.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
- this.btn_down.Location = new System.Drawing.Point(74, 327);\r
+ this.btn_down.Location = new System.Drawing.Point(610, 124);\r
this.btn_down.Name = "btn_down";\r
- this.btn_down.Size = new System.Drawing.Size(64, 22);\r
+ this.btn_down.Size = new System.Drawing.Size(75, 22);\r
this.btn_down.TabIndex = 33;\r
this.btn_down.TabStop = false;\r
this.btn_down.Text = "Down";\r
this.btn_up.FlatAppearance.BorderColor = System.Drawing.Color.Black;\r
this.btn_up.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
this.btn_up.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
- this.btn_up.Location = new System.Drawing.Point(13, 327);\r
+ this.btn_up.Location = new System.Drawing.Point(539, 124);\r
this.btn_up.Name = "btn_up";\r
- this.btn_up.Size = new System.Drawing.Size(55, 22);\r
+ this.btn_up.Size = new System.Drawing.Size(64, 22);\r
this.btn_up.TabIndex = 32;\r
this.btn_up.TabStop = false;\r
this.btn_up.Text = "Up";\r
this.btn_delete.FlatAppearance.BorderColor = System.Drawing.Color.Black;\r
this.btn_delete.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
this.btn_delete.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
- this.btn_delete.Location = new System.Drawing.Point(144, 327);\r
+ this.btn_delete.Location = new System.Drawing.Point(692, 124);\r
this.btn_delete.Name = "btn_delete";\r
- this.btn_delete.Size = new System.Drawing.Size(64, 22);\r
+ this.btn_delete.Size = new System.Drawing.Size(75, 22);\r
this.btn_delete.TabIndex = 31;\r
this.btn_delete.TabStop = false;\r
this.btn_delete.Text = "Delete";\r
this.btn_delete.UseVisualStyleBackColor = true;\r
this.btn_delete.Click += new System.EventHandler(this.btn_delete_Click);\r
// \r
- // list_queue\r
- // \r
- this.list_queue.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;\r
- this.list_queue.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.list_queue.HorizontalScrollbar = true;\r
- this.list_queue.Location = new System.Drawing.Point(12, 176);\r
- this.list_queue.Name = "list_queue";\r
- this.list_queue.Size = new System.Drawing.Size(701, 145);\r
- this.list_queue.TabIndex = 28;\r
- this.list_queue.SelectedIndexChanged += new System.EventHandler(this.list_queue_SelectedIndexChanged);\r
- // \r
- // btn_Close\r
- // \r
- this.btn_Close.BackColor = System.Drawing.SystemColors.ControlLight;\r
- this.btn_Close.FlatAppearance.BorderColor = System.Drawing.Color.Black;\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(605, 12);\r
- this.btn_Close.Name = "btn_Close";\r
- this.btn_Close.Size = new System.Drawing.Size(108, 22);\r
- this.btn_Close.TabIndex = 27;\r
- this.btn_Close.TabStop = false;\r
- this.btn_Close.Text = "Close Window";\r
- this.btn_Close.UseVisualStyleBackColor = false;\r
- this.btn_Close.Click += new System.EventHandler(this.btn_Close_Click);\r
- // \r
- // progressBar\r
- // \r
- this.progressBar.Location = new System.Drawing.Point(67, 360);\r
- this.progressBar.Name = "progressBar";\r
- this.progressBar.Size = new System.Drawing.Size(616, 23);\r
- this.progressBar.Style = System.Windows.Forms.ProgressBarStyle.Continuous;\r
- this.progressBar.TabIndex = 34;\r
- // \r
- // label2\r
- // \r
- this.label2.AutoSize = true;\r
- this.label2.Location = new System.Drawing.Point(10, 366);\r
- this.label2.Name = "label2";\r
- this.label2.Size = new System.Drawing.Size(51, 13);\r
- this.label2.TabIndex = 35;\r
- this.label2.Text = "Progress:";\r
- // \r
- // lbl_progressValue\r
- // \r
- this.lbl_progressValue.AutoSize = true;\r
- this.lbl_progressValue.Location = new System.Drawing.Point(689, 366);\r
- this.lbl_progressValue.Name = "lbl_progressValue";\r
- this.lbl_progressValue.Size = new System.Drawing.Size(24, 13);\r
- this.lbl_progressValue.TabIndex = 36;\r
- this.lbl_progressValue.Text = "0 %";\r
- // \r
- // lbl_status\r
- // \r
- this.lbl_status.AutoSize = true;\r
- this.lbl_status.BackColor = System.Drawing.Color.Transparent;\r
- this.lbl_status.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.lbl_status.Location = new System.Drawing.Point(274, 366);\r
- this.lbl_status.Name = "lbl_status";\r
- this.lbl_status.Size = new System.Drawing.Size(176, 13);\r
- this.lbl_status.TabIndex = 42;\r
- this.lbl_status.Text = "Encode Queue Completed!";\r
- this.lbl_status.Visible = false;\r
- // \r
- // text_edit\r
- // \r
- this.text_edit.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;\r
- this.text_edit.Location = new System.Drawing.Point(214, 328);\r
- this.text_edit.Name = "text_edit";\r
- this.text_edit.Size = new System.Drawing.Size(430, 20);\r
- this.text_edit.TabIndex = 43;\r
- this.toolTip1.SetToolTip(this.text_edit, "Avoid using this feature when the encoder is about to start a new task. You may o" +\r
- "verwrite the wrong job");\r
- // \r
- // btn_updateQuery\r
- // \r
- this.btn_updateQuery.BackColor = System.Drawing.SystemColors.ControlLight;\r
- this.btn_updateQuery.FlatAppearance.BorderColor = System.Drawing.Color.Black;\r
- this.btn_updateQuery.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.btn_updateQuery.ForeColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(0)))));\r
- this.btn_updateQuery.Location = new System.Drawing.Point(649, 325);\r
- this.btn_updateQuery.Name = "btn_updateQuery";\r
- this.btn_updateQuery.Size = new System.Drawing.Size(64, 23);\r
- this.btn_updateQuery.TabIndex = 46;\r
- this.btn_updateQuery.TabStop = false;\r
- this.btn_updateQuery.Text = "Update";\r
- this.btn_updateQuery.UseVisualStyleBackColor = true;\r
- this.btn_updateQuery.Click += new System.EventHandler(this.btn_updateQuery_Click);\r
- // \r
// label4\r
// \r
this.label4.AutoSize = true;\r
this.label4.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.label4.Location = new System.Drawing.Point(232, 125);\r
+ this.label4.Location = new System.Drawing.Point(269, 121);\r
this.label4.Name = "label4";\r
this.label4.Size = new System.Drawing.Size(47, 26);\r
this.label4.TabIndex = 70;\r
// lbl_chapt\r
// \r
this.lbl_chapt.AutoSize = true;\r
- this.lbl_chapt.Location = new System.Drawing.Point(175, 137);\r
+ this.lbl_chapt.Location = new System.Drawing.Point(202, 133);\r
this.lbl_chapt.Name = "lbl_chapt";\r
- this.lbl_chapt.Size = new System.Drawing.Size(10, 13);\r
+ this.lbl_chapt.Size = new System.Drawing.Size(12, 13);\r
this.lbl_chapt.TabIndex = 69;\r
this.lbl_chapt.Text = "-";\r
// \r
// \r
this.lbl_title.AccessibleRole = System.Windows.Forms.AccessibleRole.None;\r
this.lbl_title.AutoSize = true;\r
- this.lbl_title.Location = new System.Drawing.Point(175, 124);\r
+ this.lbl_title.Location = new System.Drawing.Point(202, 120);\r
this.lbl_title.Name = "lbl_title";\r
- this.lbl_title.Size = new System.Drawing.Size(10, 13);\r
+ this.lbl_title.Size = new System.Drawing.Size(12, 13);\r
this.lbl_title.TabIndex = 68;\r
this.lbl_title.Text = "-";\r
// \r
// lbl_aEnc\r
// \r
this.lbl_aEnc.AutoSize = true;\r
- this.lbl_aEnc.Location = new System.Drawing.Point(285, 138);\r
+ this.lbl_aEnc.Location = new System.Drawing.Point(330, 134);\r
this.lbl_aEnc.Name = "lbl_aEnc";\r
- this.lbl_aEnc.Size = new System.Drawing.Size(10, 13);\r
+ this.lbl_aEnc.Size = new System.Drawing.Size(12, 13);\r
this.lbl_aEnc.TabIndex = 67;\r
this.lbl_aEnc.Text = "-";\r
// \r
// lbl_vEnc\r
// \r
this.lbl_vEnc.AutoSize = true;\r
- this.lbl_vEnc.Location = new System.Drawing.Point(285, 125);\r
+ this.lbl_vEnc.Location = new System.Drawing.Point(330, 121);\r
this.lbl_vEnc.Name = "lbl_vEnc";\r
- this.lbl_vEnc.Size = new System.Drawing.Size(10, 13);\r
+ this.lbl_vEnc.Size = new System.Drawing.Size(12, 13);\r
this.lbl_vEnc.TabIndex = 66;\r
this.lbl_vEnc.Text = "-";\r
// \r
// lbl_dest\r
// \r
this.lbl_dest.AutoSize = true;\r
- this.lbl_dest.Location = new System.Drawing.Point(175, 112);\r
+ this.lbl_dest.Location = new System.Drawing.Point(202, 108);\r
this.lbl_dest.Name = "lbl_dest";\r
- this.lbl_dest.Size = new System.Drawing.Size(10, 13);\r
+ this.lbl_dest.Size = new System.Drawing.Size(12, 13);\r
this.lbl_dest.TabIndex = 65;\r
this.lbl_dest.Text = "-";\r
this.lbl_dest.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;\r
// lbl_source\r
// \r
this.lbl_source.AutoSize = true;\r
- this.lbl_source.Location = new System.Drawing.Point(175, 99);\r
+ this.lbl_source.Location = new System.Drawing.Point(202, 95);\r
this.lbl_source.Name = "lbl_source";\r
- this.lbl_source.Size = new System.Drawing.Size(10, 13);\r
+ this.lbl_source.Size = new System.Drawing.Size(12, 13);\r
this.lbl_source.TabIndex = 64;\r
this.lbl_source.Text = "-";\r
// \r
// \r
this.label1.AutoSize = true;\r
this.label1.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.label1.Location = new System.Drawing.Point(50, 99);\r
+ this.label1.Location = new System.Drawing.Point(56, 95);\r
this.label1.Name = "label1";\r
this.label1.Size = new System.Drawing.Size(99, 52);\r
this.label1.TabIndex = 63;\r
// \r
this.label3.AutoSize = true;\r
this.label3.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
- this.label3.Location = new System.Drawing.Point(50, 77);\r
+ this.label3.Location = new System.Drawing.Point(56, 73);\r
this.label3.Name = "label3";\r
this.label3.Size = new System.Drawing.Size(82, 13);\r
this.label3.TabIndex = 62;\r
this.toolStrip1.Location = new System.Drawing.Point(0, 0);\r
this.toolStrip1.Name = "toolStrip1";\r
this.toolStrip1.RenderMode = System.Windows.Forms.ToolStripRenderMode.System;\r
- this.toolStrip1.Size = new System.Drawing.Size(729, 49);\r
+ this.toolStrip1.Size = new System.Drawing.Size(780, 49);\r
this.toolStrip1.TabIndex = 71;\r
this.toolStrip1.Text = "toolStrip1";\r
// \r
// pictureBox1\r
// \r
this.pictureBox1.Image = global::Handbrake.Properties.Resources.Queue;\r
- this.pictureBox1.Location = new System.Drawing.Point(12, 65);\r
+ this.pictureBox1.Location = new System.Drawing.Point(12, 61);\r
this.pictureBox1.Name = "pictureBox1";\r
- this.pictureBox1.Size = new System.Drawing.Size(32, 32);\r
+ this.pictureBox1.Size = new System.Drawing.Size(37, 32);\r
this.pictureBox1.TabIndex = 61;\r
this.pictureBox1.TabStop = false;\r
// \r
+ // list_queue\r
+ // \r
+ this.list_queue.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {\r
+ this.Title,\r
+ this.Chapters,\r
+ this.Source,\r
+ this.Destination,\r
+ this.EncoderVideo,\r
+ this.Audio});\r
+ this.list_queue.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
+ this.list_queue.FullRowSelect = true;\r
+ this.list_queue.GridLines = true;\r
+ this.list_queue.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.Nonclickable;\r
+ this.list_queue.Location = new System.Drawing.Point(12, 157);\r
+ this.list_queue.MultiSelect = false;\r
+ this.list_queue.Name = "list_queue";\r
+ this.list_queue.Size = new System.Drawing.Size(755, 185);\r
+ this.list_queue.TabIndex = 72;\r
+ this.list_queue.UseCompatibleStateImageBehavior = false;\r
+ this.list_queue.View = System.Windows.Forms.View.Details;\r
+ // \r
+ // Title\r
+ // \r
+ this.Title.Text = "Title";\r
+ this.Title.Width = 39;\r
+ // \r
+ // Chapters\r
+ // \r
+ this.Chapters.Text = "Chapters";\r
+ this.Chapters.Width = 71;\r
+ // \r
+ // Source\r
+ // \r
+ this.Source.Text = "Source";\r
+ this.Source.Width = 219;\r
+ // \r
+ // Destination\r
+ // \r
+ this.Destination.Text = "Destination";\r
+ this.Destination.Width = 215;\r
+ // \r
+ // EncoderVideo\r
+ // \r
+ this.EncoderVideo.Text = "Video Encoder";\r
+ this.EncoderVideo.Width = 110;\r
+ // \r
+ // Audio\r
+ // \r
+ this.Audio.Text = "Audio Encoder";\r
+ this.Audio.Width = 94;\r
+ // \r
+ // lbl_progressValue\r
+ // \r
+ this.lbl_progressValue.AutoSize = true;\r
+ this.lbl_progressValue.Location = new System.Drawing.Point(737, 353);\r
+ this.lbl_progressValue.Name = "lbl_progressValue";\r
+ this.lbl_progressValue.Size = new System.Drawing.Size(30, 13);\r
+ this.lbl_progressValue.TabIndex = 36;\r
+ this.lbl_progressValue.Text = "0 %";\r
+ // \r
+ // progressBar\r
+ // \r
+ this.progressBar.Location = new System.Drawing.Point(76, 348);\r
+ this.progressBar.Name = "progressBar";\r
+ this.progressBar.Size = new System.Drawing.Size(655, 23);\r
+ this.progressBar.Style = System.Windows.Forms.ProgressBarStyle.Continuous;\r
+ this.progressBar.TabIndex = 34;\r
+ // \r
+ // label2\r
+ // \r
+ this.label2.AutoSize = true;\r
+ this.label2.Location = new System.Drawing.Point(9, 353);\r
+ this.label2.Name = "label2";\r
+ this.label2.Size = new System.Drawing.Size(62, 13);\r
+ this.label2.TabIndex = 35;\r
+ this.label2.Text = "Progress:";\r
+ // \r
+ // lbl_status\r
+ // \r
+ this.lbl_status.AutoSize = true;\r
+ this.lbl_status.BackColor = System.Drawing.Color.Transparent;\r
+ this.lbl_status.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
+ this.lbl_status.Location = new System.Drawing.Point(319, 353);\r
+ this.lbl_status.Name = "lbl_status";\r
+ this.lbl_status.Size = new System.Drawing.Size(176, 13);\r
+ this.lbl_status.TabIndex = 42;\r
+ this.lbl_status.Text = "Encode Queue Completed!";\r
+ this.lbl_status.Visible = false;\r
+ // \r
// frmQueue\r
// \r
- this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);\r
+ this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 13F);\r
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;\r
- this.ClientSize = new System.Drawing.Size(729, 400);\r
+ this.ClientSize = new System.Drawing.Size(780, 386);\r
+ this.Controls.Add(this.lbl_status);\r
+ this.Controls.Add(this.label2);\r
+ this.Controls.Add(this.list_queue);\r
+ this.Controls.Add(this.progressBar);\r
+ this.Controls.Add(this.lbl_progressValue);\r
+ this.Controls.Add(this.pictureBox1);\r
+ this.Controls.Add(this.btn_down);\r
+ this.Controls.Add(this.btn_up);\r
this.Controls.Add(this.toolStrip1);\r
this.Controls.Add(this.label4);\r
- this.Controls.Add(this.lbl_chapt);\r
- this.Controls.Add(this.lbl_title);\r
- this.Controls.Add(this.lbl_aEnc);\r
- this.Controls.Add(this.lbl_vEnc);\r
this.Controls.Add(this.lbl_dest);\r
+ this.Controls.Add(this.btn_delete);\r
+ this.Controls.Add(this.lbl_vEnc);\r
+ this.Controls.Add(this.lbl_chapt);\r
this.Controls.Add(this.lbl_source);\r
- this.Controls.Add(this.label1);\r
this.Controls.Add(this.label3);\r
- this.Controls.Add(this.pictureBox1);\r
- this.Controls.Add(this.list_queue);\r
- this.Controls.Add(this.btn_updateQuery);\r
- this.Controls.Add(this.btn_delete);\r
- this.Controls.Add(this.lbl_status);\r
- this.Controls.Add(this.btn_up);\r
- this.Controls.Add(this.text_edit);\r
- this.Controls.Add(this.btn_down);\r
- this.Controls.Add(this.lbl_progressValue);\r
- this.Controls.Add(this.label2);\r
- this.Controls.Add(this.progressBar);\r
- this.Controls.Add(this.btn_Close);\r
+ this.Controls.Add(this.lbl_aEnc);\r
+ this.Controls.Add(this.lbl_title);\r
+ this.Controls.Add(this.label1);\r
+ this.Font = new System.Drawing.Font("Verdana", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\r
this.Icon = ((System.Drawing.Icon)(resources.GetObject("$this.Icon")));\r
this.MaximizeBox = false;\r
this.Name = "frmQueue";\r
internal System.Windows.Forms.Button btn_down;\r
internal System.Windows.Forms.Button btn_up;\r
internal System.Windows.Forms.Button btn_delete;\r
- internal System.Windows.Forms.Button btn_Close;\r
- private System.Windows.Forms.ProgressBar progressBar;\r
- private System.Windows.Forms.Label label2;\r
- private System.Windows.Forms.Label lbl_progressValue;\r
- private System.Windows.Forms.Label lbl_status;\r
private System.Windows.Forms.ToolTip toolTip1;\r
- public System.Windows.Forms.ListBox list_queue;\r
- private System.Windows.Forms.TextBox text_edit;\r
- internal System.Windows.Forms.Button btn_updateQuery;\r
private System.Windows.Forms.Label label4;\r
private System.Windows.Forms.Label lbl_chapt;\r
private System.Windows.Forms.Label lbl_title;\r
private System.Windows.Forms.ToolStripButton btn_stop;\r
private System.Windows.Forms.ToolStripButton btn_batch;\r
private System.Windows.Forms.SaveFileDialog SaveFile;\r
+ private System.Windows.Forms.ListView list_queue;\r
+ private System.Windows.Forms.ColumnHeader Title;\r
+ private System.Windows.Forms.ColumnHeader Chapters;\r
+ private System.Windows.Forms.ColumnHeader Source;\r
+ private System.Windows.Forms.ColumnHeader Destination;\r
+ private System.Windows.Forms.ColumnHeader EncoderVideo;\r
+ private System.Windows.Forms.ColumnHeader Audio;\r
+ private System.Windows.Forms.Label lbl_progressValue;\r
+ private System.Windows.Forms.ProgressBar progressBar;\r
+ private System.Windows.Forms.Label label2;\r
+ private System.Windows.Forms.Label lbl_status;\r
}\r
}
\ No newline at end of file
Functions.CLI cliObj = new Functions.CLI();\r
Boolean cancel = false;\r
Process hbProc = null;\r
+ Functions.Queue queue;\r
\r
public frmQueue()\r
{\r
- InitializeComponent(); \r
+ InitializeComponent();\r
}\r
\r
+ /// <summary>\r
+ /// Initializes the Queue list with the Arraylist from the Queue class\r
+ /// </summary>\r
+ /// <param name="qw"></param>\r
+ public void setQueue(Functions.Queue qw)\r
+ {\r
+ queue = qw;\r
+ redrawQueue();\r
+ }\r
\r
- #region Queue / Handling\r
-\r
+ /// <summary>\r
+ /// Returns if there is currently an item being encoded by the queue\r
+ /// </summary>\r
+ /// <returns>Boolean true if encoding</returns>\r
public Boolean isEncoding()\r
{\r
if (hbProc == null)\r
return true;\r
}\r
\r
- private void btn_encode_Click(object sender, EventArgs e)\r
+ // Redraw's the queue with the latest data from the Queue class\r
+ private void redrawQueue()\r
{\r
- // Reset some values\r
+ list_queue.Items.Clear();\r
+ foreach (string queue_item in queue.getQueue())\r
+ {\r
+ Functions.QueryParser parsed = Functions.QueryParser.Parse(queue_item);\r
+\r
+ // Get the DVD Title\r
+ string title = "";\r
+ if (parsed.DVDTitle == 0)\r
+ title = "Auto";\r
+ else\r
+ title = parsed.DVDTitle.ToString();\r
+\r
+ // Get the DVD Chapters\r
+ string chapters = "";\r
+ if (parsed.DVDChapterStart == 0)\r
+ chapters = "Auto";\r
+ else\r
+ {\r
+ chapters = parsed.DVDChapterStart.ToString();\r
+ if (parsed.DVDChapterFinish != 0)\r
+ chapters = chapters + " - " + parsed.DVDChapterFinish;\r
+ }\r
+\r
+ ListViewItem item = new ListViewItem();\r
+ item.Text = title; // Title\r
+ item.SubItems.Add(chapters); // Chapters\r
+ item.SubItems.Add(parsed.Source); // Source\r
+ item.SubItems.Add(parsed.Destination); // Destination\r
+ item.SubItems.Add(parsed.VideoEncoder); // Video\r
+ item.SubItems.Add(parsed.AudioEncoder1); // Audio\r
+\r
+ list_queue.Items.Add(item);\r
+ }\r
+ }\r
\r
- if (list_queue.Items.Count != 0)\r
+ // Initializes the encode process\r
+ private void btn_encode_Click(object sender, EventArgs e)\r
+ {\r
+ if (queue.count() != 0)\r
{\r
lbl_status.Visible = false;\r
btn_encode.Enabled = false;\r
// Start the encode\r
try\r
{\r
- if (list_queue.Items.Count != 0)\r
+ if (queue.count() != 0)\r
{\r
// Setup or reset some values\r
btn_stop.Visible = true;\r
progressBar.Value = 0;\r
lbl_progressValue.Text = "0 %";\r
- progressBar.Step = 100 / list_queue.Items.Count;\r
+ progressBar.Step = 100 / queue.count();\r
progressBar.Update();\r
- //ThreadPool.QueueUserWorkItem(startProc);\r
- // Testing a new way of launching a thread. Hopefully will fix a random freeze up of the main thread.\r
Thread theQ = new Thread(startProc);\r
theQ.Start();\r
}\r
}\r
}\r
\r
- private void btn_stop_Click(object sender, EventArgs e)\r
- {\r
- cancel = true;\r
- btn_stop.Visible = false;\r
- btn_encode.Enabled = true;\r
- MessageBox.Show("No further items on the queue will start. The current encode process will continue until it is finished. \nClick 'Encode Video' when you wish to continue encoding the queue.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);\r
- }\r
-\r
+ // Starts the encoding process\r
private void startProc(object state)\r
{\r
try\r
{\r
-\r
- while (list_queue.Items.Count != 0)\r
+ // Run through each item on the queue\r
+ while (queue.count() != 0)\r
{\r
- string query = list_queue.Items[0].ToString();\r
+ string query = queue.getNextItemForEncoding();\r
+\r
setEncValue();\r
updateUIElements();\r
\r
-\r
hbProc = cliObj.runCli(this, query);\r
\r
hbProc.WaitForExit();\r
if (cancel == true)\r
{\r
break;\r
- } \r
+ }\r
}\r
\r
resetQueue();\r
\r
- \r
// After the encode is done, we may want to shutdown, suspend etc.\r
cliObj.afterEncodeAction();\r
}\r
}\r
}\r
\r
- private void updateUIElements()\r
- {\r
- try\r
- {\r
- if (this.InvokeRequired)\r
- {\r
- this.BeginInvoke(new ProgressUpdateHandler(updateUIElements));\r
- return;\r
- }\r
- this.list_queue.Items.RemoveAt(0);\r
-\r
- progressBar.PerformStep();\r
- lbl_progressValue.Text = string.Format("{0} %", progressBar.Value);\r
- progressBar.Update();\r
- }\r
- catch (Exception exc)\r
- {\r
- MessageBox.Show(exc.ToString());\r
- }\r
- }\r
-\r
+ // Reset's the window to the default state.\r
private void resetQueue()\r
{\r
try\r
{\r
lbl_status.Visible = true;\r
lbl_status.Text = "Encode Queue Cancelled!";\r
- text_edit.Text = "";\r
}\r
else\r
{\r
lbl_status.Visible = true;\r
lbl_status.Text = "Encode Queue Completed!";\r
- text_edit.Text = "";\r
}\r
- \r
+\r
lbl_progressValue.Text = "0 %";\r
progressBar.Value = 0;\r
progressBar.Update();\r
MessageBox.Show(exc.ToString());\r
}\r
}\r
- \r
+\r
+ // Stop's the queue from continuing. \r
+ private void btn_stop_Click(object sender, EventArgs e)\r
+ {\r
+ cancel = true;\r
+ btn_stop.Visible = false;\r
+ btn_encode.Enabled = true;\r
+ MessageBox.Show("No further items on the queue will start. The current encode process will continue until it is finished. \nClick 'Encode Video' when you wish to continue encoding the queue.", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);\r
+ }\r
+\r
+ // Updates the progress bar and progress label for a new status.\r
+ private void updateUIElements()\r
+ {\r
+ try\r
+ {\r
+ if (this.InvokeRequired)\r
+ {\r
+ this.BeginInvoke(new ProgressUpdateHandler(updateUIElements));\r
+ return;\r
+ }\r
+\r
+ redrawQueue();\r
+\r
+ progressBar.PerformStep();\r
+ lbl_progressValue.Text = string.Format("{0} %", progressBar.Value);\r
+ progressBar.Update();\r
+ }\r
+ catch (Exception exc)\r
+ {\r
+ MessageBox.Show(exc.ToString());\r
+ }\r
+ }\r
+\r
+ // Set's the information lables about the current encode.\r
private void setEncValue()\r
{\r
try\r
this.BeginInvoke(new setEncoding(setEncValue));\r
}\r
\r
- string query = query = list_queue.Items[0].ToString();\r
-\r
// found query is a global varible\r
- Functions.QueryParser parsed = Functions.QueryParser.Parse(query);\r
+ Functions.QueryParser parsed = Functions.QueryParser.Parse(queue.getLastQuery());\r
lbl_source.Text = parsed.Source;\r
lbl_dest.Text = parsed.Destination;\r
\r
}\r
}\r
\r
- private void list_queue_SelectedIndexChanged(object sender, EventArgs e)\r
- {\r
- if (list_queue.SelectedItem != null)\r
- text_edit.Text = list_queue.SelectedItem.ToString();\r
-\r
- listCount = list_queue.Items.Count;\r
- }\r
-\r
- #endregion\r
-\r
- #region Buttons\r
-\r
+ // Move an item up the Queue\r
private void btn_up_Click(object sender, EventArgs e)\r
{\r
- int count = list_queue.Items.Count;\r
- int itemToMove = list_queue.SelectedIndex;\r
- int previousItemint = 0;\r
- String previousItem = "";\r
-\r
- if (itemToMove > 0)\r
+ if (list_queue.SelectedIndices.Count != 0)\r
{\r
- previousItemint = itemToMove - 1;\r
- previousItem = list_queue.Items[previousItemint].ToString();\r
- list_queue.Items[previousItemint] = list_queue.Items[itemToMove];\r
- list_queue.Items[itemToMove] = previousItem;\r
- list_queue.SelectedIndex = list_queue.SelectedIndex - 1;\r
+ queue.moveUp(list_queue.SelectedIndices[0]);\r
+ redrawQueue();\r
}\r
}\r
\r
+ // Move an item down the Queue\r
private void btn_down_Click(object sender, EventArgs e)\r
{\r
- int count = list_queue.Items.Count;\r
- int itemToMove = list_queue.SelectedIndex;\r
- int itemAfterInt = 0;\r
- String itemAfter = "";\r
-\r
- if (itemToMove < (count - 1))\r
+ if (list_queue.SelectedIndices.Count != 0)\r
{\r
- itemAfterInt = itemToMove + 1;\r
- itemAfter = list_queue.Items[itemAfterInt].ToString();\r
- list_queue.Items[itemAfterInt] = list_queue.Items[itemToMove];\r
- list_queue.Items[itemToMove] = itemAfter;\r
- list_queue.SelectedIndex = list_queue.SelectedIndex + 1;\r
+ queue.moveDown(list_queue.SelectedIndices[0]);\r
+ redrawQueue();\r
}\r
}\r
\r
+ // Remove an item from the queue\r
private void btn_delete_Click(object sender, EventArgs e)\r
{\r
- list_queue.Items.Remove(list_queue.SelectedItem);\r
+ if (list_queue.SelectedIndices.Count != 0)\r
+ {\r
+ queue.remove(list_queue.SelectedIndices[0]);\r
+ redrawQueue();\r
+ }\r
}\r
\r
+ // Generate a batch file script to run the encode seperate of HandBrake\r
private void btn_batch_Click(object sender, EventArgs e)\r
{\r
string queries = "";\r
- for (int i = 0; i < list_queue.Items.Count; i++)\r
+ foreach (string query_item in queue.getQueue()) \r
{\r
- string query = list_queue.Items[i].ToString();\r
- string fullQuery = '"' + Application.StartupPath.ToString() + "\\HandBrakeCLI.exe" + '"' + query;\r
+ string fullQuery = '"' + Application.StartupPath.ToString() + "\\HandBrakeCLI.exe" + '"' + query_item;\r
\r
if (queries == "")\r
queries = queries + fullQuery;\r
{\r
try\r
{\r
- // Create a StreamWriter and open the file\r
+ // Create a StreamWriter and open the file, Write the batch file query to the file and \r
+ // Close the stream\r
StreamWriter line = new StreamWriter(filename);\r
-\r
- // Write the batch file query to the file\r
line.WriteLine(strCmdLine);\r
-\r
- // close the stream\r
line.Close();\r
\r
MessageBox.Show("Your batch script has been sucessfully saved.", "Status", MessageBoxButtons.OK, MessageBoxIcon.Asterisk);\r
}\r
}\r
\r
- int listCount = 0;\r
- private void btn_updateQuery_Click(object sender, EventArgs e)\r
- {\r
- if (text_edit.Text != "")\r
- {\r
- if (list_queue.Items.Count != listCount)\r
- {\r
- MessageBox.Show("Unable to modify the selected item. The number of items on the list has changed. \nPlease avoid modifying an item when a new encode is about to start!", "Warning", MessageBoxButtons.OK, MessageBoxIcon.Warning);\r
- }\r
- else\r
- {\r
- if (list_queue.SelectedItem != null)\r
- list_queue.Items[list_queue.SelectedIndex] = text_edit.Text;\r
-\r
- }\r
- }\r
- }\r
-\r
+ // Hide's the window from the users view.\r
private void btn_Close_Click(object sender, EventArgs e)\r
{\r
this.Hide();\r
}\r
\r
- #endregion \r
-\r
+ // Hide's the window when the user tries to "x" out of the window instead of closing it.\r
protected override void OnClosing(CancelEventArgs e)\r
{\r
e.Cancel = true;\r
this.Hide();\r
base.OnClosing(e);\r
}\r
- \r
+\r
}\r
}
\ No newline at end of file