diff --git a/OBSBlur/Window/WindowInfo.cs b/OBSBlur/Window/WindowInfo.cs index c3bd450..4dfc808 100644 --- a/OBSBlur/Window/WindowInfo.cs +++ b/OBSBlur/Window/WindowInfo.cs @@ -5,11 +5,11 @@ namespace OBSBlur.Window; public struct WindowInfo { internal IntPtr WindowHandle { get; init; } - public WINDOWPLACEMENT WindowPlacement { get; init; } + public WindowPlacement WindowPlacement { get; init; } public string WindowTitle { get; init; } public Process ProcessInfo { get; init; } - public WindowInfo(IntPtr windowHandle, string windowTitle, Process processInfo, WINDOWPLACEMENT windowPlacement) + public WindowInfo(IntPtr windowHandle, string windowTitle, Process processInfo, WindowPlacement windowPlacement) { this.WindowHandle = windowHandle; this.ProcessInfo = processInfo; diff --git a/OBSBlur/Window/WindowManager.cs b/OBSBlur/Window/WindowManager.cs index 8953f73..4c58893 100644 --- a/OBSBlur/Window/WindowManager.cs +++ b/OBSBlur/Window/WindowManager.cs @@ -25,7 +25,7 @@ public class WindowManager : IDisposable private bool GetWindowInfo(IntPtr windowHandle, IntPtr lParam) { - WINDOWPLACEMENT windowPlacement = new (); + WindowPlacement windowPlacement = new (); GetWindowPlacement(windowHandle, ref windowPlacement); Rectangle n = windowPlacement.NormalPosition; //Do not add if Window is not a drawable @@ -55,7 +55,7 @@ public class WindowManager : IDisposable [DllImport("user32.dll")] [return: MarshalAs(UnmanagedType.Bool)] - public static extern bool GetWindowPlacement(IntPtr windowHandle, ref WINDOWPLACEMENT lpwndpl); + public static extern bool GetWindowPlacement(IntPtr windowHandle, ref WindowPlacement lpwndpl); [DllImport("user32.dll")] private static extern uint GetWindowThreadProcessId(IntPtr windowHandle, out uint lpdwProcessId); diff --git a/OBSBlur/Window/WindowPlacement.cs b/OBSBlur/Window/WindowPlacement.cs index 5360133..ae1c4b8 100644 --- a/OBSBlur/Window/WindowPlacement.cs +++ b/OBSBlur/Window/WindowPlacement.cs @@ -7,7 +7,7 @@ namespace OBSBlur.Window; /// [Serializable] [StructLayout(LayoutKind.Sequential)] -public struct WINDOWPLACEMENT +public struct WindowPlacement { /// /// The length of the structure, in bytes. Before calling the GetWindowPlacement or SetWindowPlacement functions, set this member to sizeof(WINDOWPLACEMENT). @@ -45,11 +45,11 @@ public struct WINDOWPLACEMENT /// /// Gets the default (empty) value. /// - public static WINDOWPLACEMENT Default + public static WindowPlacement Default { get { - WINDOWPLACEMENT result = new WINDOWPLACEMENT(); + WindowPlacement result = new WindowPlacement(); result.Length = Marshal.SizeOf( result ); return result; }