video: Rename 'state_not_floating' to the more descriptive 'tiled'

This commit is contained in:
Frank Praznik 2024-05-23 10:26:36 -04:00
parent 37672f52da
commit b1061a3ec1
No known key found for this signature in database
3 changed files with 7 additions and 7 deletions

View File

@ -72,7 +72,7 @@ int SDL_SendWindowEvent(SDL_Window *window, SDL_EventType windowevent,
window->windowed.x = data1;
window->windowed.y = data2;
if (!(window->flags & SDL_WINDOW_MAXIMIZED) && !window->state_not_floating) {
if (!(window->flags & SDL_WINDOW_MAXIMIZED) && !window->tiled) {
window->floating.x = data1;
window->floating.y = data2;
}
@ -88,7 +88,7 @@ int SDL_SendWindowEvent(SDL_Window *window, SDL_EventType windowevent,
window->windowed.w = data1;
window->windowed.h = data2;
if (!(window->flags & SDL_WINDOW_MAXIMIZED) && !window->state_not_floating) {
if (!(window->flags & SDL_WINDOW_MAXIMIZED) && !window->tiled) {
window->floating.w = data1;
window->floating.h = data2;
}

View File

@ -70,10 +70,10 @@ struct SDL_Window
*/
SDL_Rect floating;
/* Toggle for drivers to indicate that the current window state is
* not floating, but may not have any fixed-size flags (e.g. tiled)
/* Toggle for drivers to indicate that the current window state is tiled,
* and sizes set non-programmatically shouldn't be cached.
*/
SDL_bool state_not_floating;
SDL_bool tiled;
/* Whether or not the initial position was defined */
SDL_bool undefined_x;

View File

@ -859,7 +859,7 @@ static void handle_configure_xdg_toplevel(void *data,
wind->floating = floating;
wind->suspended = suspended;
wind->active = active;
window->state_not_floating = tiled;
window->tiled = tiled;
if (wind->surface_status == WAYLAND_SURFACE_STATUS_WAITING_FOR_CONFIGURE) {
wind->surface_status = WAYLAND_SURFACE_STATUS_WAITING_FOR_FRAME;
@ -1191,7 +1191,7 @@ static void decoration_frame_configure(struct libdecor_frame *frame,
wind->floating = floating;
wind->suspended = suspended;
wind->active = active;
window->state_not_floating = tiled;
window->tiled = tiled;
/* Calculate the new window geometry */
ConfigureWindowGeometry(window);