added member var for the window flags to the window class

This commit is contained in:
2026-04-15 10:15:08 +02:00
parent ccbc79d496
commit ec5d5af43e
2 changed files with 4 additions and 2 deletions

View File

@@ -1,12 +1,11 @@
#include "Window.h"
#include "Application.h"
#include "InputEvents.h"
#include "Log.h"
#include "SDL3/SDL_events.h"
#include "SDL3/SDL_mouse.h"
#include "SDL3/SDL_video.h"
#include "WindowEvents.h"
#include <span>
namespace SakuraVNE {
Window::Window(const WindowData &data) : m_Data(data) {}
@@ -19,6 +18,8 @@ bool Window::Create(std::span<const SDL_WindowFlags> flags) {
windowFlags |= flag;
}
*m_Flags = windowFlags;
m_Handle = SDL_CreateWindow(m_Data.title.c_str(), m_Data.width, m_Data.height, windowFlags);
if (!m_Handle) {

View File

@@ -47,6 +47,7 @@ public:
private:
WindowData m_Data;
SDL_Window *m_Handle = nullptr;
SDL_WindowFlags *m_Flags = nullptr;
float *m_MouseXPos = nullptr;
float *m_MouseYPos = nullptr;
};