|
571ff1a3
|
2022-10-30T00:19:09
|
|
wayland: Prepare cursor implementation for reconnect support
Co-authored-by: David Edmundson <kde@davidedmundson.co.uk>
|
|
9c8b1fd8
|
2022-10-29T22:34:05
|
|
wayland: Cleanup work to aid reconnect support
Co-authored-by: David Edmundson <kde@davidedmundson.co.uk>
|
|
4556074e
|
2022-10-29T09:35:07
|
|
Re-set the maximize state if we were maximized while fullscreen
|
|
ab06a307
|
2022-10-29T09:21:17
|
|
Don't report windows being maximized when fullscreen on X11
This is a functional state for some window managers (tested using stock Ubuntu 22.04.1), and removing that state, e.g. using SDL_RestoreWindow(), results in a window centered and floating, and not visually covering the rest of the desktop.
|
|
92215481
|
2022-10-09T19:33:52
|
|
emscripten: Make an attempt at correct keyboard scancode/keycodes.
This uses a newer browser API to get physical scancodes, but still
uses the (deprecated) event field that we were already using for
scancodes, but for keycodes instead now, which appears to be more
accurate.
Since keyboard layout isn't (generally) available to web apps, this
adds an internal interface to send key events with both scancode
and keycode to SDL's internals, instead of sending just scancodes and
expecting SDL to use its own keymap to generate keycodes.
Future work in this area would be to use the keyboard layout APIs
on browsers that support them, which would allow us to use SDL's
usual keymap code and not rely on a deprecated browser API, but
until we get there, this patch gives significantly more correct
results than we would have before.
Fixes #2098.
|
|
b9e1d1b4
|
2022-10-09T19:49:34
|
|
events: Rename SDL_SendKeyboardKeyComplete to SDL_SendKeyboardKeyAndKeycode.+
|
|
f500c147
|
2022-10-28T08:39:02
|
|
Fixed DirectFB build
|
|
9e8d2f39
|
2022-10-27T13:54:53
|
|
video: Don't use texture framebuffer on Windows Subsystem for Linux.
Reference Issue #6333.
|
|
4223e6ac
|
2022-10-26T13:14:50
|
|
wayland: Early-out sooner when requesting fullscreen on a popup
Exit the fullscreen sequence sooner if it is requested that a popup window be fullscreen.
The surface commit formerly in this path is irrelevant and can be removed as previous changes made it so that SetFullscreen() is no longer called from anywhere except Wayland_SetWindowFullscreen().
|
|
41d38c0f
|
2022-10-26T09:43:04
|
|
shape: More robust handling of failure cases in CreateShaper.
|
|
c8d20f96
|
2022-10-25T23:13:34
|
|
shape: Free platform-specific shaped window data.
Fixes #2128.
|
|
30c2dac7
|
2022-10-25T20:00:38
|
|
wayland: Remove duplicate #include statement
|
|
b6cf889a
|
2022-10-25T15:09:43
|
|
Use ScreenCount() instead of SDL_GetNumVideoDisplays()
The limitation appears to be specific to multi-screen setups
|
|
e3f5744d
|
2022-10-25T12:14:00
|
|
Don't use XIWarpPointer() on multi-display configurations
|
|
20beed30
|
2022-10-25T14:56:32
|
|
SDL_EGL_GetProcAddress: remove unnecessary underscore-prepended search.
Closes https://github.com/libsdl-org/SDL/issues/6236.
|
|
053b5f85
|
2022-08-25T20:18:03
|
|
SDL_windowsevents: minimize white screen flash on window creation
Clear the window to black on the initial window draw, to avoid a really
obnoxious white flash. This doesn't always eliminate it, but it
definitely minimizes it.
|
|
d2300516
|
2022-09-07T06:49:02
|
|
cocoa: set sRGB colorspace on nswindow
This makes the colorspace match across different graphics APIs. By
default, OpenGL was getting a much more saturated colorspace (maybe
Display P3?) and it was looking very different from the rendering done
by Metal or MoltenVK.
|
|
019e9d4c
|
2022-08-25T23:15:58
|
|
SDL_cocoavideo.m: add missing SDL_cocoaopengles.h include
|
|
8db3a338
|
2022-10-23T15:45:20
|
|
#6433 Fix WINRT_IsScreenKeyboardShown on Xbox
|
|
413500ab
|
2022-10-22T09:37:34
|
|
Replaced mouseWheelGesture with GCMouse support on iOS (thanks @russelltg!)
Fixes https://github.com/libsdl-org/SDL/issues/6411
|
|
2ebaafa6
|
2022-10-18T21:02:49
|
|
Use translationInView for mouse wheel event
|
|
0e1d19cf
|
2022-10-22T18:56:40
|
|
fix build errors resulting from -Wmisleading-indentation
|
|
a905a786
|
2022-10-22T08:50:18
|
|
Clear the previous bitmap when calculating a new window shape
Fixes https://github.com/libsdl-org/SDL/issues/6428
|
|
7e108816
|
2022-10-18T01:07:54
|
|
Fixed command modifier on macOS
|
|
cdf312c8
|
2022-10-18T00:48:55
|
|
Fixed mouse warp after resizing window on macOS.
|
|
7c7cd2a6
|
2022-10-17T14:04:29
|
|
Fix issue #6037 (incorrect modifier flags on Wayland)
|
|
ed412c13
|
2022-10-15T14:05:35
|
|
wayland: Cleanup event source comments, headers, and error reporting
Replace instances of fprintf(stderr, ...) with SDL_SetError(), replace C++ comments with C style, use a uniform format for multi-line comments, and remove unused headers as poll and select aren't used in this file (the SDL function which calls them is used instead).
|
|
62047686
|
2022-10-13T16:24:13
|
|
wayland: Don't block on libdecor_dispatch()
libdecor_dispatch() needs to be called, as libdecor plugins might do some required internal processing within, however care must be taken to avoid double-blocking in the case of a timeout, which can occur if libdecor_dispatch() and the SDL event processing both work on the main Wayland queue. Additionally, assumptions that libdecor will always dispatch the main queue or not process zero-length queues (can occur if a wait is interrupted by the application queueing an event) should not be made, as this behavior is outside the control of SDL and can change.
SDL handles polling for Wayland events and then calls libdecor to do its internal processing and dispatch. If libdecor operates on the main queue, it will dispatch the queued events and the additional wl_display_dispatch_pending() call will be a NOP. If a libdecor plugin uses its own, separate queue, then the wl_display_dispatch_pending() call will ensure that the main queue is always dispatched.
|
|
e89389ba
|
2022-10-14T20:41:10
|
|
wayland: Use MAP_PRIVATE when mapping the keyboard keymap file descriptor
Per the Wayland spec, this must be mapped with MAP_PRIVATE in version 7 of the protocol and higher.
|
|
91ff8845
|
2022-10-13T23:56:17
|
|
Disable "The key you just pressed is not recognized by SDL." message by default
|
|
13919214
|
2022-10-13T23:23:55
|
|
Fixed reported cases of "Keyboard layout unknown" messages
In all cases they were using SDL_SCANCODE_TABLE_XFREE86_2 with some keycodes remapped or fewer than expected keycodes. This adds a sanity check that catches all of them and gives them the right scancode table.
|
|
2c192385
|
2022-10-13T22:50:57
|
|
Don't remove entries from an existing scancode keymap
If we can't find the X11 keysym, it's likely that either the keysym is NoSymbol, in which case we won't hit it anyway, or it's been mapped to a character, in which case the existing mapping is correct for the scancode and the character will be reflected in the keycode mapping.
|
|
99f2a503
|
2022-10-13T22:40:24
|
|
X11 scancode mapping cleanup
* Consolidated scancode mapping tables into a single location for all backends
* Verified that the xfree86_scancode_table2 is largely identical to the Linux scancode table
* Updated the Linux scancode table with the latest kernel keycodes (still unmapped)
* Route X11 keysym -> scancode mapping through the linux scancode table (which a few hand-written exceptions), which will allow mappings to automatically get picked up as they are added in the Linux scancode table
* Disabled verbose reporting of missing keysym mappings, we have enough data for now
|
|
f5afb7d1
|
2022-10-13T18:44:15
|
|
directfb: Fix return type of DirectFB_RenderPresent()
|
|
6836273d
|
2022-10-12T00:17:50
|
|
Use XIWarpPointer if compiled with xinput2
Co-authored-by: Andrei E <andreien@proton.me>
|
|
be2cb000
|
2022-10-11T11:16:52
|
|
wayland: Check for the input handle before checking the keyboard handle
|
|
0b88e609
|
2022-10-11T07:40:35
|
|
wayland: Raise wl_seat maximum version to 8
Version 8 is required for supporting axis_value120 high-resolution scroll events.
|
|
8117bfe5
|
2022-10-10T22:29:31
|
|
PS2: Ignore warnings from toolchain headers.
The `gsInline.h` header creates `Wdeclaration-after-statement` warnings.
|
|
5ddac7e0
|
2022-10-10T22:04:02
|
|
PSP: Fix type mismatch warnings.
|
|
669532d5
|
2022-10-10T22:01:49
|
|
PSP: Remove dead code.
Fixes unused variable warning.
|
|
45070835
|
2022-10-10T09:39:55
|
|
Fixed build
|
|
680d0f04
|
2022-10-10T09:26:49
|
|
Added support for undefined or centered position for shaped windows
Fixes https://github.com/libsdl-org/SDL/issues/6359
|
|
efc93e68
|
2022-09-18T15:17:08
|
|
N3DS: Don't set `num_display` by hand.
Doing so creates 2 empty displays at the beginning of the list.
|
|
83ec6062
|
2022-09-18T13:46:09
|
|
N3DS: Move gfxInit and hidInit from main to video.
|
|
266014fa
|
2022-09-18T13:38:26
|
|
N3DS: Use SDL_Touch instead of the Joystick touch.
|
|
f9785702
|
2022-09-18T13:22:07
|
|
N3DS: Deduce screen from window's display.
This removes the need for a dedicated window creation flag.
|
|
65527537
|
2021-03-30T04:32:39
|
|
N3DS port (squashed)
A dedicated renderer using Citro3D would likely allow for better
much better graphical performances.
|
|
61b5360e
|
2022-10-10T08:27:42
|
|
Only check to see if the ICC profile changes when the display changes or we gain focus
Fixes https://github.com/libsdl-org/SDL/issues/6366
|
|
6391ad97
|
2022-10-09T11:11:55
|
|
wayland: Factor out common libdecor frame commit code
The pattern of:
libdecor_state_new()
libdecor_frame_commit()
libdecor_state_free()
was used in several places. Factor it out into a common function.
|
|
b0a9396b
|
2022-10-09T11:06:20
|
|
wayland: Remove XDG surface geometry calls
These were needed to fix some buggy behavior regarding committing old buffer sizes when entering fullscreen that has since been corrected. Remove them.
|
|
b91ddbc3
|
2022-10-09T06:15:18
|
|
wayland: null-terminate drop data
|
|
eb8eb621
|
2022-10-06T22:49:17
|
|
SDL_x11modes: fix -Wunused-variable
|
|
4298e798
|
2022-10-06T02:55:30
|
|
SDL_offscreenframebuffer.c: fix format '%d' expecting int instead of Uint32
Emitted by Nintendo 3DS's gcc (fix is same as used by ngage)
|
|
914a65e0
|
2022-10-06T12:39:36
|
|
wayland: Don't unset min/max values when entering fullscreen via a compositor event
If the compositor is entering fullscreen and hasn't removed any constraints itself, it's already too late at this point. Remove the unnecessary call.
Restoring the limits when exiting fullscreen is still required, though, as they may have been removed when entering fullscreen via an SDL request.
|
|
69cf5fb0
|
2022-10-04T13:09:35
|
|
wayland: Remove surface type helpers
These were remnants of a time before the surface type was explicitly stored, so they can be removed per the TODO note.
|
|
c2b0c41c
|
2022-10-04T12:59:26
|
|
wayland: Set/unset the opaque regions on surfaces when transparency is toggled
Caches the SDL_HINT_VIDEO_EGL_ALLOW_TRANSPARENCY hint at init time and registers a callback, which is fired when the hint is changed during runtime and toggles the opaque region for existing surfaces.
|
|
ea595800
|
2022-10-03T18:31:15
|
|
wayland: Set the damage buffer size when supported
The preferred method for setting the damage region on compositor protocol versions 4 and above is to use wl_surface.damage_buffer. Use this when available and only fall back to wl_surface.damage on older versions.
Bumps the highest supported version of wl_compositor to version 4.
|
|
a8cb7bbe
|
2022-10-01T11:31:26
|
|
wayland: Add dedupe logic to window geometry configuration
Adds deduplication logic to ConfigureWindowGeometry() to avoid setting redundant backbuffer, viewport and surface opaque region dimensions. State is now only set when the window and/or backbuffer dimensions change.
This repurposes the viewport rect to always hold the actual size of the window, which can differ from the SDL size if things are being scaled. The SDL_Rect was removed in favor of two ints, as the x/y members of the struct were never used, so they just wasted space.
Since the internal variables always have the true window size, the width/height getter functions are no longer required and can be removed.
|
|
d2160c29
|
2022-10-05T21:42:26
|
|
iOS: implement SDL_GetWindowSizeInPixels.
|
|
92c71ae3
|
2022-10-05T21:59:08
|
|
[iOS] respect initial status bar configuration when displaying the launch storyboard
|
|
5b131364
|
2022-08-06T10:48:53
|
|
[UIKit] handle app lifecycle events in a custom object instead of AppDelegate
removes the need to call SDL counterparts manually when custom AppDelegate is used
|
|
eac3d6d3
|
2022-10-04T10:46:42
|
|
SDL_video.c: fix variable 'i' may be uninitialized when used here "_this->name = bootstrap[i]->name;"
|
|
ad29875e
|
2022-04-18T17:03:05
|
|
Wayland: Emulate mouse warp using relative mouse mode
Several games (including Source and GoldSrc games, and Bioshock
Infinite) attempt to "fake" relative mouse mode by repeatedly warping
the cursor to the centre of the screen. Since mouse warping is not
supported under Wayland, the viewport ends up "stuck" in a rectangular
area.
Detect this case (mouse warp while the cursor is not visible), and
enable relative mouse mode, which tracks the cursor position
independently, and so can Warp successfully.
This is behind the SDL_HINT_VIDEO_WAYLAND_EMULATE_MOUSE_WARP hint, which
is enabled by default, unless the application enables relative mouse
mode itself using SDL_SetRelativeMouseMode(SDL_TRUE).
Note that there is a behavoural difference, in that relative mouse mode
typically doesn't take mouse accelleration into account, but the
repeated-warping technique does, so mouse movement can seem very slow
with this (unless the game has its own mouse accelleration option, such
as in Portal 2).
|
|
9e3c4b9f
|
2022-10-03T17:50:01
|
|
Use the correct platform defines
|
|
f8f562da
|
2022-10-02T22:55:49
|
|
iOS: remove dead pre-iOS 8 codepaths.
SDL hasn't supported those older iOS versions for a little while now.
|
|
bbeacd72
|
2022-10-02T22:57:03
|
|
Fix some credit comments.
|
|
5e654a4b
|
2022-10-01T16:10:46
|
|
Fixed Mac compile errors when OpenGL is disabled.
|
|
28572702
|
2022-09-30T17:25:57
|
|
Properly backspace over text that was entered when autocorrect updates text with the iPhone on-screen keyboard
|
|
e17f0c28
|
2022-09-27T10:59:28
|
|
wayland: Call the Wayland hide/show functions directly when changing decoration modes
Calling SDL_HideWindow() to destroy the window is a NOP if the SDL_WINDOW_SHOWN flag was never set. Bypass it and call the Wayland-specific function directly to ensure that the window is always destroyed before switching from server-side to client-side decorations, even if it hasn't been shown yet.
Likewise, call Wayland_ShowWindow() directly when the window isn't explicitly hidden to ensure that it is always recreated since the SDL_WINDOW_SHOWN flag won't be cleared, which, when set, renders SDL_ShowWindow() a NOP.
|
|
57b5c910
|
2022-09-28T12:38:32
|
|
kmsdrm: only negative devindex's are not allowed
ad874536 removed an unnecessary limit as we *can* have a devindex
greater than 99, this error message does not reflect the support for
values greater than 99.
|
|
a2c57573
|
2022-09-01T10:47:24
|
|
video: check for "software" with SDL_HINT_FRAMEBUFFER_ACCELERATION.
We check for this value elsewhere but not in SDL_CreateWindowFramebuffer.
|
|
57b20e7b
|
2022-09-27T14:23:42
|
|
cocoa: Fix new windows setting SDL_WINDOW_BORDERLESS flag incorrectly.
Fixes #6172.
|
|
d71df644
|
2022-09-27T10:21:15
|
|
Fixed bug #6287 - SDL_FillRect failed for SDL_Surface with BitsPerPixel == 4
|
|
4a06cc0f
|
2022-09-22T13:03:09
|
|
wayland: Apply modifier changes to the text of repeated keys
The text component of a repeated keystroke is initially set when a key is first pressed and the cached value remains static until the repeated key is released and another repeatable key is pressed. If the state of a modifier such as shift or capslock is changed while a key is being repeated, the text emitted will not have the modifier applied to it until the repeated key is released and pressed again.
Update the text to be repeated by a key if a modifier is changed while a key is actively being repeated.
|
|
467c82c7
|
2022-09-23T12:31:40
|
|
wayland: Add mappings for the Escape and NumLock keys
The XKB keysym to SDL keycode mappings were missing for the Escape and NumLock keys, which prevented them from being remapped. Add them to the table so that the remapping of these keys will work.
|
|
5ea9886b
|
2022-09-23T13:19:22
|
|
haiku: Fix when screen color depth was 24 bits, SDL_GetWindowSurface would always fail with 'Unknown pixel format' error
Note that returning SDL_PIXELFORMAT_BGR24 instead of SDL_PIXELFORMAT_RGB24 seems necessary, otherwise when running with SDL_ACCELERATION=0, the red and blue channels of the window appeared swapped.
Note that when running with acceleration enabled, red and blue channel swapping does not happen regardless of whether SDL_PIXEL_FORMAT_RGB24 or SDL_PIXEL_FORMAT_BGR24 is returned.
For good measure, I also tested running with acceleration disabled in both 15 and 16 bit color depths, but red and blue channel swapping did not occur
|
|
399cb2f0
|
2022-09-21T13:20:39
|
|
wayland: Only clear the key repeat flag when the repeated key is released
If multiple keys were simultaneously depressed and one was being repeated, the repeat flag was being cleared when any of the pressed keys were released, even if the released key wasn't the one being repeated.
This tracks the key currently being repeated and only clears the repeat flag when the particular key being repeated is released.
|
|
301912a5
|
2022-09-18T21:25:55
|
|
Fix: Use WIN_ClientPointToSDL for converting additional mouse coordinates
|
|
8598f05b
|
2022-09-17T21:45:08
|
|
Support loading 2bpp .bmp files
|
|
1f7a7fd9
|
2022-09-17T21:30:40
|
|
haiku: Combine HAIKU_ColorSpaceToBitsPerPixel and HAIKU_BPPToSDLPxFormat
|
|
43fc6d59
|
2022-09-08T15:53:54
|
|
Fix incorrect return value in X11_GetPixelFormatFromVisualInfo
|
|
5fba31f6
|
2022-09-17T00:51:00
|
|
SDL_HasPrimarySelectionText: fix -Wunreachable-code-return warning.
|
|
efe01faa
|
2022-09-16T10:08:31
|
|
Replaced Blit4to4CopyAlpha() with optimized SDL_BlitCopy()
Fixes https://github.com/libsdl-org/SDL/issues/6241
|
|
c0baa6bf
|
2022-09-16T20:03:50
|
|
move SDL_windowstaskdialog.h contents into SDL_windowsmessagebox.c
Silences clang -Wpragma warnings:
D:/a/SDL/SDL/src/video/windows/SDL_windowstaskdialog.h:21:10: warning: the current #pragma pack alignment value is modified in the included file [-Wpragma-pack]
#include <pshpack1.h>
^
D:/a/_temp/msys64/clang64/include/pshpack1.h:7:9: note: previous '#pragma pack' directive that modifies alignment is here
#pragma pack(push,1)
^
In file included from D:/a/SDL/SDL/src/video/windows/SDL_windowsmessagebox.c:35:
D:/a/SDL/SDL/src/video/windows/SDL_windowstaskdialog.h:156:10: warning: the current #pragma pack alignment value is modified in the included file [-Wpragma-pack]
#include <poppack.h>
^
note: previous '#pragma pack' directive that modifies alignment is here
2 warnings generated.
Closes: https://github.com/libsdl-org/SDL/issues/6240
|
|
d744aafb
|
2022-09-15T01:00:12
|
|
Added support for simulated vsync in the renderer
This kicks in if the platform doesn't support vsync directly, or if the present fails for some reason (e.g. minimized on some platforms)
Fixes https://github.com/libsdl-org/SDL/issues/5134
|
|
d86cb8ec
|
2022-09-16T17:05:02
|
|
SDL_offscreenwindow.c: swap include order of SDL_egl_c.h/SDL_sysvideo.h
Fixes redefinition warnings from windows builds.
Reference issue: https://github.com/libsdl-org/SDL/issues/6239
|
|
6de15ffc
|
2022-09-15T12:04:08
|
|
Fixed building offscreen video driver without EGL support
Also did miscellaneous style cleanup for consistency with other code
|
|
ac5b9bc4
|
2022-09-14T18:28:35
|
|
Add support for X11 primary selection (#6132)
X11 has a so-called primary selection, which you can use by marking text and middle-clicking elsewhere to copy the marked text.
There are 3 new API functions in `SDL_clipboard.h`, which work exactly like their clipboard equivalents.
## Test Instructions
* Run the tests (just a copy of the clipboard tests): `$ ./test/testautomation --filter Clipboard`
* Build and run this small application:
<details>
```C
#include <SDL.h>
#include <unistd.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
void print_error(const char *where)
{
const char *errstr = SDL_GetError();
if (errstr == NULL || errstr[0] == '\0')
return;
fprintf(stderr, "SDL Error after '%s': %s\n", where, errstr);
SDL_ClearError();
}
int main()
{
char text_buf[256];
srand(time(NULL));
SDL_Init(SDL_INIT_VIDEO);
print_error("SDL_INIT()");
SDL_Window *window = SDL_CreateWindow("Primary Selection Test", SDL_WINDOWPOS_UNDEFINED,
SDL_WINDOWPOS_UNDEFINED, 400, 400, SDL_WINDOW_SHOWN);
print_error("SDL_CreateWindow()");
SDL_Renderer *renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_ACCELERATED);
print_error("SDL_CreateRenderer()");
bool quit = false;
unsigned int do_render = 0;
while (!quit) {
SDL_Event event;
while (SDL_PollEvent(&event)) {
print_error("SDL_PollEvent()");
switch (event.type) {
case SDL_QUIT: {
quit = true;
break;
} case SDL_KEYDOWN: {
switch (event.key.keysym.sym) {
case SDLK_ESCAPE:
case SDLK_q:
quit = true;
break;
case SDLK_c:
snprintf(text_buf, sizeof(text_buf), "foo%d", rand());
SDL_SetClipboardText(text_buf);
print_error("SDL_SetClipboardText()");
printf("clipboard: set_to=\"%s\"\n", text_buf);
break;
case SDLK_v: {
printf("clipboard: has=%d, ", SDL_HasClipboardText());
print_error("SDL_HasClipboardText()");
char *text = SDL_GetClipboardText();
print_error("SDL_GetClipboardText()");
printf("text=\"%s\"\n", text);
SDL_free(text);
break;
} case SDLK_d:
snprintf(text_buf, sizeof(text_buf), "bar%d", rand());
SDL_SetPrimarySelectionText(text_buf);
print_error("SDL_SetPrimarySelectionText()");
printf("primselec: set_to=\"%s\"\n", text_buf);
break;
case SDLK_f: {
printf("primselec: has=%d, ", SDL_HasPrimarySelectionText());
print_error("SDL_HasPrimarySelectionText()");
char *text = SDL_GetPrimarySelectionText();
print_error("SDL_GetPrimarySelectionText()");
printf("text=\"%s\"\n", text);
SDL_free(text);
break;
} default:
break;
}
break;
} default: {
break;
}}
}
// create less noise with WAYLAND_DEBUG=1
if (do_render == 0) {
SDL_RenderPresent(renderer);
print_error("SDL_RenderPresent()");
}
do_render += 1;
usleep(12000);
}
SDL_DestroyRenderer(renderer);
SDL_DestroyWindow(window);
SDL_Quit();
print_error("quit");
return 0;
}
```
</details>
* Use c,v,d,f to get and set the clipboard and primary selection.
* Mark text and middle-click also in other applications.
* For wayland under x:
* `$ mutter --wayland --no-x11 --nested`
* `$ XDG_SESSION_TYPE=wayland SDL_VIDEODRIVER=wayland ./<path_to_test_appl_binary>`
|
|
72fe6cc8
|
2022-09-14T09:14:47
|
|
Updated to the latest version of OpenGL and Vulkan headers from the Khronos registry
Fixes https://github.com/libsdl-org/SDL/issues/6193
|
|
228b9fb5
|
2022-09-14T03:43:16
|
|
Update SDL_windowswindow.c (#6225)
Clip rectangle set to int(left+width/2) , int(top+height/2) , int(left+width/2)+1 , int(top+height/2)+1
a 1x1 box
On even-valued resolution, cursor is stable at bottom-right central pixel
On odd-valued resolution, cursor is stable at exact central pixel.
this is the desired behaviour
|
|
929d5b80
|
2022-09-12T22:39:44
|
|
wayland: Use the backbuffer size for determining if a resize event is required
In some cases, a backbuffer size update may not be accompanied by a resize event if the window size and/or scale were updated before the new backbuffer size was recomputed. Instead of the scale, use the old/new backbuffer sizes to determine if a resize event is required so that a backbuffer size change will always be followed by a resize event.
|
|
edfb00c2
|
2022-09-09T14:26:44
|
|
wayland: Only commit on move if the display was changed
Only commit on a move event if the display was changed for a fullscreen window and the compositor has returned bad dimensions.
|
|
97a5e744
|
2022-09-06T17:08:27
|
|
wayland: Remove duplicate code
Wayland_SetWindowSize() can be simplified with the common CommitWindowGeometry() function.
|
|
78f843f7
|
2022-09-06T13:19:23
|
|
wayland: Remove unnecessary function parameter
SetFullscreen() is never called in a case where the commit parameter is false anymore, so the parameter is unnecessary.
|
|
69e4c770
|
2022-09-04T12:18:38
|
|
video: Make the mode switching function a NOP if mode switching is disabled
Instead of wrapping individual calls to SDL_SetDisplayModeForDisplay(), just check the flag in the function itself and make it a NOP that cannot fail if the flag is set. Silences some errant "SDL video driver doesn't support changing display mode" log errors.
|
|
768b6728
|
2022-09-04T23:39:05
|
|
wayland: Compare against the old scale when resizing
Compare against the old scale instead of the new or the conditional will always be true.
|
|
07aea476
|
2022-09-03T13:30:49
|
|
wayland: Ignore content sizes from libdecor when hiding a window
When hiding a window, libdecor can report bogus content region sizes that are +/- the height of the title bar. Ignore any size values from libdecor when hiding a window, or the size may be incorrect when restored.
|
|
6de12b4a
|
2022-09-06T13:30:19
|
|
wayland: Update the internal state when the compositor moves a fullscreen window
The compositor can arbitrarily move windows between displays, including fullscreen windows. Update the internal state when a fullscreen window is moved so the internal SDL state accurately reflects the window location, and resize the window to fit the new display.
This also fixes an edge case where the compositor can make a window fullscreen on a different display than SDL thinks it will be on (usually when a window is made fullscreen by the compositor while straddling multiple displays), which can result in the window being incorrectly sized.
|
|
a7d34595
|
2022-09-03T13:11:29
|
|
wayland: Trigger a commit on fullscreen update
If additional fullscreen requests are received when the window is already fullscreen, it is typically due to the fullscreen flags or emulated video mode being changed. A commit must be explicitly triggered or the requested changes won't take effect until some other event, such as a resize or focus change, causes the changes to be committed.
|
|
707b561f
|
2022-09-03T12:37:02
|
|
wayland: Enable compositor fullscreen toggling
The compositor can toggle the fullscreen state (via a hotkey or otherwise), so the internal SDL state must be updated accordingly when it does.
When toggling fullscreen via the compositor, SDL will attempt to use the last fullscreen flag explicitly set. If no flag was previously set, SDL_WINDOW_FULLSCREEN will be used if a window video mode was set, otherwise SDL_WINDOW_FULLSCREEN_DESKTOP will be used. If the previous flag was SDL_WINDOW_FULLSCREEN and the window video mode was cleared, it will revert to SDL_WINDOW_FULLSCREEN_DESKTOP.
|