Automated dotnet-format update

This commit is contained in:
github-actions-dotnet-formatter[bot] 2020-12-06 03:21:24 +00:00
parent 035ef17569
commit 1476fd2e03
156 changed files with 8279 additions and 8279 deletions

View File

@ -2,12 +2,12 @@
namespace Microsoft.Windows.Shell
{
public abstract class JumpItem
{
internal JumpItem()
{
}
public abstract class JumpItem
{
internal JumpItem()
{
}
public string CustomCategory { get; set; }
}
public string CustomCategory { get; set; }
}
}

View File

@ -2,11 +2,11 @@
namespace Microsoft.Windows.Shell
{
public enum JumpItemRejectionReason
{
None,
InvalidItem,
NoRegisteredHandler,
RemovedByUser
}
public enum JumpItemRejectionReason
{
None,
InvalidItem,
NoRegisteredHandler,
RemovedByUser
}
}

View File

@ -3,30 +3,30 @@ using System.Collections.Generic;
namespace Microsoft.Windows.Shell
{
public sealed class JumpItemsRejectedEventArgs : EventArgs
{
public JumpItemsRejectedEventArgs() : this(null, null)
{
}
public sealed class JumpItemsRejectedEventArgs : EventArgs
{
public JumpItemsRejectedEventArgs() : this(null, null)
{
}
public JumpItemsRejectedEventArgs(IList<JumpItem> rejectedItems, IList<JumpItemRejectionReason> reasons)
{
if ((rejectedItems == null && reasons != null) || (reasons == null && rejectedItems != null) || (rejectedItems != null && reasons != null && rejectedItems.Count != reasons.Count))
{
throw new ArgumentException("The counts of rejected items doesn't match the count of reasons.");
}
if (rejectedItems != null)
{
this.RejectedItems = new List<JumpItem>(rejectedItems).AsReadOnly();
this.RejectionReasons = new List<JumpItemRejectionReason>(reasons).AsReadOnly();
return;
}
this.RejectedItems = new List<JumpItem>().AsReadOnly();
this.RejectionReasons = new List<JumpItemRejectionReason>().AsReadOnly();
}
public JumpItemsRejectedEventArgs(IList<JumpItem> rejectedItems, IList<JumpItemRejectionReason> reasons)
{
if ((rejectedItems == null && reasons != null) || (reasons == null && rejectedItems != null) || (rejectedItems != null && reasons != null && rejectedItems.Count != reasons.Count))
{
throw new ArgumentException("The counts of rejected items doesn't match the count of reasons.");
}
if (rejectedItems != null)
{
this.RejectedItems = new List<JumpItem>(rejectedItems).AsReadOnly();
this.RejectionReasons = new List<JumpItemRejectionReason>(reasons).AsReadOnly();
return;
}
this.RejectedItems = new List<JumpItem>().AsReadOnly();
this.RejectionReasons = new List<JumpItemRejectionReason>().AsReadOnly();
}
public IList<JumpItem> RejectedItems { get; private set; }
public IList<JumpItem> RejectedItems { get; private set; }
public IList<JumpItemRejectionReason> RejectionReasons { get; private set; }
}
public IList<JumpItemRejectionReason> RejectionReasons { get; private set; }
}
}

View File

@ -3,22 +3,22 @@ using System.Collections.Generic;
namespace Microsoft.Windows.Shell
{
public sealed class JumpItemsRemovedEventArgs : EventArgs
{
public JumpItemsRemovedEventArgs() : this(null)
{
}
public sealed class JumpItemsRemovedEventArgs : EventArgs
{
public JumpItemsRemovedEventArgs() : this(null)
{
}
public JumpItemsRemovedEventArgs(IList<JumpItem> removedItems)
{
if (removedItems != null)
{
this.RemovedItems = new List<JumpItem>(removedItems).AsReadOnly();
return;
}
this.RemovedItems = new List<JumpItem>().AsReadOnly();
}
public JumpItemsRemovedEventArgs(IList<JumpItem> removedItems)
{
if (removedItems != null)
{
this.RemovedItems = new List<JumpItem>(removedItems).AsReadOnly();
return;
}
this.RemovedItems = new List<JumpItem>().AsReadOnly();
}
public IList<JumpItem> RemovedItems { get; private set; }
}
public IList<JumpItem> RemovedItems { get; private set; }
}
}

File diff suppressed because it is too large Load Diff

View File

@ -2,8 +2,8 @@
namespace Microsoft.Windows.Shell
{
public class JumpPath : JumpItem
{
public string Path { get; set; }
}
public class JumpPath : JumpItem
{
public string Path { get; set; }
}
}

View File

@ -2,20 +2,20 @@
namespace Microsoft.Windows.Shell
{
public class JumpTask : JumpItem
{
public string Title { get; set; }
public class JumpTask : JumpItem
{
public string Title { get; set; }
public string Description { get; set; }
public string Description { get; set; }
public string ApplicationPath { get; set; }
public string ApplicationPath { get; set; }
public string Arguments { get; set; }
public string Arguments { get; set; }
public string WorkingDirectory { get; set; }
public string WorkingDirectory { get; set; }
public string IconResourcePath { get; set; }
public string IconResourcePath { get; set; }
public int IconResourceIndex { get; set; }
}
public int IconResourceIndex { get; set; }
}
}

View File

@ -2,9 +2,9 @@
namespace Standard
{
internal enum AC : byte
{
SRC_OVER,
SRC_ALPHA
}
internal enum AC : byte
{
SRC_OVER,
SRC_ALPHA
}
}

View File

@ -2,9 +2,9 @@
namespace Standard
{
internal enum APPDOCLISTTYPE
{
ADLT_RECENT,
ADLT_FREQUENT
}
internal enum APPDOCLISTTYPE
{
ADLT_RECENT,
ADLT_FREQUENT
}
}

View File

@ -5,229 +5,229 @@ using System.Windows;
namespace Standard
{
internal static class Assert
{
private static void _Break()
{
Debugger.Break();
}
internal static class Assert
{
private static void _Break()
{
Debugger.Break();
}
[Conditional("DEBUG")]
public static void Evaluate(Assert.EvaluateFunction argument)
{
argument();
}
[Conditional("DEBUG")]
public static void Evaluate(Assert.EvaluateFunction argument)
{
argument();
}
[Obsolete("Use Assert.AreEqual instead of Assert.Equals", false)]
[Conditional("DEBUG")]
public static void Equals<T>(T expected, T actual)
{
}
[Obsolete("Use Assert.AreEqual instead of Assert.Equals", false)]
[Conditional("DEBUG")]
public static void Equals<T>(T expected, T actual)
{
}
[Conditional("DEBUG")]
public static void AreEqual<T>(T expected, T actual)
{
if (expected == null)
{
if (actual != null && !actual.Equals(expected))
{
Assert._Break();
return;
}
}
else if (!expected.Equals(actual))
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void AreEqual<T>(T expected, T actual)
{
if (expected == null)
{
if (actual != null && !actual.Equals(expected))
{
Assert._Break();
return;
}
}
else if (!expected.Equals(actual))
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void AreNotEqual<T>(T notExpected, T actual)
{
if (notExpected == null)
{
if (actual == null || actual.Equals(notExpected))
{
Assert._Break();
return;
}
}
else if (notExpected.Equals(actual))
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void AreNotEqual<T>(T notExpected, T actual)
{
if (notExpected == null)
{
if (actual == null || actual.Equals(notExpected))
{
Assert._Break();
return;
}
}
else if (notExpected.Equals(actual))
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void Implies(bool condition, bool result)
{
if (condition && !result)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void Implies(bool condition, bool result)
{
if (condition && !result)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void Implies(bool condition, Assert.ImplicationFunction result)
{
if (condition && !result())
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void Implies(bool condition, Assert.ImplicationFunction result)
{
if (condition && !result())
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsNeitherNullNorEmpty(string value)
{
}
[Conditional("DEBUG")]
public static void IsNeitherNullNorEmpty(string value)
{
}
[Conditional("DEBUG")]
public static void IsNeitherNullNorWhitespace(string value)
{
if (string.IsNullOrEmpty(value))
{
Assert._Break();
}
if (value.Trim().Length == 0)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsNeitherNullNorWhitespace(string value)
{
if (string.IsNullOrEmpty(value))
{
Assert._Break();
}
if (value.Trim().Length == 0)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsNotNull<T>(T value) where T : class
{
if (value == null)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsNotNull<T>(T value) where T : class
{
if (value == null)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsDefault<T>(T value) where T : struct
{
value.Equals(default(T));
}
[Conditional("DEBUG")]
public static void IsDefault<T>(T value) where T : struct
{
value.Equals(default(T));
}
[Conditional("DEBUG")]
public static void IsNotDefault<T>(T value) where T : struct
{
value.Equals(default(T));
}
[Conditional("DEBUG")]
public static void IsNotDefault<T>(T value) where T : struct
{
value.Equals(default(T));
}
[Conditional("DEBUG")]
public static void IsFalse(bool condition)
{
if (condition)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsFalse(bool condition)
{
if (condition)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsFalse(bool condition, string message)
{
if (condition)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsFalse(bool condition, string message)
{
if (condition)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsTrue(bool condition)
{
if (!condition)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsTrue(bool condition)
{
if (!condition)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsTrue(bool condition, string message)
{
if (!condition)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsTrue(bool condition, string message)
{
if (!condition)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void Fail()
{
Assert._Break();
}
[Conditional("DEBUG")]
public static void Fail()
{
Assert._Break();
}
[Conditional("DEBUG")]
public static void Fail(string message)
{
Assert._Break();
}
[Conditional("DEBUG")]
public static void Fail(string message)
{
Assert._Break();
}
[Conditional("DEBUG")]
public static void IsNull<T>(T item) where T : class
{
if (item != null)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsNull<T>(T item) where T : class
{
if (item != null)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void BoundedDoubleInc(double lowerBoundInclusive, double value, double upperBoundInclusive)
{
if (value < lowerBoundInclusive || value > upperBoundInclusive)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void BoundedDoubleInc(double lowerBoundInclusive, double value, double upperBoundInclusive)
{
if (value < lowerBoundInclusive || value > upperBoundInclusive)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void BoundedInteger(int lowerBoundInclusive, int value, int upperBoundExclusive)
{
if (value < lowerBoundInclusive || value >= upperBoundExclusive)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void BoundedInteger(int lowerBoundInclusive, int value, int upperBoundExclusive)
{
if (value < lowerBoundInclusive || value >= upperBoundExclusive)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsApartmentState(ApartmentState expectedState)
{
if (Thread.CurrentThread.GetApartmentState() != expectedState)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsApartmentState(ApartmentState expectedState)
{
if (Thread.CurrentThread.GetApartmentState() != expectedState)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void NullableIsNotNull<T>(T? value) where T : struct
{
if (value == null)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void NullableIsNotNull<T>(T? value) where T : struct
{
if (value == null)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void NullableIsNull<T>(T? value) where T : struct
{
if (value != null)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void NullableIsNull<T>(T? value) where T : struct
{
if (value != null)
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsNotOnMainThread()
{
if (Application.Current.Dispatcher.CheckAccess())
{
Assert._Break();
}
}
[Conditional("DEBUG")]
public static void IsNotOnMainThread()
{
if (Application.Current.Dispatcher.CheckAccess())
{
Assert._Break();
}
}
public delegate void EvaluateFunction();
public delegate void EvaluateFunction();
public delegate bool ImplicationFunction();
}
public delegate bool ImplicationFunction();
}
}

View File

@ -2,8 +2,8 @@
namespace Standard
{
internal enum BI
{
RGB
}
internal enum BI
{
RGB
}
}

View File

@ -2,10 +2,10 @@
namespace Standard
{
internal struct BITMAPINFO
{
public BITMAPINFOHEADER bmiHeader;
internal struct BITMAPINFO
{
public BITMAPINFOHEADER bmiHeader;
public RGBQUAD bmiColors;
}
public RGBQUAD bmiColors;
}
}

View File

@ -3,29 +3,29 @@ using System.Runtime.InteropServices;
namespace Standard
{
[StructLayout(LayoutKind.Sequential, Pack = 2)]
internal struct BITMAPINFOHEADER
{
public int biSize;
[StructLayout(LayoutKind.Sequential, Pack = 2)]
internal struct BITMAPINFOHEADER
{
public int biSize;
public int biWidth;
public int biWidth;
public int biHeight;
public int biHeight;
public short biPlanes;
public short biPlanes;
public short biBitCount;
public short biBitCount;
public BI biCompression;
public BI biCompression;
public int biSizeImage;
public int biSizeImage;
public int biXPelsPerMeter;
public int biXPelsPerMeter;
public int biYPelsPerMeter;
public int biYPelsPerMeter;
public int biClrUsed;
public int biClrUsed;
public int biClrImportant;
}
public int biClrImportant;
}
}

View File

@ -2,14 +2,14 @@
namespace Standard
{
internal struct BLENDFUNCTION
{
public AC BlendOp;
internal struct BLENDFUNCTION
{
public AC BlendOp;
public byte BlendFlags;
public byte BlendFlags;
public byte SourceConstantAlpha;
public byte SourceConstantAlpha;
public AC AlphaFormat;
}
public AC AlphaFormat;
}
}

View File

@ -2,10 +2,10 @@
namespace Standard
{
internal struct CHANGEFILTERSTRUCT
{
public uint cbSize;
internal struct CHANGEFILTERSTRUCT
{
public uint cbSize;
public MSGFLTINFO ExtStatus;
}
public MSGFLTINFO ExtStatus;
}
}

View File

@ -2,23 +2,23 @@
namespace Standard
{
internal static class CLSID
{
public static T CoCreateInstance<T>(string clsid)
{
return (T)((object)Activator.CreateInstance(Type.GetTypeFromCLSID(new Guid(clsid))));
}
internal static class CLSID
{
public static T CoCreateInstance<T>(string clsid)
{
return (T) ((object) Activator.CreateInstance(Type.GetTypeFromCLSID(new Guid(clsid))));
}
public const string TaskbarList = "56FDF344-FD6D-11d0-958A-006097C9A090";
public const string TaskbarList = "56FDF344-FD6D-11d0-958A-006097C9A090";
public const string EnumerableObjectCollection = "2d3468c1-36a7-43b6-ac24-d3f02fd9607a";
public const string EnumerableObjectCollection = "2d3468c1-36a7-43b6-ac24-d3f02fd9607a";
public const string ShellLink = "00021401-0000-0000-C000-000000000046";
public const string ShellLink = "00021401-0000-0000-C000-000000000046";
public const string DestinationList = "77f10cf0-3db5-4966-b520-b7c54fd35ed6";
public const string DestinationList = "77f10cf0-3db5-4966-b520-b7c54fd35ed6";
public const string ApplicationDestinations = "86c14003-4d6b-4ef3-a7b4-0506663b2e68";
public const string ApplicationDestinations = "86c14003-4d6b-4ef3-a7b4-0506663b2e68";
public const string ApplicationDocumentLists = "86bec222-30f2-47e0-9f25-60d11cd75c28";
}
public const string ApplicationDocumentLists = "86bec222-30f2-47e0-9f25-60d11cd75c28";
}
}

View File

@ -3,33 +3,33 @@ using System.Runtime.InteropServices;
namespace Standard
{
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
internal struct CREATESTRUCT
{
public IntPtr lpCreateParams;
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
internal struct CREATESTRUCT
{
public IntPtr lpCreateParams;
public IntPtr hInstance;
public IntPtr hInstance;
public IntPtr hMenu;
public IntPtr hMenu;
public IntPtr hwndParent;
public IntPtr hwndParent;
public int cy;
public int cy;
public int cx;
public int cx;
public int y;
public int y;
public int x;
public int x;
public WS style;
public WS style;
[MarshalAs(UnmanagedType.LPWStr)]
public string lpszName;
[MarshalAs(UnmanagedType.LPWStr)]
public string lpszName;
[MarshalAs(UnmanagedType.LPWStr)]
public string lpszClass;
[MarshalAs(UnmanagedType.LPWStr)]
public string lpszClass;
public WS_EX dwExStyle;
}
public WS_EX dwExStyle;
}
}

View File

@ -2,21 +2,21 @@
namespace Standard
{
[Flags]
internal enum CS : uint
{
VREDRAW = 1u,
HREDRAW = 2u,
DBLCLKS = 8u,
OWNDC = 32u,
CLASSDC = 64u,
PARENTDC = 128u,
NOCLOSE = 512u,
SAVEBITS = 2048u,
BYTEALIGNCLIENT = 4096u,
BYTEALIGNWINDOW = 8192u,
GLOBALCLASS = 16384u,
IME = 65536u,
DROPSHADOW = 131072u
}
[Flags]
internal enum CS : uint
{
VREDRAW = 1u,
HREDRAW = 2u,
DBLCLKS = 8u,
OWNDC = 32u,
CLASSDC = 64u,
PARENTDC = 128u,
NOCLOSE = 512u,
SAVEBITS = 2048u,
BYTEALIGNCLIENT = 4096u,
BYTEALIGNWINDOW = 8192u,
GLOBALCLASS = 16384u,
IME = 65536u,
DROPSHADOW = 131072u
}
}

View File

@ -2,11 +2,11 @@
namespace Standard
{
internal enum CombineRgnResult
{
ERROR,
NULLREGION,
SIMPLEREGION,
COMPLEXREGION
}
internal enum CombineRgnResult
{
ERROR,
NULLREGION,
SIMPLEREGION,
COMPLEXREGION
}
}

View File

@ -2,12 +2,12 @@
namespace Standard
{
internal enum DOGIF
{
DEFAULT,
TRAVERSE_LINK,
NO_HDROP,
NO_URL = 4,
ONLY_IF_ONE = 8
}
internal enum DOGIF
{
DEFAULT,
TRAVERSE_LINK,
NO_HDROP,
NO_URL = 4,
ONLY_IF_ONE = 8
}
}

View File

@ -2,10 +2,10 @@
namespace Standard
{
internal enum DWMFLIP3D
{
DEFAULT,
EXCLUDEBELOW,
EXCLUDEABOVE
}
internal enum DWMFLIP3D
{
DEFAULT,
EXCLUDEBELOW,
EXCLUDEABOVE
}
}

View File

@ -2,10 +2,10 @@
namespace Standard
{
internal enum DWMNCRP
{
USEWINDOWSTYLE,
DISABLED,
ENABLED
}
internal enum DWMNCRP
{
USEWINDOWSTYLE,
DISABLED,
ENABLED
}
}

View File

@ -2,19 +2,19 @@
namespace Standard
{
internal enum DWMWA
{
NCRENDERING_ENABLED = 1,
NCRENDERING_POLICY,
TRANSITIONS_FORCEDISABLED,
ALLOW_NCPAINT,
CAPTION_BUTTON_BOUNDS,
NONCLIENT_RTL_LAYOUT,
FORCE_ICONIC_REPRESENTATION,
FLIP3D_POLICY,
EXTENDED_FRAME_BOUNDS,
HAS_ICONIC_BITMAP,
DISALLOW_PEEK,
EXCLUDED_FROM_PEEK
}
internal enum DWMWA
{
NCRENDERING_ENABLED = 1,
NCRENDERING_POLICY,
TRANSITIONS_FORCEDISABLED,
ALLOW_NCPAINT,
CAPTION_BUTTON_BOUNDS,
NONCLIENT_RTL_LAYOUT,
FORCE_ICONIC_REPRESENTATION,
FLIP3D_POLICY,
EXTENDED_FRAME_BOUNDS,
HAS_ICONIC_BITMAP,
DISALLOW_PEEK,
EXCLUDED_FROM_PEEK
}
}

View File

@ -2,9 +2,9 @@
namespace Standard
{
internal enum DWM_SIT
{
None,
DISPLAYFRAME
}
internal enum DWM_SIT
{
None,
DISPLAYFRAME
}
}

View File

@ -3,87 +3,87 @@ using System.Runtime.InteropServices;
namespace Standard
{
[StructLayout(LayoutKind.Sequential, Pack = 1)]
internal struct DWM_TIMING_INFO
{
public int cbSize;
[StructLayout(LayoutKind.Sequential, Pack = 1)]
internal struct DWM_TIMING_INFO
{
public int cbSize;
public UNSIGNED_RATIO rateRefresh;
public UNSIGNED_RATIO rateRefresh;
public ulong qpcRefreshPeriod;
public ulong qpcRefreshPeriod;
public UNSIGNED_RATIO rateCompose;
public UNSIGNED_RATIO rateCompose;
public ulong qpcVBlank;
public ulong qpcVBlank;
public ulong cRefresh;
public ulong cRefresh;
public uint cDXRefresh;
public uint cDXRefresh;
public ulong qpcCompose;
public ulong qpcCompose;
public ulong cFrame;
public ulong cFrame;
public uint cDXPresent;
public uint cDXPresent;
public ulong cRefreshFrame;
public ulong cRefreshFrame;
public ulong cFrameSubmitted;
public ulong cFrameSubmitted;
public uint cDXPresentSubmitted;
public uint cDXPresentSubmitted;
public ulong cFrameConfirmed;
public ulong cFrameConfirmed;
public uint cDXPresentConfirmed;
public uint cDXPresentConfirmed;
public ulong cRefreshConfirmed;
public ulong cRefreshConfirmed;
public uint cDXRefreshConfirmed;
public uint cDXRefreshConfirmed;
public ulong cFramesLate;
public ulong cFramesLate;
public uint cFramesOutstanding;
public uint cFramesOutstanding;
public ulong cFrameDisplayed;
public ulong cFrameDisplayed;
public ulong qpcFrameDisplayed;
public ulong qpcFrameDisplayed;
public ulong cRefreshFrameDisplayed;
public ulong cRefreshFrameDisplayed;
public ulong cFrameComplete;
public ulong cFrameComplete;
public ulong qpcFrameComplete;
public ulong qpcFrameComplete;
public ulong cFramePending;
public ulong cFramePending;
public ulong qpcFramePending;
public ulong qpcFramePending;
public ulong cFramesDisplayed;
public ulong cFramesDisplayed;
public ulong cFramesComplete;
public ulong cFramesComplete;
public ulong cFramesPending;
public ulong cFramesPending;
public ulong cFramesAvailable;
public ulong cFramesAvailable;
public ulong cFramesDropped;
public ulong cFramesDropped;
public ulong cFramesMissed;
public ulong cFramesMissed;
public ulong cRefreshNextDisplayed;
public ulong cRefreshNextDisplayed;
public ulong cRefreshNextPresented;
public ulong cRefreshNextPresented;
public ulong cRefreshesDisplayed;
public ulong cRefreshesDisplayed;
public ulong cRefreshesPresented;
public ulong cRefreshesPresented;
public ulong cRefreshStarted;
public ulong cRefreshStarted;
public ulong cPixelsReceived;
public ulong cPixelsReceived;
public ulong cPixelsDrawn;
public ulong cPixelsDrawn;
public ulong cBuffersEmpty;
}
public ulong cBuffersEmpty;
}
}

View File

@ -2,11 +2,11 @@
namespace Standard
{
internal enum DeviceCap
{
BITSPIXEL = 12,
PLANES = 14,
LOGPIXELSX = 88,
LOGPIXELSY = 90
}
internal enum DeviceCap
{
BITSPIXEL = 12,
PLANES = 14,
LOGPIXELSX = 88,
LOGPIXELSY = 90
}
}

View File

@ -3,55 +3,55 @@ using System.Diagnostics.CodeAnalysis;
namespace Standard
{
internal static class DoubleUtilities
{
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool AreClose(double value1, double value2)
{
if (value1 == value2)
{
return true;
}
double num = value1 - value2;
return num < 1.53E-06 && num > -1.53E-06;
}
internal static class DoubleUtilities
{
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool AreClose(double value1, double value2)
{
if (value1 == value2)
{
return true;
}
double num = value1 - value2;
return num < 1.53E-06 && num > -1.53E-06;
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool LessThan(double value1, double value2)
{
return value1 < value2 && !DoubleUtilities.AreClose(value1, value2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool LessThan(double value1, double value2)
{
return value1 < value2 && !DoubleUtilities.AreClose(value1, value2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool GreaterThan(double value1, double value2)
{
return value1 > value2 && !DoubleUtilities.AreClose(value1, value2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool GreaterThan(double value1, double value2)
{
return value1 > value2 && !DoubleUtilities.AreClose(value1, value2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool LessThanOrClose(double value1, double value2)
{
return value1 < value2 || DoubleUtilities.AreClose(value1, value2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool LessThanOrClose(double value1, double value2)
{
return value1 < value2 || DoubleUtilities.AreClose(value1, value2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool GreaterThanOrClose(double value1, double value2)
{
return value1 > value2 || DoubleUtilities.AreClose(value1, value2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool GreaterThanOrClose(double value1, double value2)
{
return value1 > value2 || DoubleUtilities.AreClose(value1, value2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool IsFinite(double value)
{
return !double.IsNaN(value) && !double.IsInfinity(value);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool IsFinite(double value)
{
return !double.IsNaN(value) && !double.IsInfinity(value);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool IsValidSize(double value)
{
return DoubleUtilities.IsFinite(value) && DoubleUtilities.GreaterThanOrClose(value, 0.0);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static bool IsValidSize(double value)
{
return DoubleUtilities.IsFinite(value) && DoubleUtilities.GreaterThanOrClose(value, 0.0);
}
private const double Epsilon = 1.53E-06;
}
private const double Epsilon = 1.53E-06;
}
}

View File

@ -5,66 +5,66 @@ using System.Windows.Media;
namespace Standard
{
internal static class DpiHelper
{
[SuppressMessage("Microsoft.Performance", "CA1810:InitializeReferenceTypeStaticFieldsInline")]
static DpiHelper()
{
using (SafeDC desktop = SafeDC.GetDesktop())
{
int deviceCaps = NativeMethods.GetDeviceCaps(desktop, DeviceCap.LOGPIXELSX);
int deviceCaps2 = NativeMethods.GetDeviceCaps(desktop, DeviceCap.LOGPIXELSY);
DpiHelper._transformToDip = Matrix.Identity;
DpiHelper._transformToDip.Scale(96.0 / (double)deviceCaps, 96.0 / (double)deviceCaps2);
DpiHelper._transformToDevice = Matrix.Identity;
DpiHelper._transformToDevice.Scale((double)deviceCaps / 96.0, (double)deviceCaps2 / 96.0);
}
}
internal static class DpiHelper
{
[SuppressMessage("Microsoft.Performance", "CA1810:InitializeReferenceTypeStaticFieldsInline")]
static DpiHelper()
{
using (SafeDC desktop = SafeDC.GetDesktop())
{
int deviceCaps = NativeMethods.GetDeviceCaps(desktop, DeviceCap.LOGPIXELSX);
int deviceCaps2 = NativeMethods.GetDeviceCaps(desktop, DeviceCap.LOGPIXELSY);
DpiHelper._transformToDip = Matrix.Identity;
DpiHelper._transformToDip.Scale(96.0 / (double) deviceCaps, 96.0 / (double) deviceCaps2);
DpiHelper._transformToDevice = Matrix.Identity;
DpiHelper._transformToDevice.Scale((double) deviceCaps / 96.0, (double) deviceCaps2 / 96.0);
}
}
public static Point LogicalPixelsToDevice(Point logicalPoint)
{
return DpiHelper._transformToDevice.Transform(logicalPoint);
}
public static Point LogicalPixelsToDevice(Point logicalPoint)
{
return DpiHelper._transformToDevice.Transform(logicalPoint);
}
public static Point DevicePixelsToLogical(Point devicePoint)
{
return DpiHelper._transformToDip.Transform(devicePoint);
}
public static Point DevicePixelsToLogical(Point devicePoint)
{
return DpiHelper._transformToDip.Transform(devicePoint);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static Rect LogicalRectToDevice(Rect logicalRectangle)
{
Point point = DpiHelper.LogicalPixelsToDevice(new Point(logicalRectangle.Left, logicalRectangle.Top));
Point point2 = DpiHelper.LogicalPixelsToDevice(new Point(logicalRectangle.Right, logicalRectangle.Bottom));
return new Rect(point, point2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static Rect LogicalRectToDevice(Rect logicalRectangle)
{
Point point = DpiHelper.LogicalPixelsToDevice(new Point(logicalRectangle.Left, logicalRectangle.Top));
Point point2 = DpiHelper.LogicalPixelsToDevice(new Point(logicalRectangle.Right, logicalRectangle.Bottom));
return new Rect(point, point2);
}
public static Rect DeviceRectToLogical(Rect deviceRectangle)
{
Point point = DpiHelper.DevicePixelsToLogical(new Point(deviceRectangle.Left, deviceRectangle.Top));
Point point2 = DpiHelper.DevicePixelsToLogical(new Point(deviceRectangle.Right, deviceRectangle.Bottom));
return new Rect(point, point2);
}
public static Rect DeviceRectToLogical(Rect deviceRectangle)
{
Point point = DpiHelper.DevicePixelsToLogical(new Point(deviceRectangle.Left, deviceRectangle.Top));
Point point2 = DpiHelper.DevicePixelsToLogical(new Point(deviceRectangle.Right, deviceRectangle.Bottom));
return new Rect(point, point2);
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static Size LogicalSizeToDevice(Size logicalSize)
{
Point point = DpiHelper.LogicalPixelsToDevice(new Point(logicalSize.Width, logicalSize.Height));
return new Size
{
Width = point.X,
Height = point.Y
};
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public static Size LogicalSizeToDevice(Size logicalSize)
{
Point point = DpiHelper.LogicalPixelsToDevice(new Point(logicalSize.Width, logicalSize.Height));
return new Size
{
Width = point.X,
Height = point.Y
};
}
public static Size DeviceSizeToLogical(Size deviceSize)
{
Point point = DpiHelper.DevicePixelsToLogical(new Point(deviceSize.Width, deviceSize.Height));
return new Size(point.X, point.Y);
}
public static Size DeviceSizeToLogical(Size deviceSize)
{
Point point = DpiHelper.DevicePixelsToLogical(new Point(deviceSize.Width, deviceSize.Height));
return new Size(point.X, point.Y);
}
private static Matrix _transformToDevice;
private static Matrix _transformToDevice;
private static Matrix _transformToDip;
}
private static Matrix _transformToDip;
}
}

View File

@ -2,13 +2,13 @@
namespace Standard
{
[Flags]
internal enum ErrorModes
{
Default = 0,
FailCriticalErrors = 1,
NoGpFaultErrorBox = 2,
NoAlignmentFaultExcept = 4,
NoOpenFileErrorBox = 32768
}
[Flags]
internal enum ErrorModes
{
Default = 0,
FailCriticalErrors = 1,
NoGpFaultErrorBox = 2,
NoAlignmentFaultExcept = 4,
NoOpenFileErrorBox = 32768
}
}

View File

@ -2,11 +2,11 @@
namespace Standard
{
internal enum FO
{
MOVE = 1,
COPY,
DELETE,
RENAME
}
internal enum FO
{
MOVE = 1,
COPY,
DELETE,
RENAME
}
}

View File

@ -2,23 +2,23 @@
namespace Standard
{
internal enum FOF : ushort
{
MULTIDESTFILES = 1,
CONFIRMMOUSE,
SILENT = 4,
RENAMEONCOLLISION = 8,
NOCONFIRMATION = 16,
WANTMAPPINGHANDLE = 32,
ALLOWUNDO = 64,
FILESONLY = 128,
SIMPLEPROGRESS = 256,
NOCONFIRMMKDIR = 512,
NOERRORUI = 1024,
NOCOPYSECURITYATTRIBS = 2048,
NORECURSION = 4096,
NO_CONNECTED_ELEMENTS = 8192,
WANTNUKEWARNING = 16384,
NORECURSEREPARSE = 32768
}
internal enum FOF : ushort
{
MULTIDESTFILES = 1,
CONFIRMMOUSE,
SILENT = 4,
RENAMEONCOLLISION = 8,
NOCONFIRMATION = 16,
WANTMAPPINGHANDLE = 32,
ALLOWUNDO = 64,
FILESONLY = 128,
SIMPLEPROGRESS = 256,
NOCONFIRMMKDIR = 512,
NOERRORUI = 1024,
NOCOPYSECURITYATTRIBS = 2048,
NORECURSION = 4096,
NO_CONNECTED_ELEMENTS = 8192,
WANTNUKEWARNING = 16384,
NORECURSEREPARSE = 32768
}
}

View File

@ -2,18 +2,18 @@
namespace Standard
{
[Flags]
[Flags]
internal enum Facility
{
Null,
Rpc,
Dispatch,
Storage,
Itf,
Win32 = 7,
Windows,
Control = 10,
Ese = 3678,
WinCodec = 2200
}
{
Null,
Rpc,
Dispatch,
Storage,
Itf,
Win32 = 7,
Windows,
Control = 10,
Ese = 3678,
WinCodec = 2200
}
}

View File

@ -2,8 +2,8 @@
namespace Standard
{
internal enum GCLP
{
HBRBACKGROUND = -10
}
internal enum GCLP
{
HBRBACKGROUND = -10
}
}

View File

@ -2,17 +2,17 @@
namespace Standard
{
internal enum GPS
{
DEFAULT,
HANDLERPROPERTIESONLY,
READWRITE,
TEMPORARY = 4,
FASTPROPERTIESONLY = 8,
OPENSLOWITEM = 16,
DELAYCREATION = 32,
BESTEFFORT = 64,
NO_OPLOCK = 128,
MASK_VALID = 255
}
internal enum GPS
{
DEFAULT,
HANDLERPROPERTIESONLY,
READWRITE,
TEMPORARY = 4,
FASTPROPERTIESONLY = 8,
OPENSLOWITEM = 16,
DELAYCREATION = 32,
BESTEFFORT = 64,
NO_OPLOCK = 128,
MASK_VALID = 255
}
}

View File

@ -2,14 +2,14 @@
namespace Standard
{
internal enum GWL
{
WNDPROC = -4,
HINSTANCE = -6,
HWNDPARENT = -8,
STYLE = -16,
EXSTYLE = -20,
USERDATA = -21,
ID = -12
}
internal enum GWL
{
WNDPROC = -4,
HINSTANCE = -6,
HWNDPARENT = -8,
STYLE = -16,
EXSTYLE = -20,
USERDATA = -21,
ID = -12
}
}

View File

@ -2,15 +2,15 @@
namespace Standard
{
[Flags]
internal enum HCF
{
HIGHCONTRASTON = 1,
AVAILABLE = 2,
HOTKEYACTIVE = 4,
CONFIRMHOTKEY = 8,
HOTKEYSOUND = 16,
INDICATOR = 32,
HOTKEYAVAILABLE = 64
}
[Flags]
internal enum HCF
{
HIGHCONTRASTON = 1,
AVAILABLE = 2,
HOTKEYACTIVE = 4,
CONFIRMHOTKEY = 8,
HOTKEYSOUND = 16,
INDICATOR = 32,
HOTKEYAVAILABLE = 64
}
}

View File

@ -2,12 +2,12 @@
namespace Standard
{
internal struct HIGHCONTRAST
{
public int cbSize;
internal struct HIGHCONTRAST
{
public int cbSize;
public HCF dwFlags;
public HCF dwFlags;
public IntPtr lpszDefaultScheme;
}
public IntPtr lpszDefaultScheme;
}
}

View File

@ -7,238 +7,238 @@ using System.Runtime.InteropServices;
namespace Standard
{
[StructLayout(LayoutKind.Explicit)]
internal struct HRESULT
{
public HRESULT(uint i)
{
this._value = i;
}
[StructLayout(LayoutKind.Explicit)]
internal struct HRESULT
{
public HRESULT(uint i)
{
this._value = i;
}
public static HRESULT Make(bool severe, Facility facility, int code)
{
return new HRESULT((uint)((severe ? (Facility)(-2147483648) : Facility.Null) | (Facility) ((int)facility << 16) | (Facility)code));
}
public static HRESULT Make(bool severe, Facility facility, int code)
{
return new HRESULT((uint) ((severe ? (Facility) (-2147483648) : Facility.Null) | (Facility) ((int) facility << 16) | (Facility) code));
}
public Facility Facility
{
get
{
return HRESULT.GetFacility((int)this._value);
}
}
public Facility Facility
{
get
{
return HRESULT.GetFacility((int) this._value);
}
}
public static Facility GetFacility(int errorCode)
{
return (Facility)(errorCode >> 16 & 8191);
}
public static Facility GetFacility(int errorCode)
{
return (Facility) (errorCode >> 16 & 8191);
}
public int Code
{
get
{
return HRESULT.GetCode((int)this._value);
}
}
public int Code
{
get
{
return HRESULT.GetCode((int) this._value);
}
}
public static int GetCode(int error)
{
return error & 65535;
}
public static int GetCode(int error)
{
return error & 65535;
}
public override string ToString()
{
foreach (FieldInfo fieldInfo in typeof(HRESULT).GetFields(BindingFlags.Static | BindingFlags.Public))
{
if (fieldInfo.FieldType == typeof(HRESULT))
{
HRESULT hrLeft = (HRESULT)fieldInfo.GetValue(null);
if (hrLeft == this)
{
return fieldInfo.Name;
}
}
}
if (this.Facility == Facility.Win32)
{
foreach (FieldInfo fieldInfo2 in typeof(Win32Error).GetFields(BindingFlags.Static | BindingFlags.Public))
{
if (fieldInfo2.FieldType == typeof(Win32Error))
{
Win32Error error = (Win32Error)fieldInfo2.GetValue(null);
if ((HRESULT)error == this)
{
return "HRESULT_FROM_WIN32(" + fieldInfo2.Name + ")";
}
}
}
}
return string.Format(CultureInfo.InvariantCulture, "0x{0:X8}", new object[]
{
this._value
});
}
public override string ToString()
{
foreach (FieldInfo fieldInfo in typeof(HRESULT).GetFields(BindingFlags.Static | BindingFlags.Public))
{
if (fieldInfo.FieldType == typeof(HRESULT))
{
HRESULT hrLeft = (HRESULT) fieldInfo.GetValue(null);
if (hrLeft == this)
{
return fieldInfo.Name;
}
}
}
if (this.Facility == Facility.Win32)
{
foreach (FieldInfo fieldInfo2 in typeof(Win32Error).GetFields(BindingFlags.Static | BindingFlags.Public))
{
if (fieldInfo2.FieldType == typeof(Win32Error))
{
Win32Error error = (Win32Error) fieldInfo2.GetValue(null);
if ((HRESULT) error == this)
{
return "HRESULT_FROM_WIN32(" + fieldInfo2.Name + ")";
}
}
}
}
return string.Format(CultureInfo.InvariantCulture, "0x{0:X8}", new object[]
{
this._value
});
}
public override bool Equals(object obj)
{
bool result;
try
{
result = (((HRESULT)obj)._value == this._value);
}
catch (InvalidCastException)
{
result = false;
}
return result;
}
public override bool Equals(object obj)
{
bool result;
try
{
result = (((HRESULT) obj)._value == this._value);
}
catch (InvalidCastException)
{
result = false;
}
return result;
}
public override int GetHashCode()
{
return this._value.GetHashCode();
}
public override int GetHashCode()
{
return this._value.GetHashCode();
}
public static bool operator ==(HRESULT hrLeft, HRESULT hrRight)
{
return hrLeft._value == hrRight._value;
}
public static bool operator ==(HRESULT hrLeft, HRESULT hrRight)
{
return hrLeft._value == hrRight._value;
}
public static bool operator !=(HRESULT hrLeft, HRESULT hrRight)
{
return !(hrLeft == hrRight);
}
public static bool operator !=(HRESULT hrLeft, HRESULT hrRight)
{
return !(hrLeft == hrRight);
}
public bool Succeeded
{
get
{
return this._value >= 0u;
}
}
public bool Succeeded
{
get
{
return this._value >= 0u;
}
}
public bool Failed
{
get
{
return this._value < 0u;
}
}
public bool Failed
{
get
{
return this._value < 0u;
}
}
public void ThrowIfFailed()
{
this.ThrowIfFailed(null);
}
public void ThrowIfFailed()
{
this.ThrowIfFailed(null);
}
[SuppressMessage("Microsoft.Usage", "CA2201:DoNotRaiseReservedExceptionTypes", Justification = "Only recreating Exceptions that were already raised.")]
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void ThrowIfFailed(string message)
{
if (this.Failed)
{
if (string.IsNullOrEmpty(message))
{
message = this.ToString();
}
Exception ex = Marshal.GetExceptionForHR((int)this._value, new IntPtr(-1));
if (ex.GetType() == typeof(COMException))
{
Facility facility = this.Facility;
if (facility == Facility.Win32)
{
ex = new Win32Exception(this.Code, message);
}
else
{
ex = new COMException(message, (int)this._value);
}
}
else
{
ConstructorInfo constructor = ex.GetType().GetConstructor(new Type[]
{
typeof(string)
});
if (null != constructor)
{
ex = (constructor.Invoke(new object[]
{
message
}) as Exception);
}
}
throw ex;
}
}
[SuppressMessage("Microsoft.Usage", "CA2201:DoNotRaiseReservedExceptionTypes", Justification = "Only recreating Exceptions that were already raised.")]
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void ThrowIfFailed(string message)
{
if (this.Failed)
{
if (string.IsNullOrEmpty(message))
{
message = this.ToString();
}
Exception ex = Marshal.GetExceptionForHR((int) this._value, new IntPtr(-1));
if (ex.GetType() == typeof(COMException))
{
Facility facility = this.Facility;
if (facility == Facility.Win32)
{
ex = new Win32Exception(this.Code, message);
}
else
{
ex = new COMException(message, (int) this._value);
}
}
else
{
ConstructorInfo constructor = ex.GetType().GetConstructor(new Type[]
{
typeof(string)
});
if (null != constructor)
{
ex = (constructor.Invoke(new object[]
{
message
}) as Exception);
}
}
throw ex;
}
}
public static void ThrowLastError()
{
((HRESULT)Win32Error.GetLastError()).ThrowIfFailed();
}
public static void ThrowLastError()
{
((HRESULT) Win32Error.GetLastError()).ThrowIfFailed();
}
[FieldOffset(0)]
private readonly uint _value;
[FieldOffset(0)]
private readonly uint _value;
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT S_OK = new HRESULT(0u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT S_OK = new HRESULT(0u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT S_FALSE = new HRESULT(1u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT S_FALSE = new HRESULT(1u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_PENDING = new HRESULT(2147483658u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_PENDING = new HRESULT(2147483658u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_NOTIMPL = new HRESULT(2147500033u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_NOTIMPL = new HRESULT(2147500033u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_NOINTERFACE = new HRESULT(2147500034u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_NOINTERFACE = new HRESULT(2147500034u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_POINTER = new HRESULT(2147500035u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_POINTER = new HRESULT(2147500035u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_ABORT = new HRESULT(2147500036u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_ABORT = new HRESULT(2147500036u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_FAIL = new HRESULT(2147500037u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_FAIL = new HRESULT(2147500037u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_UNEXPECTED = new HRESULT(2147549183u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_UNEXPECTED = new HRESULT(2147549183u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT STG_E_INVALIDFUNCTION = new HRESULT(2147680257u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT STG_E_INVALIDFUNCTION = new HRESULT(2147680257u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT REGDB_E_CLASSNOTREG = new HRESULT(2147746132u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT REGDB_E_CLASSNOTREG = new HRESULT(2147746132u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT DESTS_E_NO_MATCHING_ASSOC_HANDLER = new HRESULT(2147749635u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT DESTS_E_NO_MATCHING_ASSOC_HANDLER = new HRESULT(2147749635u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT DESTS_E_NORECDOCS = new HRESULT(2147749636u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT DESTS_E_NORECDOCS = new HRESULT(2147749636u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT DESTS_E_NOTALLCLEARED = new HRESULT(2147749637u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT DESTS_E_NOTALLCLEARED = new HRESULT(2147749637u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_ACCESSDENIED = new HRESULT(2147942405u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_ACCESSDENIED = new HRESULT(2147942405u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_OUTOFMEMORY = new HRESULT(2147942414u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_OUTOFMEMORY = new HRESULT(2147942414u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_INVALIDARG = new HRESULT(2147942487u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT E_INVALIDARG = new HRESULT(2147942487u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT INTSAFE_E_ARITHMETIC_OVERFLOW = new HRESULT(2147942934u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT INTSAFE_E_ARITHMETIC_OVERFLOW = new HRESULT(2147942934u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT COR_E_OBJECTDISPOSED = new HRESULT(2148734498u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT COR_E_OBJECTDISPOSED = new HRESULT(2148734498u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT WC_E_GREATERTHAN = new HRESULT(3222072867u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT WC_E_GREATERTHAN = new HRESULT(3222072867u);
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT WC_E_SYNTAX = new HRESULT(3222072877u);
}
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
public static readonly HRESULT WC_E_SYNTAX = new HRESULT(3222072877u);
}
}

View File

@ -2,36 +2,36 @@
namespace Standard
{
internal enum HT
{
ERROR = -2,
TRANSPARENT,
NOWHERE,
CLIENT,
CAPTION,
SYSMENU,
GROWBOX,
SIZE = 4,
MENU,
HSCROLL,
VSCROLL,
MINBUTTON,
MAXBUTTON,
LEFT,
RIGHT,
TOP,
TOPLEFT,
TOPRIGHT,
BOTTOM,
BOTTOMLEFT,
BOTTOMRIGHT,
BORDER,
REDUCE = 8,
ZOOM,
SIZEFIRST,
SIZELAST = 17,
OBJECT = 19,
CLOSE,
HELP
}
internal enum HT
{
ERROR = -2,
TRANSPARENT,
NOWHERE,
CLIENT,
CAPTION,
SYSMENU,
GROWBOX,
SIZE = 4,
MENU,
HSCROLL,
VSCROLL,
MINBUTTON,
MAXBUTTON,
LEFT,
RIGHT,
TOP,
TOPLEFT,
TOPRIGHT,
BOTTOM,
BOTTOMLEFT,
BOTTOMRIGHT,
BORDER,
REDUCE = 8,
ZOOM,
SIZEFIRST,
SIZELAST = 17,
OBJECT = 19,
CLOSE,
HELP
}
}

View File

@ -3,15 +3,15 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("12337d35-94c6-48a0-bce7-6a9c69d4d600")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IApplicationDestinations
{
void SetAppID([MarshalAs(UnmanagedType.LPWStr)] [In] string pszAppID);
[Guid("12337d35-94c6-48a0-bce7-6a9c69d4d600")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IApplicationDestinations
{
void SetAppID([MarshalAs(UnmanagedType.LPWStr)][In] string pszAppID);
void RemoveDestination([MarshalAs(UnmanagedType.IUnknown)] object punk);
void RemoveDestination([MarshalAs(UnmanagedType.IUnknown)] object punk);
void RemoveAllDestinations();
}
void RemoveAllDestinations();
}
}

View File

@ -3,14 +3,14 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("3c594f9f-9f30-47a1-979a-c9e83d3d0a06")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IApplicationDocumentLists
{
void SetAppID([MarshalAs(UnmanagedType.LPWStr)] string pszAppID);
[Guid("3c594f9f-9f30-47a1-979a-c9e83d3d0a06")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IApplicationDocumentLists
{
void SetAppID([MarshalAs(UnmanagedType.LPWStr)] string pszAppID);
[return: MarshalAs(UnmanagedType.IUnknown)]
object GetList([In] APPDOCLISTTYPE listtype, [In] uint cItemsDesired, [In] ref Guid riid);
}
[return: MarshalAs(UnmanagedType.IUnknown)]
object GetList([In] APPDOCLISTTYPE listtype, [In] uint cItemsDesired, [In] ref Guid riid);
}
}

View File

@ -3,31 +3,31 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("6332debf-87b5-4670-90c0-5e57b408a49e")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface ICustomDestinationList
{
void SetAppID([MarshalAs(UnmanagedType.LPWStr)] [In] string pszAppID);
[Guid("6332debf-87b5-4670-90c0-5e57b408a49e")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface ICustomDestinationList
{
void SetAppID([MarshalAs(UnmanagedType.LPWStr)][In] string pszAppID);
[return: MarshalAs(UnmanagedType.Interface)]
object BeginList(out uint pcMaxSlots, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object BeginList(out uint pcMaxSlots, [In] ref Guid riid);
[PreserveSig]
HRESULT AppendCategory([MarshalAs(UnmanagedType.LPWStr)] string pszCategory, IObjectArray poa);
[PreserveSig]
HRESULT AppendCategory([MarshalAs(UnmanagedType.LPWStr)] string pszCategory, IObjectArray poa);
void AppendKnownCategory(KDC category);
void AppendKnownCategory(KDC category);
[PreserveSig]
HRESULT AddUserTasks(IObjectArray poa);
[PreserveSig]
HRESULT AddUserTasks(IObjectArray poa);
void CommitList();
void CommitList();
[return: MarshalAs(UnmanagedType.Interface)]
object GetRemovedDestinations([In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetRemovedDestinations([In] ref Guid riid);
void DeleteList([MarshalAs(UnmanagedType.LPWStr)] string pszAppID);
void DeleteList([MarshalAs(UnmanagedType.LPWStr)] string pszAppID);
void AbortList();
}
void AbortList();
}
}

View File

@ -3,19 +3,19 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("000214F2-0000-0000-C000-000000000046")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IEnumIDList
{
[PreserveSig]
HRESULT Next(uint celt, out IntPtr rgelt, out int pceltFetched);
[Guid("000214F2-0000-0000-C000-000000000046")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IEnumIDList
{
[PreserveSig]
HRESULT Next(uint celt, out IntPtr rgelt, out int pceltFetched);
[PreserveSig]
HRESULT Skip(uint celt);
[PreserveSig]
HRESULT Skip(uint celt);
void Reset();
void Reset();
void Clone([MarshalAs(UnmanagedType.Interface)] out IEnumIDList ppenum);
}
void Clone([MarshalAs(UnmanagedType.Interface)] out IEnumIDList ppenum);
}
}

View File

@ -3,17 +3,17 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("2c1c7e2e-2d0e-4059-831e-1e6f82335c2e")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IEnumObjects
{
void Next(uint celt, [In] ref Guid riid, [MarshalAs(UnmanagedType.LPArray, ArraySubType = UnmanagedType.IUnknown, SizeParamIndex = 0)] [Out] object[] rgelt, out uint pceltFetched);
[Guid("2c1c7e2e-2d0e-4059-831e-1e6f82335c2e")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IEnumObjects
{
void Next(uint celt, [In] ref Guid riid, [MarshalAs(UnmanagedType.LPArray, ArraySubType = UnmanagedType.IUnknown, SizeParamIndex = 0)][Out] object[] rgelt, out uint pceltFetched);
void Skip(uint celt);
void Skip(uint celt);
void Reset();
void Reset();
IEnumObjects Clone();
}
IEnumObjects Clone();
}
}

View File

@ -2,54 +2,54 @@
namespace Standard
{
internal static class IID
{
public const string EnumIdList = "000214F2-0000-0000-C000-000000000046";
internal static class IID
{
public const string EnumIdList = "000214F2-0000-0000-C000-000000000046";
public const string EnumObjects = "2c1c7e2e-2d0e-4059-831e-1e6f82335c2e";
public const string EnumObjects = "2c1c7e2e-2d0e-4059-831e-1e6f82335c2e";
public const string HtmlDocument2 = "332C4425-26CB-11D0-B483-00C04FD90119";
public const string HtmlDocument2 = "332C4425-26CB-11D0-B483-00C04FD90119";
public const string ModalWindow = "b4db1657-70d7-485e-8e3e-6fcb5a5c1802";
public const string ModalWindow = "b4db1657-70d7-485e-8e3e-6fcb5a5c1802";
public const string ObjectArray = "92CA9DCD-5622-4bba-A805-5E9F541BD8C9";
public const string ObjectArray = "92CA9DCD-5622-4bba-A805-5E9F541BD8C9";
public const string ObjectCollection = "5632b1a4-e38a-400a-928a-d4cd63230295";
public const string ObjectCollection = "5632b1a4-e38a-400a-928a-d4cd63230295";
public const string PropertyNotifySink = "9BFBBC02-EFF1-101A-84ED-00AA00341D07";
public const string PropertyNotifySink = "9BFBBC02-EFF1-101A-84ED-00AA00341D07";
public const string PropertyStore = "886d8eeb-8cf2-4446-8d02-cdba1dbdcf99";
public const string PropertyStore = "886d8eeb-8cf2-4446-8d02-cdba1dbdcf99";
public const string ServiceProvider = "6d5140c1-7436-11ce-8034-00aa006009fa";
public const string ServiceProvider = "6d5140c1-7436-11ce-8034-00aa006009fa";
public const string ShellFolder = "000214E6-0000-0000-C000-000000000046";
public const string ShellFolder = "000214E6-0000-0000-C000-000000000046";
public const string ShellLink = "000214F9-0000-0000-C000-000000000046";
public const string ShellLink = "000214F9-0000-0000-C000-000000000046";
public const string ShellItem = "43826d1e-e718-42ee-bc55-a1e261c37bfe";
public const string ShellItem = "43826d1e-e718-42ee-bc55-a1e261c37bfe";
public const string ShellItem2 = "7e9fb0d3-919f-4307-ab2e-9b1860310c93";
public const string ShellItem2 = "7e9fb0d3-919f-4307-ab2e-9b1860310c93";
public const string ShellItemArray = "B63EA76D-1F85-456F-A19C-48159EFA858B";
public const string ShellItemArray = "B63EA76D-1F85-456F-A19C-48159EFA858B";
public const string TaskbarList = "56FDF342-FD6D-11d0-958A-006097C9A090";
public const string TaskbarList = "56FDF342-FD6D-11d0-958A-006097C9A090";
public const string TaskbarList2 = "602D4995-B13A-429b-A66E-1935E44F4317";
public const string TaskbarList2 = "602D4995-B13A-429b-A66E-1935E44F4317";
public const string Unknown = "00000000-0000-0000-C000-000000000046";
public const string Unknown = "00000000-0000-0000-C000-000000000046";
public const string ApplicationDestinations = "12337d35-94c6-48a0-bce7-6a9c69d4d600";
public const string ApplicationDestinations = "12337d35-94c6-48a0-bce7-6a9c69d4d600";
public const string ApplicationDocumentLists = "3c594f9f-9f30-47a1-979a-c9e83d3d0a06";
public const string ApplicationDocumentLists = "3c594f9f-9f30-47a1-979a-c9e83d3d0a06";
public const string CustomDestinationList = "6332debf-87b5-4670-90c0-5e57b408a49e";
public const string CustomDestinationList = "6332debf-87b5-4670-90c0-5e57b408a49e";
public const string ObjectWithAppUserModelId = "36db0196-9665-46d1-9ba7-d3709eecf9ed";
public const string ObjectWithAppUserModelId = "36db0196-9665-46d1-9ba7-d3709eecf9ed";
public const string ObjectWithProgId = "71e806fb-8dee-46fc-bf8c-7748a8a1ae13";
public const string ObjectWithProgId = "71e806fb-8dee-46fc-bf8c-7748a8a1ae13";
public const string TaskbarList3 = "ea1afb91-9e28-4b86-90e9-9e9f8a5eefaf";
public const string TaskbarList3 = "ea1afb91-9e28-4b86-90e9-9e9f8a5eefaf";
public const string TaskbarList4 = "c43dc798-95d1-4bea-9030-bb99e2983a1a";
}
public const string TaskbarList4 = "c43dc798-95d1-4bea-9030-bb99e2983a1a";
}
}

View File

@ -2,10 +2,10 @@
namespace Standard
{
internal struct INPUT
{
public uint type;
internal struct INPUT
{
public uint type;
public MOUSEINPUT mi;
}
public MOUSEINPUT mi;
}
}

View File

@ -2,8 +2,8 @@
namespace Standard
{
internal enum INPUT_TYPE : uint
{
MOUSE
}
internal enum INPUT_TYPE : uint
{
MOUSE
}
}

View File

@ -3,14 +3,14 @@ using System.Runtime.InteropServices;
namespace Standard
{
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("92CA9DCD-5622-4bba-A805-5E9F541BD8C9")]
[ComImport]
internal interface IObjectArray
{
uint GetCount();
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("92CA9DCD-5622-4bba-A805-5E9F541BD8C9")]
[ComImport]
internal interface IObjectArray
{
uint GetCount();
[return: MarshalAs(UnmanagedType.IUnknown)]
object GetAt([In] uint uiIndex, [In] ref Guid riid);
}
[return: MarshalAs(UnmanagedType.IUnknown)]
object GetAt([In] uint uiIndex, [In] ref Guid riid);
}
}

View File

@ -3,22 +3,22 @@ using System.Runtime.InteropServices;
namespace Standard
{
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("92CA9DCD-5622-4bba-A805-5E9F541BD8C9")]
[ComImport]
internal interface IObjectCollection : IObjectArray
{
uint GetCount();
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("92CA9DCD-5622-4bba-A805-5E9F541BD8C9")]
[ComImport]
internal interface IObjectCollection : IObjectArray
{
uint GetCount();
[return: MarshalAs(UnmanagedType.IUnknown)]
object GetAt([In] uint uiIndex, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.IUnknown)]
object GetAt([In] uint uiIndex, [In] ref Guid riid);
void AddObject([MarshalAs(UnmanagedType.IUnknown)] object punk);
void AddObject([MarshalAs(UnmanagedType.IUnknown)] object punk);
void AddFromArray(IObjectArray poaSource);
void AddFromArray(IObjectArray poaSource);
void RemoveObjectAt(uint uiIndex);
void RemoveObjectAt(uint uiIndex);
void Clear();
}
void Clear();
}
}

View File

@ -3,14 +3,14 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("36db0196-9665-46d1-9ba7-d3709eecf9ed")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IObjectWithAppUserModelId
{
void SetAppID([MarshalAs(UnmanagedType.LPWStr)] string pszAppID);
[Guid("36db0196-9665-46d1-9ba7-d3709eecf9ed")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IObjectWithAppUserModelId
{
void SetAppID([MarshalAs(UnmanagedType.LPWStr)] string pszAppID);
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetAppID();
}
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetAppID();
}
}

View File

@ -3,14 +3,14 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("71e806fb-8dee-46fc-bf8c-7748a8a1ae13")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IObjectWithProgId
{
void SetProgID([MarshalAs(UnmanagedType.LPWStr)] string pszProgID);
[Guid("71e806fb-8dee-46fc-bf8c-7748a8a1ae13")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IObjectWithProgId
{
void SetProgID([MarshalAs(UnmanagedType.LPWStr)] string pszProgID);
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetProgID();
}
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetProgID();
}
}

View File

@ -3,19 +3,19 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("886d8eeb-8cf2-4446-8d02-cdba1dbdcf99")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IPropertyStore
{
uint GetCount();
[Guid("886d8eeb-8cf2-4446-8d02-cdba1dbdcf99")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IPropertyStore
{
uint GetCount();
PKEY GetAt(uint iProp);
PKEY GetAt(uint iProp);
void GetValue([In] ref PKEY pkey, [In] [Out] PROPVARIANT pv);
void GetValue([In] ref PKEY pkey, [In][Out] PROPVARIANT pv);
void SetValue([In] ref PKEY pkey, PROPVARIANT pv);
void SetValue([In] ref PKEY pkey, PROPVARIANT pv);
void Commit();
}
void Commit();
}
}

View File

@ -4,34 +4,34 @@ using System.Runtime.InteropServices.ComTypes;
namespace Standard
{
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("000214E6-0000-0000-C000-000000000046")]
[ComImport]
internal interface IShellFolder
{
void ParseDisplayName([In] IntPtr hwnd, [In] IBindCtx pbc, [MarshalAs(UnmanagedType.LPWStr)] [In] string pszDisplayName, [In] [Out] ref int pchEaten, out IntPtr ppidl, [In] [Out] ref uint pdwAttributes);
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("000214E6-0000-0000-C000-000000000046")]
[ComImport]
internal interface IShellFolder
{
void ParseDisplayName([In] IntPtr hwnd, [In] IBindCtx pbc, [MarshalAs(UnmanagedType.LPWStr)][In] string pszDisplayName, [In][Out] ref int pchEaten, out IntPtr ppidl, [In][Out] ref uint pdwAttributes);
IEnumIDList EnumObjects([In] IntPtr hwnd, [In] SHCONTF grfFlags);
IEnumIDList EnumObjects([In] IntPtr hwnd, [In] SHCONTF grfFlags);
[return: MarshalAs(UnmanagedType.Interface)]
object BindToObject([In] IntPtr pidl, [In] IBindCtx pbc, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object BindToObject([In] IntPtr pidl, [In] IBindCtx pbc, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object BindToStorage([In] IntPtr pidl, [In] IBindCtx pbc, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object BindToStorage([In] IntPtr pidl, [In] IBindCtx pbc, [In] ref Guid riid);
[PreserveSig]
HRESULT CompareIDs([In] IntPtr lParam, [In] IntPtr pidl1, [In] IntPtr pidl2);
[PreserveSig]
HRESULT CompareIDs([In] IntPtr lParam, [In] IntPtr pidl1, [In] IntPtr pidl2);
[return: MarshalAs(UnmanagedType.Interface)]
object CreateViewObject([In] IntPtr hwndOwner, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object CreateViewObject([In] IntPtr hwndOwner, [In] ref Guid riid);
void GetAttributesOf([In] uint cidl, [In] IntPtr apidl, [In] [Out] ref SFGAO rgfInOut);
void GetAttributesOf([In] uint cidl, [In] IntPtr apidl, [In][Out] ref SFGAO rgfInOut);
[return: MarshalAs(UnmanagedType.Interface)]
object GetUIObjectOf([In] IntPtr hwndOwner, [In] uint cidl, [MarshalAs(UnmanagedType.LPArray, ArraySubType = UnmanagedType.SysInt, SizeParamIndex = 2)] [In] IntPtr apidl, [In] ref Guid riid, [In] [Out] ref uint rgfReserved);
[return: MarshalAs(UnmanagedType.Interface)]
object GetUIObjectOf([In] IntPtr hwndOwner, [In] uint cidl, [MarshalAs(UnmanagedType.LPArray, ArraySubType = UnmanagedType.SysInt, SizeParamIndex = 2)][In] IntPtr apidl, [In] ref Guid riid, [In][Out] ref uint rgfReserved);
void GetDisplayNameOf([In] IntPtr pidl, [In] SHGDN uFlags, out IntPtr pName);
void GetDisplayNameOf([In] IntPtr pidl, [In] SHGDN uFlags, out IntPtr pName);
void SetNameOf([In] IntPtr hwnd, [In] IntPtr pidl, [MarshalAs(UnmanagedType.LPWStr)] [In] string pszName, [In] SHGDN uFlags, out IntPtr ppidlOut);
}
void SetNameOf([In] IntPtr hwnd, [In] IntPtr pidl, [MarshalAs(UnmanagedType.LPWStr)][In] string pszName, [In] SHGDN uFlags, out IntPtr ppidlOut);
}
}

View File

@ -4,21 +4,21 @@ using System.Runtime.InteropServices.ComTypes;
namespace Standard
{
[Guid("43826d1e-e718-42ee-bc55-a1e261c37bfe")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IShellItem
{
[return: MarshalAs(UnmanagedType.Interface)]
object BindToHandler(IBindCtx pbc, [In] ref Guid bhid, [In] ref Guid riid);
[Guid("43826d1e-e718-42ee-bc55-a1e261c37bfe")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IShellItem
{
[return: MarshalAs(UnmanagedType.Interface)]
object BindToHandler(IBindCtx pbc, [In] ref Guid bhid, [In] ref Guid riid);
IShellItem GetParent();
IShellItem GetParent();
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetDisplayName(SIGDN sigdnName);
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetDisplayName(SIGDN sigdnName);
SFGAO GetAttributes(SFGAO sfgaoMask);
SFGAO GetAttributes(SFGAO sfgaoMask);
int Compare(IShellItem psi, SICHINT hint);
}
int Compare(IShellItem psi, SICHINT hint);
}
}

View File

@ -4,53 +4,53 @@ using System.Runtime.InteropServices.ComTypes;
namespace Standard
{
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("7e9fb0d3-919f-4307-ab2e-9b1860310c93")]
[ComImport]
internal interface IShellItem2 : IShellItem
{
[return: MarshalAs(UnmanagedType.Interface)]
object BindToHandler([In] IBindCtx pbc, [In] ref Guid bhid, [In] ref Guid riid);
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("7e9fb0d3-919f-4307-ab2e-9b1860310c93")]
[ComImport]
internal interface IShellItem2 : IShellItem
{
[return: MarshalAs(UnmanagedType.Interface)]
object BindToHandler([In] IBindCtx pbc, [In] ref Guid bhid, [In] ref Guid riid);
IShellItem GetParent();
IShellItem GetParent();
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetDisplayName(SIGDN sigdnName);
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetDisplayName(SIGDN sigdnName);
SFGAO GetAttributes(SFGAO sfgaoMask);
SFGAO GetAttributes(SFGAO sfgaoMask);
int Compare(IShellItem psi, SICHINT hint);
int Compare(IShellItem psi, SICHINT hint);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyStore(GPS flags, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyStore(GPS flags, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyStoreWithCreateObject(GPS flags, [MarshalAs(UnmanagedType.IUnknown)] object punkCreateObject, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyStoreWithCreateObject(GPS flags, [MarshalAs(UnmanagedType.IUnknown)] object punkCreateObject, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyStoreForKeys(IntPtr rgKeys, uint cKeys, GPS flags, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyStoreForKeys(IntPtr rgKeys, uint cKeys, GPS flags, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyDescriptionList(IntPtr keyType, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyDescriptionList(IntPtr keyType, [In] ref Guid riid);
void Update(IBindCtx pbc);
void Update(IBindCtx pbc);
PROPVARIANT GetProperty(IntPtr key);
PROPVARIANT GetProperty(IntPtr key);
Guid GetCLSID(IntPtr key);
Guid GetCLSID(IntPtr key);
System.Runtime.InteropServices.ComTypes.FILETIME GetFileTime(IntPtr key);
System.Runtime.InteropServices.ComTypes.FILETIME GetFileTime(IntPtr key);
int GetInt32(IntPtr key);
int GetInt32(IntPtr key);
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetString(IntPtr key);
[return: MarshalAs(UnmanagedType.LPWStr)]
string GetString(IntPtr key);
uint GetUInt32(IntPtr key);
uint GetUInt32(IntPtr key);
ulong GetUInt64(IntPtr key);
ulong GetUInt64(IntPtr key);
[return: MarshalAs(UnmanagedType.Bool)]
void GetBool(IntPtr key);
}
[return: MarshalAs(UnmanagedType.Bool)]
void GetBool(IntPtr key);
}
}

View File

@ -4,27 +4,27 @@ using System.Runtime.InteropServices.ComTypes;
namespace Standard
{
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("B63EA76D-1F85-456F-A19C-48159EFA858B")]
[ComImport]
internal interface IShellItemArray
{
[return: MarshalAs(UnmanagedType.Interface)]
object BindToHandler(IBindCtx pbc, [In] ref Guid rbhid, [In] ref Guid riid);
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("B63EA76D-1F85-456F-A19C-48159EFA858B")]
[ComImport]
internal interface IShellItemArray
{
[return: MarshalAs(UnmanagedType.Interface)]
object BindToHandler(IBindCtx pbc, [In] ref Guid rbhid, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyStore(int flags, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyStore(int flags, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyDescriptionList([In] ref PKEY keyType, [In] ref Guid riid);
[return: MarshalAs(UnmanagedType.Interface)]
object GetPropertyDescriptionList([In] ref PKEY keyType, [In] ref Guid riid);
uint GetAttributes(SIATTRIBFLAGS dwAttribFlags, uint sfgaoMask);
uint GetAttributes(SIATTRIBFLAGS dwAttribFlags, uint sfgaoMask);
uint GetCount();
uint GetCount();
IShellItem GetItemAt(uint dwIndex);
IShellItem GetItemAt(uint dwIndex);
[return: MarshalAs(UnmanagedType.Interface)]
object EnumItems();
}
[return: MarshalAs(UnmanagedType.Interface)]
object EnumItems();
}
}

View File

@ -4,45 +4,45 @@ using System.Text;
namespace Standard
{
[Guid("000214F9-0000-0000-C000-000000000046")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IShellLinkW
{
void GetPath([MarshalAs(UnmanagedType.LPWStr)] [Out] StringBuilder pszFile, int cchMaxPath, [In] [Out] WIN32_FIND_DATAW pfd, SLGP fFlags);
[Guid("000214F9-0000-0000-C000-000000000046")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface IShellLinkW
{
void GetPath([MarshalAs(UnmanagedType.LPWStr)][Out] StringBuilder pszFile, int cchMaxPath, [In][Out] WIN32_FIND_DATAW pfd, SLGP fFlags);
void GetIDList(out IntPtr ppidl);
void GetIDList(out IntPtr ppidl);
void SetIDList(IntPtr pidl);
void SetIDList(IntPtr pidl);
void GetDescription([MarshalAs(UnmanagedType.LPWStr)] [Out] StringBuilder pszFile, int cchMaxName);
void GetDescription([MarshalAs(UnmanagedType.LPWStr)][Out] StringBuilder pszFile, int cchMaxName);
void SetDescription([MarshalAs(UnmanagedType.LPWStr)] string pszName);
void SetDescription([MarshalAs(UnmanagedType.LPWStr)] string pszName);
void GetWorkingDirectory([MarshalAs(UnmanagedType.LPWStr)] [Out] StringBuilder pszDir, int cchMaxPath);
void GetWorkingDirectory([MarshalAs(UnmanagedType.LPWStr)][Out] StringBuilder pszDir, int cchMaxPath);
void SetWorkingDirectory([MarshalAs(UnmanagedType.LPWStr)] string pszDir);
void SetWorkingDirectory([MarshalAs(UnmanagedType.LPWStr)] string pszDir);
void GetArguments([MarshalAs(UnmanagedType.LPWStr)] [Out] StringBuilder pszArgs, int cchMaxPath);
void GetArguments([MarshalAs(UnmanagedType.LPWStr)][Out] StringBuilder pszArgs, int cchMaxPath);
void SetArguments([MarshalAs(UnmanagedType.LPWStr)] string pszArgs);
void SetArguments([MarshalAs(UnmanagedType.LPWStr)] string pszArgs);
short GetHotKey();
short GetHotKey();
void SetHotKey(short wHotKey);
void SetHotKey(short wHotKey);
uint GetShowCmd();
uint GetShowCmd();
void SetShowCmd(uint iShowCmd);
void SetShowCmd(uint iShowCmd);
void GetIconLocation([MarshalAs(UnmanagedType.LPWStr)] [Out] StringBuilder pszIconPath, int cchIconPath, out int piIcon);
void GetIconLocation([MarshalAs(UnmanagedType.LPWStr)][Out] StringBuilder pszIconPath, int cchIconPath, out int piIcon);
void SetIconLocation([MarshalAs(UnmanagedType.LPWStr)] string pszIconPath, int iIcon);
void SetIconLocation([MarshalAs(UnmanagedType.LPWStr)] string pszIconPath, int iIcon);
void SetRelativePath([MarshalAs(UnmanagedType.LPWStr)] string pszPathRel, uint dwReserved);
void SetRelativePath([MarshalAs(UnmanagedType.LPWStr)] string pszPathRel, uint dwReserved);
void Resolve(IntPtr hwnd, uint fFlags);
void Resolve(IntPtr hwnd, uint fFlags);
void SetPath([MarshalAs(UnmanagedType.LPWStr)] string pszFile);
}
void SetPath([MarshalAs(UnmanagedType.LPWStr)] string pszFile);
}
}

View File

@ -3,19 +3,19 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("56FDF342-FD6D-11d0-958A-006097C9A090")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface ITaskbarList
{
void HrInit();
[Guid("56FDF342-FD6D-11d0-958A-006097C9A090")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface ITaskbarList
{
void HrInit();
void AddTab(IntPtr hwnd);
void AddTab(IntPtr hwnd);
void DeleteTab(IntPtr hwnd);
void DeleteTab(IntPtr hwnd);
void ActivateTab(IntPtr hwnd);
void ActivateTab(IntPtr hwnd);
void SetActiveAlt(IntPtr hwnd);
}
void SetActiveAlt(IntPtr hwnd);
}
}

View File

@ -3,21 +3,21 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("602D4995-B13A-429b-A66E-1935E44F4317")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface ITaskbarList2 : ITaskbarList
{
void HrInit();
[Guid("602D4995-B13A-429b-A66E-1935E44F4317")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface ITaskbarList2 : ITaskbarList
{
void HrInit();
void AddTab(IntPtr hwnd);
void AddTab(IntPtr hwnd);
void DeleteTab(IntPtr hwnd);
void DeleteTab(IntPtr hwnd);
void ActivateTab(IntPtr hwnd);
void ActivateTab(IntPtr hwnd);
void SetActiveAlt(IntPtr hwnd);
void SetActiveAlt(IntPtr hwnd);
void MarkFullscreenWindow(IntPtr hwnd, [MarshalAs(UnmanagedType.Bool)] bool fFullscreen);
}
void MarkFullscreenWindow(IntPtr hwnd, [MarshalAs(UnmanagedType.Bool)] bool fFullscreen);
}
}

View File

@ -3,57 +3,57 @@ using System.Runtime.InteropServices;
namespace Standard
{
[Guid("ea1afb91-9e28-4b86-90e9-9e9f8a5eefaf")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface ITaskbarList3 : ITaskbarList2, ITaskbarList
{
void HrInit();
[Guid("ea1afb91-9e28-4b86-90e9-9e9f8a5eefaf")]
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[ComImport]
internal interface ITaskbarList3 : ITaskbarList2, ITaskbarList
{
void HrInit();
void AddTab(IntPtr hwnd);
void AddTab(IntPtr hwnd);
void DeleteTab(IntPtr hwnd);
void DeleteTab(IntPtr hwnd);
void ActivateTab(IntPtr hwnd);
void ActivateTab(IntPtr hwnd);
void SetActiveAlt(IntPtr hwnd);
void SetActiveAlt(IntPtr hwnd);
void MarkFullscreenWindow(IntPtr hwnd, [MarshalAs(UnmanagedType.Bool)] bool fFullscreen);
void MarkFullscreenWindow(IntPtr hwnd, [MarshalAs(UnmanagedType.Bool)] bool fFullscreen);
[PreserveSig]
HRESULT SetProgressValue(IntPtr hwnd, ulong ullCompleted, ulong ullTotal);
[PreserveSig]
HRESULT SetProgressValue(IntPtr hwnd, ulong ullCompleted, ulong ullTotal);
[PreserveSig]
HRESULT SetProgressState(IntPtr hwnd, TBPF tbpFlags);
[PreserveSig]
HRESULT SetProgressState(IntPtr hwnd, TBPF tbpFlags);
[PreserveSig]
HRESULT RegisterTab(IntPtr hwndTab, IntPtr hwndMDI);
[PreserveSig]
HRESULT RegisterTab(IntPtr hwndTab, IntPtr hwndMDI);
[PreserveSig]
HRESULT UnregisterTab(IntPtr hwndTab);
[PreserveSig]
HRESULT UnregisterTab(IntPtr hwndTab);
[PreserveSig]
HRESULT SetTabOrder(IntPtr hwndTab, IntPtr hwndInsertBefore);
[PreserveSig]
HRESULT SetTabOrder(IntPtr hwndTab, IntPtr hwndInsertBefore);
[PreserveSig]
HRESULT SetTabActive(IntPtr hwndTab, IntPtr hwndMDI, uint dwReserved);
[PreserveSig]
HRESULT SetTabActive(IntPtr hwndTab, IntPtr hwndMDI, uint dwReserved);
[PreserveSig]
HRESULT ThumbBarAddButtons(IntPtr hwnd, uint cButtons, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 1)] THUMBBUTTON[] pButtons);
[PreserveSig]
HRESULT ThumbBarAddButtons(IntPtr hwnd, uint cButtons, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 1)] THUMBBUTTON[] pButtons);
[PreserveSig]
HRESULT ThumbBarUpdateButtons(IntPtr hwnd, uint cButtons, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 1)] THUMBBUTTON[] pButtons);
[PreserveSig]
HRESULT ThumbBarUpdateButtons(IntPtr hwnd, uint cButtons, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 1)] THUMBBUTTON[] pButtons);
[PreserveSig]
HRESULT ThumbBarSetImageList(IntPtr hwnd, [MarshalAs(UnmanagedType.IUnknown)] object himl);
[PreserveSig]
HRESULT ThumbBarSetImageList(IntPtr hwnd, [MarshalAs(UnmanagedType.IUnknown)] object himl);
[PreserveSig]
HRESULT SetOverlayIcon(IntPtr hwnd, IntPtr hIcon, [MarshalAs(UnmanagedType.LPWStr)] string pszDescription);
[PreserveSig]
HRESULT SetOverlayIcon(IntPtr hwnd, IntPtr hIcon, [MarshalAs(UnmanagedType.LPWStr)] string pszDescription);
[PreserveSig]
HRESULT SetThumbnailTooltip(IntPtr hwnd, [MarshalAs(UnmanagedType.LPWStr)] string pszTip);
[PreserveSig]
HRESULT SetThumbnailTooltip(IntPtr hwnd, [MarshalAs(UnmanagedType.LPWStr)] string pszTip);
[PreserveSig]
HRESULT SetThumbnailClip(IntPtr hwnd, RefRECT prcClip);
}
[PreserveSig]
HRESULT SetThumbnailClip(IntPtr hwnd, RefRECT prcClip);
}
}

View File

@ -3,59 +3,59 @@ using System.Runtime.InteropServices;
namespace Standard
{
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("ea1afb91-9e28-4b86-90e9-9e9f8a5eefaf")]
[ComImport]
internal interface ITaskbarList4 : ITaskbarList3, ITaskbarList2, ITaskbarList
{
void HrInit();
[InterfaceType(ComInterfaceType.InterfaceIsIUnknown)]
[Guid("ea1afb91-9e28-4b86-90e9-9e9f8a5eefaf")]
[ComImport]
internal interface ITaskbarList4 : ITaskbarList3, ITaskbarList2, ITaskbarList
{
void HrInit();
void AddTab(IntPtr hwnd);
void AddTab(IntPtr hwnd);
void DeleteTab(IntPtr hwnd);
void DeleteTab(IntPtr hwnd);
void ActivateTab(IntPtr hwnd);
void ActivateTab(IntPtr hwnd);
void SetActiveAlt(IntPtr hwnd);
void SetActiveAlt(IntPtr hwnd);
void MarkFullscreenWindow(IntPtr hwnd, [MarshalAs(UnmanagedType.Bool)] bool fFullscreen);
void MarkFullscreenWindow(IntPtr hwnd, [MarshalAs(UnmanagedType.Bool)] bool fFullscreen);
[PreserveSig]
HRESULT SetProgressValue(IntPtr hwnd, ulong ullCompleted, ulong ullTotal);
[PreserveSig]
HRESULT SetProgressValue(IntPtr hwnd, ulong ullCompleted, ulong ullTotal);
[PreserveSig]
HRESULT SetProgressState(IntPtr hwnd, TBPF tbpFlags);
[PreserveSig]
HRESULT SetProgressState(IntPtr hwnd, TBPF tbpFlags);
[PreserveSig]
HRESULT RegisterTab(IntPtr hwndTab, IntPtr hwndMDI);
[PreserveSig]
HRESULT RegisterTab(IntPtr hwndTab, IntPtr hwndMDI);
[PreserveSig]
HRESULT UnregisterTab(IntPtr hwndTab);
[PreserveSig]
HRESULT UnregisterTab(IntPtr hwndTab);
[PreserveSig]
HRESULT SetTabOrder(IntPtr hwndTab, IntPtr hwndInsertBefore);
[PreserveSig]
HRESULT SetTabOrder(IntPtr hwndTab, IntPtr hwndInsertBefore);
[PreserveSig]
HRESULT SetTabActive(IntPtr hwndTab, IntPtr hwndMDI, uint dwReserved);
[PreserveSig]
HRESULT SetTabActive(IntPtr hwndTab, IntPtr hwndMDI, uint dwReserved);
[PreserveSig]
HRESULT ThumbBarAddButtons(IntPtr hwnd, uint cButtons, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 1)] THUMBBUTTON[] pButtons);
[PreserveSig]
HRESULT ThumbBarAddButtons(IntPtr hwnd, uint cButtons, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 1)] THUMBBUTTON[] pButtons);
[PreserveSig]
HRESULT ThumbBarUpdateButtons(IntPtr hwnd, uint cButtons, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 1)] THUMBBUTTON[] pButtons);
[PreserveSig]
HRESULT ThumbBarUpdateButtons(IntPtr hwnd, uint cButtons, [MarshalAs(UnmanagedType.LPArray, SizeParamIndex = 1)] THUMBBUTTON[] pButtons);
[PreserveSig]
HRESULT ThumbBarSetImageList(IntPtr hwnd, [MarshalAs(UnmanagedType.IUnknown)] object himl);
[PreserveSig]
HRESULT ThumbBarSetImageList(IntPtr hwnd, [MarshalAs(UnmanagedType.IUnknown)] object himl);
[PreserveSig]
HRESULT SetOverlayIcon(IntPtr hwnd, IntPtr hIcon, [MarshalAs(UnmanagedType.LPWStr)] string pszDescription);
[PreserveSig]
HRESULT SetOverlayIcon(IntPtr hwnd, IntPtr hIcon, [MarshalAs(UnmanagedType.LPWStr)] string pszDescription);
[PreserveSig]
HRESULT SetThumbnailTooltip(IntPtr hwnd, [MarshalAs(UnmanagedType.LPWStr)] string pszTip);
[PreserveSig]
HRESULT SetThumbnailTooltip(IntPtr hwnd, [MarshalAs(UnmanagedType.LPWStr)] string pszTip);
[PreserveSig]
HRESULT SetThumbnailClip(IntPtr hwnd, RefRECT prcClip);
[PreserveSig]
HRESULT SetThumbnailClip(IntPtr hwnd, RefRECT prcClip);
void SetTabProperties(IntPtr hwndTab, STPF stpFlags);
}
void SetTabProperties(IntPtr hwndTab, STPF stpFlags);
}
}

View File

@ -2,9 +2,9 @@
namespace Standard
{
internal enum KDC
{
FREQUENT = 1,
RECENT
}
internal enum KDC
{
FREQUENT = 1,
RECENT
}
}

View File

@ -3,36 +3,36 @@ using System.Runtime.InteropServices;
namespace Standard
{
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
internal struct LOGFONT
{
public int lfHeight;
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
internal struct LOGFONT
{
public int lfHeight;
public int lfWidth;
public int lfWidth;
public int lfEscapement;
public int lfEscapement;
public int lfOrientation;
public int lfOrientation;
public int lfWeight;
public int lfWeight;
public byte lfItalic;
public byte lfItalic;
public byte lfUnderline;
public byte lfUnderline;
public byte lfStrikeOut;
public byte lfStrikeOut;
public byte lfCharSet;
public byte lfCharSet;
public byte lfOutPrecision;
public byte lfOutPrecision;
public byte lfClipPrecision;
public byte lfClipPrecision;
public byte lfQuality;
public byte lfQuality;
public byte lfPitchAndFamily;
public byte lfPitchAndFamily;
[MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
public string lfFaceName;
}
[MarshalAs(UnmanagedType.ByValTStr, SizeConst = 32)]
public string lfFaceName;
}
}

View File

@ -2,14 +2,14 @@
namespace Standard
{
internal struct MARGINS
{
public int cxLeftWidth;
internal struct MARGINS
{
public int cxLeftWidth;
public int cxRightWidth;
public int cxRightWidth;
public int cyTopHeight;
public int cyTopHeight;
public int cyBottomHeight;
}
public int cyBottomHeight;
}
}

View File

@ -2,13 +2,13 @@
namespace Standard
{
[Flags]
internal enum MF : uint
{
DOES_NOT_EXIST = 4294967295u,
ENABLED = 0u,
BYCOMMAND = 0u,
GRAYED = 1u,
DISABLED = 2u
}
[Flags]
internal enum MF : uint
{
DOES_NOT_EXIST = 4294967295u,
ENABLED = 0u,
BYCOMMAND = 0u,
GRAYED = 1u,
DISABLED = 2u
}
}

View File

@ -2,16 +2,16 @@
namespace Standard
{
internal struct MINMAXINFO
{
public POINT ptReserved;
internal struct MINMAXINFO
{
public POINT ptReserved;
public POINT ptMaxSize;
public POINT ptMaxSize;
public POINT ptMaxPosition;
public POINT ptMaxPosition;
public POINT ptMinTrackSize;
public POINT ptMinTrackSize;
public POINT ptMaxTrackSize;
}
public POINT ptMaxTrackSize;
}
}

View File

@ -3,15 +3,15 @@ using System.Runtime.InteropServices;
namespace Standard
{
[StructLayout(LayoutKind.Sequential)]
internal class MONITORINFO
{
public int cbSize = Marshal.SizeOf(typeof(MONITORINFO));
[StructLayout(LayoutKind.Sequential)]
internal class MONITORINFO
{
public int cbSize = Marshal.SizeOf(typeof(MONITORINFO));
public RECT rcMonitor;
public RECT rcMonitor;
public RECT rcWork;
public RECT rcWork;
public int dwFlags;
}
public int dwFlags;
}
}

View File

@ -2,9 +2,9 @@
namespace Standard
{
internal enum MOUSEEVENTF
{
LEFTDOWN = 2,
LEFTUP = 4
}
internal enum MOUSEEVENTF
{
LEFTDOWN = 2,
LEFTUP = 4
}
}

View File

@ -2,18 +2,18 @@
namespace Standard
{
internal struct MOUSEINPUT
{
public int dx;
internal struct MOUSEINPUT
{
public int dx;
public int dy;
public int dy;
public int mouseData;
public int mouseData;
public int dwFlags;
public int dwFlags;
public int time;
public int time;
public IntPtr dwExtraInfo;
}
public IntPtr dwExtraInfo;
}
}

View File

@ -2,10 +2,10 @@
namespace Standard
{
internal enum MSGFLT
{
RESET,
ALLOW,
DISALLOW
}
internal enum MSGFLT
{
RESET,
ALLOW,
DISALLOW
}
}

View File

@ -2,11 +2,11 @@
namespace Standard
{
internal enum MSGFLTINFO
{
NONE,
ALREADYALLOWED_FORWND,
ALREADYDISALLOWED_FORWND,
ALLOWED_HIGHER
}
internal enum MSGFLTINFO
{
NONE,
ALREADYALLOWED_FORWND,
ALREADYDISALLOWED_FORWND,
ALLOWED_HIGHER
}
}

View File

@ -6,145 +6,145 @@ using System.Runtime.InteropServices.ComTypes;
namespace Standard
{
internal sealed class ManagedIStream : IStream, IDisposable
{
public ManagedIStream(Stream source)
{
Verify.IsNotNull<Stream>(source, "source");
this._source = source;
}
internal sealed class ManagedIStream : IStream, IDisposable
{
public ManagedIStream(Stream source)
{
Verify.IsNotNull<Stream>(source, "source");
this._source = source;
}
private void _Validate()
{
if (this._source == null)
{
throw new ObjectDisposedException("this");
}
}
private void _Validate()
{
if (this._source == null)
{
throw new ObjectDisposedException("this");
}
}
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters", MessageId = "Standard.HRESULT.ThrowIfFailed(System.String)")]
[Obsolete("The method is not implemented", true)]
public void Clone(out IStream ppstm)
{
ppstm = null;
HRESULT.STG_E_INVALIDFUNCTION.ThrowIfFailed("The method is not implemented.");
}
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters", MessageId = "Standard.HRESULT.ThrowIfFailed(System.String)")]
[Obsolete("The method is not implemented", true)]
public void Clone(out IStream ppstm)
{
ppstm = null;
HRESULT.STG_E_INVALIDFUNCTION.ThrowIfFailed("The method is not implemented.");
}
public void Commit(int grfCommitFlags)
{
this._Validate();
this._source.Flush();
}
public void Commit(int grfCommitFlags)
{
this._Validate();
this._source.Flush();
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
[SuppressMessage("Microsoft.Design", "CA1062:Validate arguments of public methods", MessageId = "0")]
public void CopyTo(IStream pstm, long cb, IntPtr pcbRead, IntPtr pcbWritten)
{
Verify.IsNotNull<IStream>(pstm, "pstm");
this._Validate();
byte[] array = new byte[4096];
long num;
int num2;
for (num = 0L; num < cb; num += (long)num2)
{
num2 = this._source.Read(array, 0, array.Length);
if (num2 == 0)
{
break;
}
pstm.Write(array, num2, IntPtr.Zero);
}
if (IntPtr.Zero != pcbRead)
{
Marshal.WriteInt64(pcbRead, num);
}
if (IntPtr.Zero != pcbWritten)
{
Marshal.WriteInt64(pcbWritten, num);
}
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
[SuppressMessage("Microsoft.Design", "CA1062:Validate arguments of public methods", MessageId = "0")]
public void CopyTo(IStream pstm, long cb, IntPtr pcbRead, IntPtr pcbWritten)
{
Verify.IsNotNull<IStream>(pstm, "pstm");
this._Validate();
byte[] array = new byte[4096];
long num;
int num2;
for (num = 0L; num < cb; num += (long) num2)
{
num2 = this._source.Read(array, 0, array.Length);
if (num2 == 0)
{
break;
}
pstm.Write(array, num2, IntPtr.Zero);
}
if (IntPtr.Zero != pcbRead)
{
Marshal.WriteInt64(pcbRead, num);
}
if (IntPtr.Zero != pcbWritten)
{
Marshal.WriteInt64(pcbWritten, num);
}
}
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters", MessageId = "Standard.HRESULT.ThrowIfFailed(System.String)")]
[Obsolete("The method is not implemented", true)]
public void LockRegion(long libOffset, long cb, int dwLockType)
{
HRESULT.STG_E_INVALIDFUNCTION.ThrowIfFailed("The method is not implemented.");
}
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters", MessageId = "Standard.HRESULT.ThrowIfFailed(System.String)")]
[Obsolete("The method is not implemented", true)]
public void LockRegion(long libOffset, long cb, int dwLockType)
{
HRESULT.STG_E_INVALIDFUNCTION.ThrowIfFailed("The method is not implemented.");
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void Read(byte[] pv, int cb, IntPtr pcbRead)
{
this._Validate();
int val = this._source.Read(pv, 0, cb);
if (IntPtr.Zero != pcbRead)
{
Marshal.WriteInt32(pcbRead, val);
}
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void Read(byte[] pv, int cb, IntPtr pcbRead)
{
this._Validate();
int val = this._source.Read(pv, 0, cb);
if (IntPtr.Zero != pcbRead)
{
Marshal.WriteInt32(pcbRead, val);
}
}
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters", MessageId = "Standard.HRESULT.ThrowIfFailed(System.String)")]
[Obsolete("The method is not implemented", true)]
public void Revert()
{
HRESULT.STG_E_INVALIDFUNCTION.ThrowIfFailed("The method is not implemented.");
}
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters", MessageId = "Standard.HRESULT.ThrowIfFailed(System.String)")]
[Obsolete("The method is not implemented", true)]
public void Revert()
{
HRESULT.STG_E_INVALIDFUNCTION.ThrowIfFailed("The method is not implemented.");
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void Seek(long dlibMove, int dwOrigin, IntPtr plibNewPosition)
{
this._Validate();
long val = this._source.Seek(dlibMove, (SeekOrigin)dwOrigin);
if (IntPtr.Zero != plibNewPosition)
{
Marshal.WriteInt64(plibNewPosition, val);
}
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void Seek(long dlibMove, int dwOrigin, IntPtr plibNewPosition)
{
this._Validate();
long val = this._source.Seek(dlibMove, (SeekOrigin) dwOrigin);
if (IntPtr.Zero != plibNewPosition)
{
Marshal.WriteInt64(plibNewPosition, val);
}
}
public void SetSize(long libNewSize)
{
this._Validate();
this._source.SetLength(libNewSize);
}
public void SetSize(long libNewSize)
{
this._Validate();
this._source.SetLength(libNewSize);
}
public void Stat(out System.Runtime.InteropServices.ComTypes.STATSTG pstatstg, int grfStatFlag)
{
pstatstg = default(System.Runtime.InteropServices.ComTypes.STATSTG);
this._Validate();
pstatstg.type = 2;
pstatstg.cbSize = this._source.Length;
pstatstg.grfMode = 2;
pstatstg.grfLocksSupported = 2;
}
public void Stat(out System.Runtime.InteropServices.ComTypes.STATSTG pstatstg, int grfStatFlag)
{
pstatstg = default(System.Runtime.InteropServices.ComTypes.STATSTG);
this._Validate();
pstatstg.type = 2;
pstatstg.cbSize = this._source.Length;
pstatstg.grfMode = 2;
pstatstg.grfLocksSupported = 2;
}
[Obsolete("The method is not implemented", true)]
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters", MessageId = "Standard.HRESULT.ThrowIfFailed(System.String)")]
public void UnlockRegion(long libOffset, long cb, int dwLockType)
{
HRESULT.STG_E_INVALIDFUNCTION.ThrowIfFailed("The method is not implemented.");
}
[Obsolete("The method is not implemented", true)]
[SuppressMessage("Microsoft.Globalization", "CA1303:Do not pass literals as localized parameters", MessageId = "Standard.HRESULT.ThrowIfFailed(System.String)")]
public void UnlockRegion(long libOffset, long cb, int dwLockType)
{
HRESULT.STG_E_INVALIDFUNCTION.ThrowIfFailed("The method is not implemented.");
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void Write(byte[] pv, int cb, IntPtr pcbWritten)
{
this._Validate();
this._source.Write(pv, 0, cb);
if (IntPtr.Zero != pcbWritten)
{
Marshal.WriteInt32(pcbWritten, cb);
}
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void Write(byte[] pv, int cb, IntPtr pcbWritten)
{
this._Validate();
this._source.Write(pv, 0, cb);
if (IntPtr.Zero != pcbWritten)
{
Marshal.WriteInt32(pcbWritten, cb);
}
}
public void Dispose()
{
this._source = null;
}
public void Dispose()
{
this._source = null;
}
private const int STGTY_STREAM = 2;
private const int STGTY_STREAM = 2;
private const int STGM_READWRITE = 2;
private const int STGM_READWRITE = 2;
private const int LOCK_EXCLUSIVE = 2;
private const int LOCK_EXCLUSIVE = 2;
private Stream _source;
}
private Stream _source;
}
}

View File

@ -2,5 +2,5 @@
namespace Standard
{
internal delegate IntPtr MessageHandler(WM uMsg, IntPtr wParam, IntPtr lParam, out bool handled);
internal delegate IntPtr MessageHandler(WM uMsg, IntPtr wParam, IntPtr lParam, out bool handled);
}

View File

@ -7,126 +7,126 @@ using System.Windows.Threading;
namespace Standard
{
internal sealed class MessageWindow : DispatcherObject, IDisposable
{
public IntPtr Handle { get; private set; }
internal sealed class MessageWindow : DispatcherObject, IDisposable
{
public IntPtr Handle { get; private set; }
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public MessageWindow(CS classStyle, WS style, WS_EX exStyle, Rect location, string name, WndProc callback)
{
this._wndProcCallback = callback;
this._className = "MessageWindowClass+" + Guid.NewGuid().ToString();
WNDCLASSEX wndclassex = new WNDCLASSEX
{
cbSize = Marshal.SizeOf(typeof(WNDCLASSEX)),
style = classStyle,
lpfnWndProc = MessageWindow.s_WndProc,
hInstance = NativeMethods.GetModuleHandle(null),
hbrBackground = NativeMethods.GetStockObject(StockObject.NULL_BRUSH),
lpszMenuName = "",
lpszClassName = this._className
};
NativeMethods.RegisterClassEx(ref wndclassex);
GCHandle value = default(GCHandle);
try
{
value = GCHandle.Alloc(this);
IntPtr lpParam = (IntPtr)value;
this.Handle = NativeMethods.CreateWindowEx(exStyle, this._className, name, style, (int)location.X, (int)location.Y, (int)location.Width, (int)location.Height, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, lpParam);
}
finally
{
value.Free();
}
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public MessageWindow(CS classStyle, WS style, WS_EX exStyle, Rect location, string name, WndProc callback)
{
this._wndProcCallback = callback;
this._className = "MessageWindowClass+" + Guid.NewGuid().ToString();
WNDCLASSEX wndclassex = new WNDCLASSEX
{
cbSize = Marshal.SizeOf(typeof(WNDCLASSEX)),
style = classStyle,
lpfnWndProc = MessageWindow.s_WndProc,
hInstance = NativeMethods.GetModuleHandle(null),
hbrBackground = NativeMethods.GetStockObject(StockObject.NULL_BRUSH),
lpszMenuName = "",
lpszClassName = this._className
};
NativeMethods.RegisterClassEx(ref wndclassex);
GCHandle value = default(GCHandle);
try
{
value = GCHandle.Alloc(this);
IntPtr lpParam = (IntPtr) value;
this.Handle = NativeMethods.CreateWindowEx(exStyle, this._className, name, style, (int) location.X, (int) location.Y, (int) location.Width, (int) location.Height, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, lpParam);
}
finally
{
value.Free();
}
}
~MessageWindow()
{
this._Dispose(false, false);
}
~MessageWindow()
{
this._Dispose(false, false);
}
public void Dispose()
{
this._Dispose(true, false);
GC.SuppressFinalize(this);
}
public void Dispose()
{
this._Dispose(true, false);
GC.SuppressFinalize(this);
}
[SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "disposing")]
private void _Dispose(bool disposing, bool isHwndBeingDestroyed)
{
if (this._isDisposed)
{
return;
}
this._isDisposed = true;
IntPtr hwnd = this.Handle;
string className = this._className;
if (isHwndBeingDestroyed)
{
base.Dispatcher.BeginInvoke(DispatcherPriority.Normal, new DispatcherOperationCallback((object arg) => MessageWindow._DestroyWindow(IntPtr.Zero, className)));
}
else if (this.Handle != IntPtr.Zero)
{
if (base.CheckAccess())
{
MessageWindow._DestroyWindow(hwnd, className);
}
else
{
base.Dispatcher.BeginInvoke(DispatcherPriority.Normal, new DispatcherOperationCallback((object arg) => MessageWindow._DestroyWindow(hwnd, className)));
}
}
MessageWindow.s_windowLookup.Remove(hwnd);
this._className = null;
this.Handle = IntPtr.Zero;
}
[SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "disposing")]
private void _Dispose(bool disposing, bool isHwndBeingDestroyed)
{
if (this._isDisposed)
{
return;
}
this._isDisposed = true;
IntPtr hwnd = this.Handle;
string className = this._className;
if (isHwndBeingDestroyed)
{
base.Dispatcher.BeginInvoke(DispatcherPriority.Normal, new DispatcherOperationCallback((object arg) => MessageWindow._DestroyWindow(IntPtr.Zero, className)));
}
else if (this.Handle != IntPtr.Zero)
{
if (base.CheckAccess())
{
MessageWindow._DestroyWindow(hwnd, className);
}
else
{
base.Dispatcher.BeginInvoke(DispatcherPriority.Normal, new DispatcherOperationCallback((object arg) => MessageWindow._DestroyWindow(hwnd, className)));
}
}
MessageWindow.s_windowLookup.Remove(hwnd);
this._className = null;
this.Handle = IntPtr.Zero;
}
[SuppressMessage("Microsoft.Usage", "CA1816:CallGCSuppressFinalizeCorrectly")]
private static IntPtr _WndProc(IntPtr hwnd, WM msg, IntPtr wParam, IntPtr lParam)
{
IntPtr result = IntPtr.Zero;
MessageWindow messageWindow = null;
if (msg == WM.CREATE)
{
messageWindow = (MessageWindow)GCHandle.FromIntPtr(((CREATESTRUCT)Marshal.PtrToStructure(lParam, typeof(CREATESTRUCT))).lpCreateParams).Target;
MessageWindow.s_windowLookup.Add(hwnd, messageWindow);
}
else if (!MessageWindow.s_windowLookup.TryGetValue(hwnd, out messageWindow))
{
return NativeMethods.DefWindowProc(hwnd, msg, wParam, lParam);
}
WndProc wndProcCallback = messageWindow._wndProcCallback;
if (wndProcCallback != null)
{
result = wndProcCallback(hwnd, msg, wParam, lParam);
}
else
{
result = NativeMethods.DefWindowProc(hwnd, msg, wParam, lParam);
}
if (msg == WM.NCDESTROY)
{
messageWindow._Dispose(true, true);
GC.SuppressFinalize(messageWindow);
}
return result;
}
[SuppressMessage("Microsoft.Usage", "CA1816:CallGCSuppressFinalizeCorrectly")]
private static IntPtr _WndProc(IntPtr hwnd, WM msg, IntPtr wParam, IntPtr lParam)
{
IntPtr result = IntPtr.Zero;
MessageWindow messageWindow = null;
if (msg == WM.CREATE)
{
messageWindow = (MessageWindow) GCHandle.FromIntPtr(((CREATESTRUCT) Marshal.PtrToStructure(lParam, typeof(CREATESTRUCT))).lpCreateParams).Target;
MessageWindow.s_windowLookup.Add(hwnd, messageWindow);
}
else if (!MessageWindow.s_windowLookup.TryGetValue(hwnd, out messageWindow))
{
return NativeMethods.DefWindowProc(hwnd, msg, wParam, lParam);
}
WndProc wndProcCallback = messageWindow._wndProcCallback;
if (wndProcCallback != null)
{
result = wndProcCallback(hwnd, msg, wParam, lParam);
}
else
{
result = NativeMethods.DefWindowProc(hwnd, msg, wParam, lParam);
}
if (msg == WM.NCDESTROY)
{
messageWindow._Dispose(true, true);
GC.SuppressFinalize(messageWindow);
}
return result;
}
private static object _DestroyWindow(IntPtr hwnd, string className)
{
Utility.SafeDestroyWindow(ref hwnd);
NativeMethods.UnregisterClass(className, NativeMethods.GetModuleHandle(null));
return null;
}
private static object _DestroyWindow(IntPtr hwnd, string className)
{
Utility.SafeDestroyWindow(ref hwnd);
NativeMethods.UnregisterClass(className, NativeMethods.GetModuleHandle(null));
return null;
}
private static readonly WndProc s_WndProc = new WndProc(MessageWindow._WndProc);
private static readonly WndProc s_WndProc = new WndProc(MessageWindow._WndProc);
private static readonly Dictionary<IntPtr, MessageWindow> s_windowLookup = new Dictionary<IntPtr, MessageWindow>();
private static readonly Dictionary<IntPtr, MessageWindow> s_windowLookup = new Dictionary<IntPtr, MessageWindow>();
private WndProc _wndProcCallback;
private WndProc _wndProcCallback;
private string _className;
private string _className;
private bool _isDisposed;
}
private bool _isDisposed;
}
}

View File

@ -2,18 +2,18 @@
namespace Standard
{
[Flags]
internal enum NIF : uint
{
MESSAGE = 1u,
ICON = 2u,
TIP = 4u,
STATE = 8u,
INFO = 16u,
GUID = 32u,
REALTIME = 64u,
SHOWTIP = 128u,
XP_MASK = 59u,
VISTA_MASK = 251u
}
[Flags]
internal enum NIF : uint
{
MESSAGE = 1u,
ICON = 2u,
TIP = 4u,
STATE = 8u,
INFO = 16u,
GUID = 32u,
REALTIME = 64u,
SHOWTIP = 128u,
XP_MASK = 59u,
VISTA_MASK = 251u
}
}

View File

@ -2,16 +2,16 @@
namespace Standard
{
internal enum NIIF
{
NONE,
INFO,
WARNING,
ERROR,
USER,
NOSOUND = 16,
LARGE_ICON = 32,
NIIF_RESPECT_QUIET_TIME = 128,
XP_ICON_MASK = 15
}
internal enum NIIF
{
NONE,
INFO,
WARNING,
ERROR,
USER,
NOSOUND = 16,
LARGE_ICON = 32,
NIIF_RESPECT_QUIET_TIME = 128,
XP_ICON_MASK = 15
}
}

View File

@ -2,12 +2,12 @@
namespace Standard
{
internal enum NIM : uint
{
ADD,
MODIFY,
DELETE,
SETFOCUS,
SETVERSION
}
internal enum NIM : uint
{
ADD,
MODIFY,
DELETE,
SETFOCUS,
SETVERSION
}
}

View File

@ -4,62 +4,62 @@ using System.Runtime.InteropServices;
namespace Standard
{
internal struct NONCLIENTMETRICS
{
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public static NONCLIENTMETRICS VistaMetricsStruct
{
get
{
return new NONCLIENTMETRICS
{
cbSize = Marshal.SizeOf(typeof(NONCLIENTMETRICS))
};
}
}
internal struct NONCLIENTMETRICS
{
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public static NONCLIENTMETRICS VistaMetricsStruct
{
get
{
return new NONCLIENTMETRICS
{
cbSize = Marshal.SizeOf(typeof(NONCLIENTMETRICS))
};
}
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public static NONCLIENTMETRICS XPMetricsStruct
{
get
{
return new NONCLIENTMETRICS
{
cbSize = Marshal.SizeOf(typeof(NONCLIENTMETRICS)) - 4
};
}
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public static NONCLIENTMETRICS XPMetricsStruct
{
get
{
return new NONCLIENTMETRICS
{
cbSize = Marshal.SizeOf(typeof(NONCLIENTMETRICS)) - 4
};
}
}
public int cbSize;
public int cbSize;
public int iBorderWidth;
public int iBorderWidth;
public int iScrollWidth;
public int iScrollWidth;
public int iScrollHeight;
public int iScrollHeight;
public int iCaptionWidth;
public int iCaptionWidth;
public int iCaptionHeight;
public int iCaptionHeight;
public LOGFONT lfCaptionFont;
public LOGFONT lfCaptionFont;
public int iSmCaptionWidth;
public int iSmCaptionWidth;
public int iSmCaptionHeight;
public int iSmCaptionHeight;
public LOGFONT lfSmCaptionFont;
public LOGFONT lfSmCaptionFont;
public int iMenuWidth;
public int iMenuWidth;
public int iMenuHeight;
public int iMenuHeight;
public LOGFONT lfMenuFont;
public LOGFONT lfMenuFont;
public LOGFONT lfStatusFont;
public LOGFONT lfStatusFont;
public LOGFONT lfMessageFont;
public LOGFONT lfMessageFont;
public int iPaddedBorderWidth;
}
public int iPaddedBorderWidth;
}
}

View File

@ -4,41 +4,41 @@ using System.Runtime.InteropServices;
namespace Standard
{
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential)]
internal class NOTIFYICONDATA
{
public int cbSize;
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential)]
internal class NOTIFYICONDATA
{
public int cbSize;
public IntPtr hWnd;
public IntPtr hWnd;
public int uID;
public int uID;
public NIF uFlags;
public NIF uFlags;
public int uCallbackMessage;
public int uCallbackMessage;
public IntPtr hIcon;
public IntPtr hIcon;
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 128)]
public char[] szTip = new char[128];
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 128)]
public char[] szTip = new char[128];
public uint dwState;
public uint dwState;
public uint dwStateMask;
public uint dwStateMask;
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 256)]
public char[] szInfo = new char[256];
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 256)]
public char[] szInfo = new char[256];
public uint uVersion;
public uint uVersion;
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 64)]
public char[] szInfoTitle = new char[64];
[MarshalAs(UnmanagedType.ByValArray, SizeConst = 64)]
public char[] szInfoTitle = new char[64];
public uint dwInfoFlags;
public uint dwInfoFlags;
public Guid guidItem;
public Guid guidItem;
private IntPtr hBalloonIcon;
}
private IntPtr hBalloonIcon;
}
}

File diff suppressed because it is too large Load Diff

View File

@ -2,11 +2,11 @@
namespace Standard
{
internal enum OLECMDEXECOPT
{
DODEFAULT,
PROMPTUSER,
DONTPROMPTUSER,
SHOWHELP
}
internal enum OLECMDEXECOPT
{
DODEFAULT,
PROMPTUSER,
DONTPROMPTUSER,
SHOWHELP
}
}

View File

@ -2,13 +2,13 @@
namespace Standard
{
internal enum OLECMDF
{
SUPPORTED = 1,
ENABLED,
LATCHED = 4,
NINCHED = 8,
INVISIBLE = 16,
DEFHIDEONCTXTMENU = 32
}
internal enum OLECMDF
{
SUPPORTED = 1,
ENABLED,
LATCHED = 4,
NINCHED = 8,
INVISIBLE = 16,
DEFHIDEONCTXTMENU = 32
}
}

View File

@ -2,64 +2,64 @@
namespace Standard
{
internal enum OLECMDID
{
OPEN = 1,
NEW,
SAVE,
SAVEAS,
SAVECOPYAS,
PRINT,
PRINTPREVIEW,
PAGESETUP,
SPELL,
PROPERTIES,
CUT,
COPY,
PASTE,
PASTESPECIAL,
UNDO,
REDO,
SELECTALL,
CLEARSELECTION,
ZOOM,
GETZOOMRANGE,
UPDATECOMMANDS,
REFRESH,
STOP,
HIDETOOLBARS,
SETPROGRESSMAX,
SETPROGRESSPOS,
SETPROGRESSTEXT,
SETTITLE,
SETDOWNLOADSTATE,
STOPDOWNLOAD,
ONTOOLBARACTIVATED,
FIND,
DELETE,
HTTPEQUIV,
HTTPEQUIV_DONE,
ENABLE_INTERACTION,
ONUNLOAD,
PROPERTYBAG2,
PREREFRESH,
SHOWSCRIPTERROR,
SHOWMESSAGE,
SHOWFIND,
SHOWPAGESETUP,
SHOWPRINT,
CLOSE,
ALLOWUILESSSAVEAS,
DONTDOWNLOADCSS,
UPDATEPAGESTATUS,
PRINT2,
PRINTPREVIEW2,
SETPRINTTEMPLATE,
GETPRINTTEMPLATE,
PAGEACTIONBLOCKED = 55,
PAGEACTIONUIQUERY,
FOCUSVIEWCONTROLS,
FOCUSVIEWCONTROLSQUERY,
SHOWPAGEACTIONMENU
}
internal enum OLECMDID
{
OPEN = 1,
NEW,
SAVE,
SAVEAS,
SAVECOPYAS,
PRINT,
PRINTPREVIEW,
PAGESETUP,
SPELL,
PROPERTIES,
CUT,
COPY,
PASTE,
PASTESPECIAL,
UNDO,
REDO,
SELECTALL,
CLEARSELECTION,
ZOOM,
GETZOOMRANGE,
UPDATECOMMANDS,
REFRESH,
STOP,
HIDETOOLBARS,
SETPROGRESSMAX,
SETPROGRESSPOS,
SETPROGRESSTEXT,
SETTITLE,
SETDOWNLOADSTATE,
STOPDOWNLOAD,
ONTOOLBARACTIVATED,
FIND,
DELETE,
HTTPEQUIV,
HTTPEQUIV_DONE,
ENABLE_INTERACTION,
ONUNLOAD,
PROPERTYBAG2,
PREREFRESH,
SHOWSCRIPTERROR,
SHOWMESSAGE,
SHOWFIND,
SHOWPAGESETUP,
SHOWPRINT,
CLOSE,
ALLOWUILESSSAVEAS,
DONTDOWNLOADCSS,
UPDATEPAGESTATUS,
PRINT2,
PRINTPREVIEW2,
SETPRINTTEMPLATE,
GETPRINTTEMPLATE,
PAGEACTIONBLOCKED = 55,
PAGEACTIONUIQUERY,
FOCUSVIEWCONTROLS,
FOCUSVIEWCONTROLSQUERY,
SHOWPAGEACTIONMENU
}
}

View File

@ -3,29 +3,29 @@ using System.Runtime.InteropServices;
namespace Standard
{
[StructLayout(LayoutKind.Sequential, Pack = 4)]
internal struct PKEY
{
public PKEY(Guid fmtid, uint pid)
{
this._fmtid = fmtid;
this._pid = pid;
}
[StructLayout(LayoutKind.Sequential, Pack = 4)]
internal struct PKEY
{
public PKEY(Guid fmtid, uint pid)
{
this._fmtid = fmtid;
this._pid = pid;
}
private readonly Guid _fmtid;
private readonly Guid _fmtid;
private readonly uint _pid;
private readonly uint _pid;
public static readonly PKEY Title = new PKEY(new Guid("F29F85E0-4FF9-1068-AB91-08002B27B3D9"), 2u);
public static readonly PKEY Title = new PKEY(new Guid("F29F85E0-4FF9-1068-AB91-08002B27B3D9"), 2u);
public static readonly PKEY AppUserModel_ID = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 5u);
public static readonly PKEY AppUserModel_ID = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 5u);
public static readonly PKEY AppUserModel_IsDestListSeparator = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 6u);
public static readonly PKEY AppUserModel_IsDestListSeparator = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 6u);
public static readonly PKEY AppUserModel_RelaunchCommand = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 2u);
public static readonly PKEY AppUserModel_RelaunchCommand = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 2u);
public static readonly PKEY AppUserModel_RelaunchDisplayNameResource = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 4u);
public static readonly PKEY AppUserModel_RelaunchDisplayNameResource = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 4u);
public static readonly PKEY AppUserModel_RelaunchIconResource = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 3u);
}
public static readonly PKEY AppUserModel_RelaunchIconResource = new PKEY(new Guid("9F4C2855-9F79-4B39-A8D0-E1D42DE1D5F3"), 3u);
}
}

View File

@ -2,10 +2,10 @@
namespace Standard
{
internal struct POINT
{
public int x;
internal struct POINT
{
public int x;
public int y;
}
public int y;
}
}

View File

@ -4,91 +4,91 @@ using System.Runtime.InteropServices;
namespace Standard
{
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Explicit)]
internal class PROPVARIANT : IDisposable
{
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public VarEnum VarType
{
get
{
return (VarEnum)this.vt;
}
}
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Explicit)]
internal class PROPVARIANT : IDisposable
{
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public VarEnum VarType
{
get
{
return (VarEnum) this.vt;
}
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public string GetValue()
{
if (this.vt == 31)
{
return Marshal.PtrToStringUni(this.pointerVal);
}
return null;
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public string GetValue()
{
if (this.vt == 31)
{
return Marshal.PtrToStringUni(this.pointerVal);
}
return null;
}
public void SetValue(bool f)
{
this.Clear();
this.vt = 11;
this.boolVal = (short)(f ? -1 : 0);
}
public void SetValue(bool f)
{
this.Clear();
this.vt = 11;
this.boolVal = (short) (f ? -1 : 0);
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void SetValue(string val)
{
this.Clear();
this.vt = 31;
this.pointerVal = Marshal.StringToCoTaskMemUni(val);
}
[SuppressMessage("Microsoft.Security", "CA2122:DoNotIndirectlyExposeMethodsWithLinkDemands")]
public void SetValue(string val)
{
this.Clear();
this.vt = 31;
this.pointerVal = Marshal.StringToCoTaskMemUni(val);
}
public void Clear()
{
PROPVARIANT.NativeMethods.PropVariantClear(this);
}
public void Clear()
{
PROPVARIANT.NativeMethods.PropVariantClear(this);
}
public void Dispose()
{
this.Dispose(true);
GC.SuppressFinalize(this);
}
public void Dispose()
{
this.Dispose(true);
GC.SuppressFinalize(this);
}
~PROPVARIANT()
{
this.Dispose(false);
}
~PROPVARIANT()
{
this.Dispose(false);
}
[SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "disposing")]
private void Dispose(bool disposing)
{
this.Clear();
}
[SuppressMessage("Microsoft.Usage", "CA1801:ReviewUnusedParameters", MessageId = "disposing")]
private void Dispose(bool disposing)
{
this.Clear();
}
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(0)]
private ushort vt;
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(0)]
private ushort vt;
[SuppressMessage("Microsoft.Reliability", "CA2006:UseSafeHandleToEncapsulateNativeResources")]
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(8)]
private IntPtr pointerVal;
[SuppressMessage("Microsoft.Reliability", "CA2006:UseSafeHandleToEncapsulateNativeResources")]
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(8)]
private IntPtr pointerVal;
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(8)]
private byte byteVal;
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(8)]
private byte byteVal;
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(8)]
private long longVal;
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(8)]
private long longVal;
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(8)]
private short boolVal;
[SuppressMessage("Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields")]
[FieldOffset(8)]
private short boolVal;
private static class NativeMethods
{
[DllImport("ole32.dll")]
internal static extern HRESULT PropVariantClear(PROPVARIANT pvar);
}
}
private static class NativeMethods
{
[DllImport("ole32.dll")]
internal static extern HRESULT PropVariantClear(PROPVARIANT pvar);
}
}
}

View File

@ -2,12 +2,12 @@
namespace Standard
{
internal enum READYSTATE
{
UNINITIALIZED,
LOADING,
LOADED,
INTERACTIVE,
COMPLETE
}
internal enum READYSTATE
{
UNINITIALIZED,
LOADING,
LOADED,
INTERACTIVE,
COMPLETE
}
}

View File

@ -3,150 +3,150 @@ using System.Diagnostics.CodeAnalysis;
namespace Standard
{
internal struct RECT
{
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public void Offset(int dx, int dy)
{
this._left += dx;
this._top += dy;
this._right += dx;
this._bottom += dy;
}
internal struct RECT
{
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public void Offset(int dx, int dy)
{
this._left += dx;
this._top += dy;
this._right += dx;
this._bottom += dy;
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Left
{
get
{
return this._left;
}
set
{
this._left = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Left
{
get
{
return this._left;
}
set
{
this._left = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Right
{
get
{
return this._right;
}
set
{
this._right = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Right
{
get
{
return this._right;
}
set
{
this._right = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Top
{
get
{
return this._top;
}
set
{
this._top = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Top
{
get
{
return this._top;
}
set
{
this._top = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Bottom
{
get
{
return this._bottom;
}
set
{
this._bottom = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Bottom
{
get
{
return this._bottom;
}
set
{
this._bottom = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Width
{
get
{
return this._right - this._left;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Width
{
get
{
return this._right - this._left;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Height
{
get
{
return this._bottom - this._top;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Height
{
get
{
return this._bottom - this._top;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public POINT Position
{
get
{
return new POINT
{
x = this._left,
y = this._top
};
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public POINT Position
{
get
{
return new POINT
{
x = this._left,
y = this._top
};
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public SIZE Size
{
get
{
return new SIZE
{
cx = this.Width,
cy = this.Height
};
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public SIZE Size
{
get
{
return new SIZE
{
cx = this.Width,
cy = this.Height
};
}
}
public static RECT Union(RECT rect1, RECT rect2)
{
return new RECT
{
Left = Math.Min(rect1.Left, rect2.Left),
Top = Math.Min(rect1.Top, rect2.Top),
Right = Math.Max(rect1.Right, rect2.Right),
Bottom = Math.Max(rect1.Bottom, rect2.Bottom)
};
}
public static RECT Union(RECT rect1, RECT rect2)
{
return new RECT
{
Left = Math.Min(rect1.Left, rect2.Left),
Top = Math.Min(rect1.Top, rect2.Top),
Right = Math.Max(rect1.Right, rect2.Right),
Bottom = Math.Max(rect1.Bottom, rect2.Bottom)
};
}
public override bool Equals(object obj)
{
bool result;
try
{
RECT rect = (RECT)obj;
result = (rect._bottom == this._bottom && rect._left == this._left && rect._right == this._right && rect._top == this._top);
}
catch (InvalidCastException)
{
result = false;
}
return result;
}
public override bool Equals(object obj)
{
bool result;
try
{
RECT rect = (RECT) obj;
result = (rect._bottom == this._bottom && rect._left == this._left && rect._right == this._right && rect._top == this._top);
}
catch (InvalidCastException)
{
result = false;
}
return result;
}
public override int GetHashCode()
{
return (this._left << 16 | Utility.LOWORD(this._right)) ^ (this._top << 16 | Utility.LOWORD(this._bottom));
}
public override int GetHashCode()
{
return (this._left << 16 | Utility.LOWORD(this._right)) ^ (this._top << 16 | Utility.LOWORD(this._bottom));
}
private int _left;
private int _left;
private int _top;
private int _top;
private int _right;
private int _right;
private int _bottom;
}
private int _bottom;
}
}

View File

@ -2,14 +2,14 @@
namespace Standard
{
internal struct RGBQUAD
{
public byte rgbBlue;
internal struct RGBQUAD
{
public byte rgbBlue;
public byte rgbGreen;
public byte rgbGreen;
public byte rgbRed;
public byte rgbRed;
public byte rgbReserved;
}
public byte rgbReserved;
}
}

View File

@ -2,12 +2,12 @@
namespace Standard
{
internal enum RGN
{
AND = 1,
OR,
XOR,
DIFF,
COPY
}
internal enum RGN
{
AND = 1,
OR,
XOR,
DIFF,
COPY
}
}

View File

@ -4,12 +4,12 @@ using System.Runtime.InteropServices;
namespace Standard
{
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential)]
internal class RefPOINT
{
public int x;
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential)]
internal class RefPOINT
{
public int x;
public int y;
}
public int y;
}
}

View File

@ -4,104 +4,104 @@ using System.Runtime.InteropServices;
namespace Standard
{
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential)]
internal class RefRECT
{
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public RefRECT(int left, int top, int right, int bottom)
{
this._left = left;
this._top = top;
this._right = right;
this._bottom = bottom;
}
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential)]
internal class RefRECT
{
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public RefRECT(int left, int top, int right, int bottom)
{
this._left = left;
this._top = top;
this._right = right;
this._bottom = bottom;
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Width
{
get
{
return this._right - this._left;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Width
{
get
{
return this._right - this._left;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Height
{
get
{
return this._bottom - this._top;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Height
{
get
{
return this._bottom - this._top;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Left
{
get
{
return this._left;
}
set
{
this._left = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Left
{
get
{
return this._left;
}
set
{
this._left = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Right
{
get
{
return this._right;
}
set
{
this._right = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Right
{
get
{
return this._right;
}
set
{
this._right = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Top
{
get
{
return this._top;
}
set
{
this._top = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Top
{
get
{
return this._top;
}
set
{
this._top = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Bottom
{
get
{
return this._bottom;
}
set
{
this._bottom = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public int Bottom
{
get
{
return this._bottom;
}
set
{
this._bottom = value;
}
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public void Offset(int dx, int dy)
{
this._left += dx;
this._top += dy;
this._right += dx;
this._bottom += dy;
}
[SuppressMessage("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
public void Offset(int dx, int dy)
{
this._left += dx;
this._top += dy;
this._right += dx;
this._bottom += dy;
}
private int _left;
private int _left;
private int _top;
private int _top;
private int _right;
private int _right;
private int _bottom;
}
private int _bottom;
}
}

View File

@ -2,30 +2,30 @@
namespace Standard
{
internal enum SC
{
SIZE = 61440,
MOVE = 61456,
MINIMIZE = 61472,
MAXIMIZE = 61488,
NEXTWINDOW = 61504,
PREVWINDOW = 61520,
CLOSE = 61536,
VSCROLL = 61552,
HSCROLL = 61568,
MOUSEMENU = 61584,
KEYMENU = 61696,
ARRANGE = 61712,
RESTORE = 61728,
TASKLIST = 61744,
SCREENSAVE = 61760,
HOTKEY = 61776,
DEFAULT = 61792,
MONITORPOWER = 61808,
CONTEXTHELP = 61824,
SEPARATOR = 61455,
F_ISSECURE = 1,
ICON = 61472,
ZOOM = 61488
}
internal enum SC
{
SIZE = 61440,
MOVE = 61456,
MINIMIZE = 61472,
MAXIMIZE = 61488,
NEXTWINDOW = 61504,
PREVWINDOW = 61520,
CLOSE = 61536,
VSCROLL = 61552,
HSCROLL = 61568,
MOUSEMENU = 61584,
KEYMENU = 61696,
ARRANGE = 61712,
RESTORE = 61728,
TASKLIST = 61744,
SCREENSAVE = 61760,
HOTKEY = 61776,
DEFAULT = 61792,
MONITORPOWER = 61808,
CONTEXTHELP = 61824,
SEPARATOR = 61455,
F_ISSECURE = 1,
ICON = 61472,
ZOOM = 61488
}
}

View File

@ -2,42 +2,42 @@
namespace Standard
{
[Flags]
internal enum SFGAO : uint
{
CANCOPY = 1u,
CANMOVE = 2u,
CANLINK = 4u,
STORAGE = 8u,
CANRENAME = 16u,
CANDELETE = 32u,
HASPROPSHEET = 64u,
DROPTARGET = 256u,
CAPABILITYMASK = 375u,
ENCRYPTED = 8192u,
ISSLOW = 16384u,
GHOSTED = 32768u,
LINK = 65536u,
SHARE = 131072u,
READONLY = 262144u,
HIDDEN = 524288u,
DISPLAYATTRMASK = 1032192u,
FILESYSANCESTOR = 268435456u,
FOLDER = 536870912u,
FILESYSTEM = 1073741824u,
HASSUBFOLDER = 2147483648u,
CONTENTSMASK = 2147483648u,
VALIDATE = 16777216u,
REMOVABLE = 33554432u,
COMPRESSED = 67108864u,
BROWSABLE = 134217728u,
NONENUMERATED = 1048576u,
NEWCONTENT = 2097152u,
CANMONIKER = 4194304u,
HASSTORAGE = 4194304u,
STREAM = 4194304u,
STORAGEANCESTOR = 8388608u,
STORAGECAPMASK = 1891958792u,
PKEYSFGAOMASK = 2164539392u
}
[Flags]
internal enum SFGAO : uint
{
CANCOPY = 1u,
CANMOVE = 2u,
CANLINK = 4u,
STORAGE = 8u,
CANRENAME = 16u,
CANDELETE = 32u,
HASPROPSHEET = 64u,
DROPTARGET = 256u,
CAPABILITYMASK = 375u,
ENCRYPTED = 8192u,
ISSLOW = 16384u,
GHOSTED = 32768u,
LINK = 65536u,
SHARE = 131072u,
READONLY = 262144u,
HIDDEN = 524288u,
DISPLAYATTRMASK = 1032192u,
FILESYSANCESTOR = 268435456u,
FOLDER = 536870912u,
FILESYSTEM = 1073741824u,
HASSUBFOLDER = 2147483648u,
CONTENTSMASK = 2147483648u,
VALIDATE = 16777216u,
REMOVABLE = 33554432u,
COMPRESSED = 67108864u,
BROWSABLE = 134217728u,
NONENUMERATED = 1048576u,
NEWCONTENT = 2097152u,
CANMONIKER = 4194304u,
HASSTORAGE = 4194304u,
STREAM = 4194304u,
STORAGEANCESTOR = 8388608u,
STORAGECAPMASK = 1891958792u,
PKEYSFGAOMASK = 2164539392u
}
}

View File

@ -2,14 +2,14 @@
namespace Standard
{
internal enum SHARD
{
PIDL = 1,
PATHA,
PATHW,
APPIDINFO,
APPIDINFOIDLIST,
LINK,
APPIDINFOLINK
}
internal enum SHARD
{
PIDL = 1,
PATHA,
PATHW,
APPIDINFO,
APPIDINFOIDLIST,
LINK,
APPIDINFOLINK
}
}

View File

@ -4,14 +4,14 @@ using System.Runtime.InteropServices;
namespace Standard
{
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential, Pack = 4)]
internal class SHARDAPPIDINFO
{
[MarshalAs(UnmanagedType.Interface)]
private object psi;
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential, Pack = 4)]
internal class SHARDAPPIDINFO
{
[MarshalAs(UnmanagedType.Interface)]
private object psi;
[MarshalAs(UnmanagedType.LPWStr)]
private string pszAppID;
}
[MarshalAs(UnmanagedType.LPWStr)]
private string pszAppID;
}
}

View File

@ -4,13 +4,13 @@ using System.Runtime.InteropServices;
namespace Standard
{
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential, Pack = 4)]
internal class SHARDAPPIDINFOIDLIST
{
private IntPtr pidl;
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential, Pack = 4)]
internal class SHARDAPPIDINFOIDLIST
{
private IntPtr pidl;
[MarshalAs(UnmanagedType.LPWStr)]
private string pszAppID;
}
[MarshalAs(UnmanagedType.LPWStr)]
private string pszAppID;
}
}

View File

@ -4,13 +4,13 @@ using System.Runtime.InteropServices;
namespace Standard
{
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential, Pack = 4)]
internal class SHARDAPPIDINFOLINK
{
private IntPtr psl;
[SuppressMessage("Microsoft.Performance", "CA1812:AvoidUninstantiatedInternalClasses")]
[StructLayout(LayoutKind.Sequential, Pack = 4)]
internal class SHARDAPPIDINFOLINK
{
private IntPtr psl;
[MarshalAs(UnmanagedType.LPWStr)]
private string pszAppID;
}
[MarshalAs(UnmanagedType.LPWStr)]
private string pszAppID;
}
}

View File

@ -2,19 +2,19 @@
namespace Standard
{
internal enum SHCONTF
{
CHECKING_FOR_CHILDREN = 16,
FOLDERS = 32,
NONFOLDERS = 64,
INCLUDEHIDDEN = 128,
INIT_ON_FIRST_NEXT = 256,
NETPRINTERSRCH = 512,
SHAREABLE = 1024,
STORAGE = 2048,
NAVIGATION_ENUM = 4096,
FASTITEMS = 8192,
FLATLIST = 16384,
ENABLE_ASYNC = 32768
}
internal enum SHCONTF
{
CHECKING_FOR_CHILDREN = 16,
FOLDERS = 32,
NONFOLDERS = 64,
INCLUDEHIDDEN = 128,
INIT_ON_FIRST_NEXT = 256,
NETPRINTERSRCH = 512,
SHAREABLE = 1024,
STORAGE = 2048,
NAVIGATION_ENUM = 4096,
FASTITEMS = 8192,
FLATLIST = 16384,
ENABLE_ASYNC = 32768
}
}

View File

@ -3,26 +3,26 @@ using System.Runtime.InteropServices;
namespace Standard
{
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode, Pack = 1)]
internal struct SHFILEOPSTRUCT
{
public IntPtr hwnd;
[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode, Pack = 1)]
internal struct SHFILEOPSTRUCT
{
public IntPtr hwnd;
[MarshalAs(UnmanagedType.U4)]
public FO wFunc;
[MarshalAs(UnmanagedType.U4)]
public FO wFunc;
public string pFrom;
public string pFrom;
public string pTo;
public string pTo;
[MarshalAs(UnmanagedType.U2)]
public FOF fFlags;
[MarshalAs(UnmanagedType.U2)]
public FOF fFlags;
[MarshalAs(UnmanagedType.Bool)]
public int fAnyOperationsAborted;
[MarshalAs(UnmanagedType.Bool)]
public int fAnyOperationsAborted;
public IntPtr hNameMappings;
public IntPtr hNameMappings;
public string lpszProgressTitle;
}
public string lpszProgressTitle;
}
}

Some files were not shown because too many files have changed in this diff Show More