Frank Praznik
800c35a2c1
dialog: Don't potentially call SDL_free() on an uninitialized value
2024-06-26 21:56:40 -04:00
Frank Praznik
596651f13a
dialog: Decodes percent encoded URI paths returned by the xdg file portal
2024-06-26 21:31:35 -04:00
Semphris
8c8ee2174d
Dialog: Add filter number, remove NULL termination
2024-06-03 18:22:26 -07:00
Sam Lantinga
a5b0041b4a
Fixed SDL_strncmp() logic in portal dialog code
...
Also removed redundant calls to SDL_strlen()
Fixes https://github.com/libsdl-org/SDL/issues/9899
2024-05-27 07:46:58 -07:00
Semphris
3acca27e95
Dialog: XDG Portals: Remove the file:// URI
2024-05-23 12:54:39 -07:00
Ryan C. Gordon
0ec716819e
thread: Reworked SDL_CreateThread to be consistent across platforms.
...
Also documented missing and weird bits, rename typedefs to fit SDL standards.
2024-05-22 11:39:43 -04:00
Sam Lantinga
cb416922e3
Fixed compiling with WIN32_LEAN_AND_MEAN
...
Fixes https://github.com/libsdl-org/SDL/issues/9766
2024-05-12 16:00:21 -07:00
Cyao
d4ce9183b8
Update SDL_portaldialog.c
...
Do not throw error when quitting with escape or closing the window
2024-05-12 09:41:13 -07:00
Ozkan Sezer
e909c0360f
remove most of SDL_OutOfMemory() calls where SDL is the allocator.
...
Since commit 447b508a77 , SDL_malloc,
SDL_calloc, and SDL_realloc already calls SDL_OutOfMemory().
2024-05-08 20:00:50 +03:00
Semphris
0411633bb2
Fixes and improvements for dialogs
2024-05-08 09:08:43 -07:00
Miku AuahDark
86fada6faa
Android: Implement open and save file dialog.
2024-05-06 09:33:48 -07:00
Semphris
4ac8968f65
Fix improper handling of NULL dialog filter on Cocoa
2024-05-02 10:18:31 -07:00
Semphris
2b7af6636f
Fix dialogs on Windows
...
This fixes a bunch of issues with dialogs on Windows.
- Removed lpstrFileTitle assignation, which overwrote the buffer
- Increased the memory size available for long file selections
- Removed seemingly unused `default_folder` in win_Args struct
- Properly handle the case where only one file is selected in multiselect mode
- Properly handle the initial folder, which would fail in specific conditions
The details for the last entry are explained in a comment in the code.
2024-04-30 10:17:46 -07:00
devon-artmeier
9c65738926
dialog: Use size_t for length variables ( #9572 )
...
Shuts up a warning about size differences.
2024-04-18 09:09:10 -07:00
Ryan C. Gordon
bc6ad3ee43
dialog: convert_ext_list had parameter names in wrong order in header.
2024-04-17 21:45:51 -04:00
DevonArtmeier
65a04a772e
dialog: Allocate space for terminator when building filter string
2024-04-16 14:09:18 -07:00
Sam Lantinga
a00669db18
Fixed warning C4267: 'initializing': conversion from 'size_t' to 'int', possible loss of data
2024-04-15 10:29:45 -07:00
meyraud705
db9b4ba2fa
Fix memory leak in dialog
2024-04-15 03:23:52 -10:00
Semphris
6ad390fc50
File dialog improvements
...
- Add a globally-accessible function to handle the parsing of filter extensions
- Remove the ability of putting the wildcard ('*') among other patterns; it's either a list of patterns or a single '*' now
- Add a hint to select between portals and Zenity on Unix
2024-04-04 22:07:14 -07:00
Sean Ridenour
feebb9fcf8
Fix file selection dialog boxes not working on macOS 11.0+
2024-04-01 07:38:05 -07:00
Sam Huang
a9cab01185
Don't change cwd with file dialogs
2024-03-31 12:50:29 -07:00
Semphris
335fa5d6e4
Disable SDL dialogs for tvOS and iOS
2024-03-29 23:13:15 -07:00
Mykola Rubets
fc053fb499
Fix OpenFolder dialog behavior on Windows
2024-03-24 11:44:16 -07:00
Sam Lantinga
491f18eea3
Fixed uninitialized signal_id
...
Also removed unnecessary SDL_OutOfMemory() calls
Fixes https://github.com/libsdl-org/SDL/issues/9300
2024-03-18 09:12:51 -07:00
Frank Praznik
ebb6582534
wayland: Handle the toplevel export property as a string
...
xdg-toplevel export handles are strings, so treat the property as one. Avoids the need to manually manage the string pointer.
2024-03-18 11:41:02 -04:00
Frank Praznik
ea60c2079b
dialog: Pass the Wayland or X11 parent window handle to the file dialog portal
...
Pass the Wayland window export string in the form "wayland:<handle string>" or the X11 window XID in the form "x11:<XID in hex>" to the file dialog portal, so that the window manager can associate the dialog with the parent window and position it correctly.
2024-03-15 18:30:05 -04:00
Frank Praznik
d523cd069f
dialog: Detect if the file chooser portal is available
...
Use the introspection method to detect if the file chooser portal is available.
2024-03-15 18:30:05 -04:00
Semphris
70c2e15615
Add file dialogs
2024-03-14 15:40:25 -07:00