diff options
author | sr55 <[email protected]> | 2008-04-04 16:09:04 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2008-04-04 16:09:04 +0000 |
commit | 8747cd2227c1d7e295e7c6596b6ba32a35be595b (patch) | |
tree | 8a1a003d3bf7882bafda9315cc6dee3158c3ca6a /win/C#/frmActivityWindow.cs | |
parent | 65fd8a79dbc5756d41349c22f82c659c892b75bc (diff) |
- New Audio Panel (Query Parser, Query Generator, Preset Loader Functions all updated)
This includes minor changes to the UI (e.g in the 'Output Settings' box)
- UI Improvments for Windows Vista and XP where non Classic theme is used.
- Activity Window can now view the log whilst an encode is going. (Doesn't live update... yet TODO!)
- Changed Radio File/Folder option for Source Browse to a single checkbox. Folder view by default.
Check "File mode" for file selection dialog.
- Misc other UI changes
- Update checker won't display an error message during statup if one occurs whilst checking the update.
The message was hidden behind the splash screen. This is now not a problem.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1375 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/C#/frmActivityWindow.cs')
-rw-r--r-- | win/C#/frmActivityWindow.cs | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/win/C#/frmActivityWindow.cs b/win/C#/frmActivityWindow.cs index dc8b7a642..031b8d79f 100644 --- a/win/C#/frmActivityWindow.cs +++ b/win/C#/frmActivityWindow.cs @@ -1,7 +1,7 @@ /* frmActivityWindow.cs $
This file is part of the HandBrake source code.
- Homepage: <http://handbrake.m0k.org/>.
+ Homepage: <http://handbrake.fr>.
It may be used under the terms of the GNU General Public License. */
using System;
@@ -42,15 +42,21 @@ namespace Handbrake {
try
{
- string dvdInfoPath = Path.Combine(Path.GetTempPath(), "hb_encode_log.dat");
- FileStream f = System.IO.File.Open(dvdInfoPath, FileMode.Open, FileAccess.Read, FileShare.Read);
-
- StreamReader sr = new StreamReader(f);
+ // hb_encode_log.dat is the primary log file. Since .NET can't read this file whilst the CLI is outputing to it,
+ // we'll need to make a copy of it.
+ string logFile = Path.Combine(Path.GetTempPath(), "hb_encode_log.dat");
+ string logFile2 = Path.Combine(Path.GetTempPath(), "hb_encode_log_AppReadable.dat");
+ // Make sure the application readable log file does not already exist. FileCopy fill fail if it does.
+ if (File.Exists(logFile2))
+ File.Delete(logFile2);
+ // Copy the log file.
+ File.Copy(logFile, logFile2);
+ // Begin processing the log file.
+ StreamReader sr = new StreamReader(logFile2);
string line = sr.ReadLine();
-
while (line != null)
{
this.rtf_actLog.AppendText(line + System.Environment.NewLine);
@@ -58,10 +64,10 @@ namespace Handbrake }
sr.Close();
}
- catch (Exception)
+ catch (Exception exc)
{
rtf_actLog.Clear();
- rtf_actLog.Text = "Please wait until the encode has finished to view the log.";
+ rtf_actLog.Text = "Please wait until the encode has finished to view the log. \n\n\n" + exc.ToString();
}
}
|