summaryrefslogtreecommitdiffstats
path: root/win/C#/Functions/Win32.cs
diff options
context:
space:
mode:
authorsr55 <[email protected]>2010-07-22 18:20:19 +0000
committersr55 <[email protected]>2010-07-22 18:20:19 +0000
commita7a9e89446f318ae286a7cf45182b3f1dee978a6 (patch)
tree017e2548bba5315d7e32d86fe728b20f2761fb21 /win/C#/Functions/Win32.cs
parent925dfe6a2292889fd623d4092747ad798b5d1606 (diff)
Reverting 3452
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3454 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'win/C#/Functions/Win32.cs')
-rw-r--r--win/C#/Functions/Win32.cs99
1 files changed, 51 insertions, 48 deletions
diff --git a/win/C#/Functions/Win32.cs b/win/C#/Functions/Win32.cs
index c2e785075..a50102688 100644
--- a/win/C#/Functions/Win32.cs
+++ b/win/C#/Functions/Win32.cs
@@ -47,13 +47,62 @@ namespace Handbrake.Functions
public static extern int ExitWindowsEx(int uFlags, int dwReason);
/// <summary>
+ /// System Memory Status
+ /// </summary>
+ public struct MEMORYSTATUS // Unused var's are required here.
+ {
+ /// <summary>
+ /// Unknown
+ /// </summary>
+ public UInt32 dwLength;
+
+ /// <summary>
+ /// Memory Load
+ /// </summary>
+ public UInt32 dwMemoryLoad;
+
+ /// <summary>
+ /// Total Physical Memory
+ /// </summary>
+ public UInt32 dwTotalPhys; // Used
+
+ /// <summary>
+ /// Available Physical Memory
+ /// </summary>
+ public UInt32 dwAvailPhys;
+
+ /// <summary>
+ /// Total Page File
+ /// </summary>
+ public UInt32 dwTotalPageFile;
+
+ /// <summary>
+ /// Available Page File
+ /// </summary>
+ public UInt32 dwAvailPageFile;
+
+ /// <summary>
+ /// Total Virtual Memory
+ /// </summary>
+ public UInt32 dwTotalVirtual;
+
+ /// <summary>
+ /// Available Virtual Memory
+ /// </summary>
+ public UInt32 dwAvailVirtual;
+ }
+
+ /// <summary>
/// Global Memory Status
/// </summary>
/// <param name="lpBuffer">
/// The lp buffer.
/// </param>
[DllImport("kernel32.dll")]
- public static extern void GlobalMemoryStatus(ref MEMORYSTATUS lpBuffer);
+ public static extern void GlobalMemoryStatus
+ (
+ ref MEMORYSTATUS lpBuffer
+ );
/// <summary>
/// Generate a Console Ctrl Event
@@ -92,7 +141,7 @@ namespace Handbrake.Functions
}
[DllImport("kernel32.dll", CharSet = CharSet.Auto, SetLastError = true)]
- public static extern EXECUTION_STATE SetThreadExecutionState(EXECUTION_STATE esFlags);
+ static extern EXECUTION_STATE SetThreadExecutionState(EXECUTION_STATE esFlags);
[FlagsAttribute]
public enum EXECUTION_STATE : uint
@@ -117,51 +166,5 @@ namespace Handbrake.Functions
{
SetThreadExecutionState(EXECUTION_STATE.ES_CONTINUOUS);
}
-
- /// <summary>
- /// System Memory Status
- /// </summary>
- public struct MEMORYSTATUS // Unused var's are required here.
- {
- /// <summary>
- /// Unknown
- /// </summary>
- public UInt32 dwLength;
-
- /// <summary>
- /// Memory Load
- /// </summary>
- public UInt32 dwMemoryLoad;
-
- /// <summary>
- /// Total Physical Memory
- /// </summary>
- public UInt32 dwTotalPhys; // Used
-
- /// <summary>
- /// Available Physical Memory
- /// </summary>
- public UInt32 dwAvailPhys;
-
- /// <summary>
- /// Total Page File
- /// </summary>
- public UInt32 dwTotalPageFile;
-
- /// <summary>
- /// Available Page File
- /// </summary>
- public UInt32 dwAvailPageFile;
-
- /// <summary>
- /// Total Virtual Memory
- /// </summary>
- public UInt32 dwTotalVirtual;
-
- /// <summary>
- /// Available Virtual Memory
- /// </summary>
- public UInt32 dwAvailVirtual;
- }
}
}