feat(console): add ConsoleDeviceExists

This commit is contained in:
Tristan Cormier authored and fallenoak committed 2025-11-04 10:46:55 -06:00
1 parent 300d6b2f29
commit a64ab82e41
2 files changed
+8 -1

No files matched your search

+6 -1
View File
@@ -6,6 +6,7 @@
#include "gx/Device.hpp"
#include <cstring>
static CGxDevice* s_device;
CVar* s_cvGxMaximize;
CVar* s_cvGxResolution;
CVar* s_cvGxWidescreen;
@@ -198,7 +199,7 @@ void ConsoleDeviceInitialize(const char* title) {
api = GxApi_GLL;
#endif
CGxDevice* device = GxDevCreate(api, OsWindowProc, format);
s_device = GxDevCreate(api, OsWindowProc, format);
// TODO
@@ -207,3 +208,7 @@ void ConsoleDeviceInitialize(const char* title) {
// TODO
}
int32_t ConsoleDeviceExists() {
return s_device != nullptr;
}
+2
View File
@@ -9,4 +9,6 @@ struct DefaultSettings {
void ConsoleDeviceInitialize(const char* title);
int32_t ConsoleDeviceExists();
#endif