summaryrefslogtreecommitdiffstats
path: root/win/CS
diff options
context:
space:
mode:
authorsr55 <[email protected]>2019-07-16 21:01:03 +0100
committersr55 <[email protected]>2019-07-16 21:01:03 +0100
commitdd8f04643a07579efa2b3ad78b71feeb68d0db43 (patch)
tree334ce820bfe9e523f01060500119bf18452bacad /win/CS
parent8d5f8fc7f55d45a082efd5c624c04b84118fb2b5 (diff)
WinGui: Support Encode Time in days. #523
Diffstat (limited to 'win/CS')
-rw-r--r--win/CS/HandBrake.Interop/Interop/HandBrakeInstance.cs4
-rw-r--r--win/CS/HandBrake.Interop/Interop/Json/State/Working.cs5
2 files changed, 7 insertions, 2 deletions
diff --git a/win/CS/HandBrake.Interop/Interop/HandBrakeInstance.cs b/win/CS/HandBrake.Interop/Interop/HandBrakeInstance.cs
index 139a62e8d..c11340ee9 100644
--- a/win/CS/HandBrake.Interop/Interop/HandBrakeInstance.cs
+++ b/win/CS/HandBrake.Interop/Interop/HandBrakeInstance.cs
@@ -463,8 +463,8 @@ namespace HandBrake.Interop.Interop
{
if (this.EncodeProgress != null)
{
- var progressEventArgs = new EncodeProgressEventArgs(state.Working.Progress, state.Working.Rate, state.Working.RateAvg, new TimeSpan(state.Working.Hours, state.Working.Minutes, state.Working.Seconds),
- state.Working.PassID, state.Working.Pass, state.Working.PassCount, taskState.Code);
+ TimeSpan eta = TimeSpan.FromSeconds(state.Working.ETASeconds);
+ var progressEventArgs = new EncodeProgressEventArgs(state.Working.Progress, state.Working.Rate, state.Working.RateAvg, eta, state.Working.PassID, state.Working.Pass, state.Working.PassCount, taskState.Code);
this.EncodeProgress(this, progressEventArgs);
}
diff --git a/win/CS/HandBrake.Interop/Interop/Json/State/Working.cs b/win/CS/HandBrake.Interop/Interop/Json/State/Working.cs
index a1b7fb0e5..4e5060031 100644
--- a/win/CS/HandBrake.Interop/Interop/Json/State/Working.cs
+++ b/win/CS/HandBrake.Interop/Interop/Json/State/Working.cs
@@ -69,5 +69,10 @@ namespace HandBrake.Interop.Interop.Json.State
/// Gets or sets the sequence id.
/// </summary>
public int SequenceID { get; set; }
+
+ /// <summary>
+ /// Gets total time remaining in seconds.
+ /// </summary>
+ public int ETASeconds { get; set; }
}
} \ No newline at end of file