1 /* frmActivityWindow.cs $
\r
3 This file is part of the HandBrake source code.
\r
4 Homepage: <http://handbrake.m0k.org/>.
\r
5 It may be used under the terms of the GNU General Public License. */
\r
8 using System.Collections.Generic;
\r
9 using System.ComponentModel;
\r
11 using System.Drawing;
\r
13 using System.Windows.Forms;
\r
19 public partial class frmActivityWindow : Form
\r
22 /// This window should be used to display the RAW output of the handbrake CLI which is produced during an encode.
\r
24 public frmActivityWindow()
\r
26 InitializeComponent();
\r
27 this.rtf_actLog.Text = string.Empty;
\r
30 private void btn_close_Click(object sender, EventArgs e)
\r
35 private void frmActivityWindow_Load(object sender, EventArgs e)
\r
37 this.rtf_actLog.Text = string.Empty;
\r
41 private void readFile()
\r
45 string dvdInfoPath = Path.Combine(Path.GetTempPath(), "hb_encode_log.dat");
\r
46 FileStream f = System.IO.File.Open(dvdInfoPath, FileMode.Open, FileAccess.Read, FileShare.Read);
\r
48 StreamReader sr = new StreamReader(f);
\r
52 string line = sr.ReadLine();
\r
54 while (line != null)
\r
56 this.rtf_actLog.AppendText(line + System.Environment.NewLine);
\r
57 line = sr.ReadLine();
\r
64 rtf_actLog.Text = "Please wait until the encode has finished to view the log.";
\r
68 private void btn_copy_Click(object sender, EventArgs e)
\r
70 if (rtf_actLog.Text != "")
\r
71 Clipboard.SetText(rtf_actLog.Text, TextDataFormat.Text);
\r
74 private void btn_refresh_Click(object sender, EventArgs e)
\r