diff options
author | sr55 <[email protected]> | 2010-07-09 19:15:08 +0000 |
---|---|---|
committer | sr55 <[email protected]> | 2010-07-09 19:15:08 +0000 |
commit | 17392beaf07e263536d58ff96079bdf97d6469e6 (patch) | |
tree | 452ae9da4c785232139462e597cf3ddece62df20 /win/C#/frmMain.cs | |
parent | 52d146b4f937d3358716baeb3eb5ef703dd4c7e0 (diff) |
WinGui:
- Added a new preference that allows the user to prevent the system from going to sleep during an encode.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3431 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/C#/frmMain.cs')
-rw-r--r-- | win/C#/frmMain.cs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/win/C#/frmMain.cs b/win/C#/frmMain.cs index 6937c5923..4cf0483ec 100644 --- a/win/C#/frmMain.cs +++ b/win/C#/frmMain.cs @@ -351,12 +351,20 @@ namespace Handbrake private void encodeStarted(object sender, EventArgs e)
{
+ if (Properties.Settings.Default.preventSleep)
+ {
+ Win32.PreventSleep();
+ }
SetEncodeStarted();
encodeQueue.EncodeStatusChanged += EncodeQueue_EncodeStatusChanged;
}
private void encodeEnded(object sender, EventArgs e)
{
+ if (Properties.Settings.Default.preventSleep)
+ {
+ Win32.AllowSleep();
+ }
encodeQueue.EncodeStatusChanged -= EncodeQueue_EncodeStatusChanged;
SetEncodeFinished();
}
|