diff options
Diffstat (limited to 'win/C#/HandBrake.ApplicationServices/Services')
-rw-r--r-- | win/C#/HandBrake.ApplicationServices/Services/Encode.cs | 20 | ||||
-rw-r--r-- | win/C#/HandBrake.ApplicationServices/Services/Scan.cs | 4 |
2 files changed, 5 insertions, 19 deletions
diff --git a/win/C#/HandBrake.ApplicationServices/Services/Encode.cs b/win/C#/HandBrake.ApplicationServices/Services/Encode.cs index 9ef1b2c9c..c21d83722 100644 --- a/win/C#/HandBrake.ApplicationServices/Services/Encode.cs +++ b/win/C#/HandBrake.ApplicationServices/Services/Encode.cs @@ -261,22 +261,6 @@ namespace HandBrake.ApplicationServices.Services /* Helpers */
/// <summary>
- /// Add the CLI Query to the Log File.
- /// </summary>
- /// <param name="encJob">
- /// The Encode Job Object
- /// </param>
- private static string CreateCliLogHeader(Job encJob)
- {
- StringBuilder logHeader = new StringBuilder();
- logHeader.AppendLine("# CLI Query: " + encJob.Query);
- logHeader.AppendLine("# User Query: " + encJob.CustomQuery);
- logHeader.AppendLine("-------------------------------------------");
-
- return logHeader.ToString();
- }
-
- /// <summary>
/// Save a copy of the log to the users desired location or a default location
/// if this feature is enabled in options.
/// </summary>
@@ -430,8 +414,8 @@ namespace HandBrake.ApplicationServices.Services fileWriter = new StreamWriter(logFile) { AutoFlush = true };
- fileWriter.WriteLine(CreateCliLogHeader(encodeJob));
- logBuffer.AppendLine(CreateCliLogHeader(encodeJob));
+ fileWriter.WriteLine(Logging.CreateCliLogHeader(encodeJob));
+ logBuffer.AppendLine(Logging.CreateCliLogHeader(encodeJob));
}
catch (Exception exc)
{
diff --git a/win/C#/HandBrake.ApplicationServices/Services/Scan.cs b/win/C#/HandBrake.ApplicationServices/Services/Scan.cs index 039cb3f3d..04c35e36f 100644 --- a/win/C#/HandBrake.ApplicationServices/Services/Scan.cs +++ b/win/C#/HandBrake.ApplicationServices/Services/Scan.cs @@ -191,10 +191,11 @@ namespace HandBrake.ApplicationServices.Services // Write the Buffer out to file.
StreamWriter scanLog = new StreamWriter(dvdInfoPath);
+ scanLog.WriteLine(Logging.CreateCliLogHeader(null));
scanLog.Write(this.readData.Buffer);
scanLog.Flush();
scanLog.Close();
- logBuffer = readData.Buffer;
+ logBuffer.AppendLine(this.readData.Buffer.ToString());
IsScanning = false;
@@ -268,6 +269,7 @@ namespace HandBrake.ApplicationServices.Services {
logFilePosition = 0;
logBuffer = new StringBuilder();
+ logBuffer.AppendLine(Logging.CreateCliLogHeader(null));
}
/// <summary>
|