mirror of
https://github.com/raysan5/raylib.git
synced 2025-09-13 06:48:15 +00:00
Reviewed window initialization
In case graphic device could not be created it returns false instead of failing with an error tracelog (and consequently closing the program). Window initialization success could be checked with new function IsWindowReady()
This commit is contained in:
@@ -684,8 +684,9 @@ extern "C" { // Prevents name mangling of functions
|
||||
//------------------------------------------------------------------------------------
|
||||
|
||||
// Window-related functions
|
||||
RLAPI bool InitWindow(int width, int height, void *data); // Initialize window and OpenGL context
|
||||
RLAPI void InitWindow(int width, int height, void *data); // Initialize window and OpenGL context
|
||||
RLAPI void CloseWindow(void); // Close window and unload OpenGL context
|
||||
RLAPI bool IsWindowReady(void); // Check if window has been initialized successfully
|
||||
RLAPI bool WindowShouldClose(void); // Check if KEY_ESCAPE pressed or Close icon pressed
|
||||
RLAPI bool IsWindowMinimized(void); // Check if window has been minimized (or lost focus)
|
||||
RLAPI void ToggleFullscreen(void); // Toggle fullscreen mode (only PLATFORM_DESKTOP)
|
||||
|
Reference in New Issue
Block a user