From bc3eb506bdc804e385a6f951c1227537969bd6e4 Mon Sep 17 00:00:00 2001
From: MrScautHD <65916181+MrScautHD@users.noreply.github.com>
Date: Sat, 19 Aug 2023 22:59:08 +0200
Subject: [PATCH] Fixed ConfigFlags
---
Raylib-cs/types/Window.cs | 11 +++++------
1 file changed, 5 insertions(+), 6 deletions(-)
diff --git a/Raylib-cs/types/Window.cs b/Raylib-cs/types/Window.cs
index d6cae9e..bc758eb 100644
--- a/Raylib-cs/types/Window.cs
+++ b/Raylib-cs/types/Window.cs
@@ -7,8 +7,9 @@ public class Window : IDisposable
{
private static Window _instance;
- private Window(int width, int height, string title)
+ private Window(ConfigFlags flags, int width, int height, string title)
{
+ Raylib.SetConfigFlags(flags);
Raylib.InitWindow(width, height, title);
_instance = this;
}
@@ -16,13 +17,14 @@ public class Window : IDisposable
///
/// Gets an instance of the Window or creates a new one if it doesn't exist.
///
+ /// The configuration flags for the window.
/// The width of the window.
/// The height of the window.
/// The title of the window.
/// An instance of the Window.
- public static Window Instance(int width, int height, string title)
+ public static Window Instance(ConfigFlags flags, int width, int height, string title)
{
- return _instance ?? new Window(width, height, title);
+ return _instance ?? new Window(flags, width, height, title);
}
/// See
@@ -63,9 +65,6 @@ public class Window : IDisposable
/// See
public bool SetState(ConfigFlags state) => Raylib.SetWindowState(state);
- /// See
- public void SetConfigFlag(ConfigFlags state) => Raylib.SetConfigFlags(state);
-
/// See
public void ClearState(ConfigFlags state) => Raylib.ClearWindowState(state);