mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-05-16 09:48:26 +00:00
Added SDL_GetWindowSafeArea()
Fixes https://github.com/libsdl-org/SDL/issues/3243
This commit is contained in:
parent
1c4cc2b024
commit
457ca3995c
16 changed files with 147 additions and 1 deletions
|
@ -1614,6 +1614,14 @@ static void SDLTest_PrintEvent(const SDL_Event *event)
|
|||
SDL_Log("SDL EVENT: Window %" SDL_PRIu32 " changed pixel size to %" SDL_PRIs32 "x%" SDL_PRIs32,
|
||||
event->window.windowID, event->window.data1, event->window.data2);
|
||||
break;
|
||||
case SDL_EVENT_WINDOW_SAFE_AREA_CHANGED: {
|
||||
SDL_Rect rect;
|
||||
|
||||
SDL_GetWindowSafeArea(SDL_GetWindowFromID(event->window.windowID), &rect);
|
||||
SDL_Log("SDL EVENT: Window %" SDL_PRIu32 " changed safe area to: %d,%d %dx%d\n",
|
||||
event->window.windowID, rect.x, rect.y, rect.w, rect.h);
|
||||
break;
|
||||
}
|
||||
case SDL_EVENT_WINDOW_MINIMIZED:
|
||||
SDL_Log("SDL EVENT: Window %" SDL_PRIu32 " minimized", event->window.windowID);
|
||||
break;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue