Sam Lantinga
cef1514b01
Fixed some Xcode warnings
2022-07-17 09:07:04 -07:00
Ozkan Sezer
2201d80255
avoid -Werror=declaration-after-statement after last commit.
2022-07-14 02:40:00 +03:00
freebsd
24b3efd08d
(OpenBSD) Exe Path: Use PWD instead of CWD and use CWD as fallback
2022-07-13 16:24:20 -07:00
Francisco Javier Trujillo Mata
7d7c5b803c
Improving mkdir creating parents folder
2022-07-03 09:23:34 -07:00
chalonverse
f317d619cc
Xbox GDKX support ( #5869 )
...
* Xbox GDK support (14 squashed commits)
* Added basic keyboard testing
* Update readme
* Code review fixes
* Fixed issue where controller add/removal wasn't working (since the device notification events don't work on Xbox, have to use the joystick thread to poll XInput)
2022-07-01 13:59:14 -07:00
Pierre Wendling
6c536afdb7
Fix C89 declaration for macOS modules.
...
Since Clang 14, `-Wdeclaration-after-statement` is enforced on every
standard.
2022-06-27 15:19:40 -07:00
Francisco Javier Trujillo Mata
6b03c1adf6
Add filesystem driver
2022-06-15 15:15:26 -07:00
Sam Lantinga
aa6ea607d9
Fixed whitespace
...
Whitespace inconsistencies reported in https://github.com/libsdl-org/SDL/pull/5673
2022-05-18 06:58:14 -07:00
pionere
009a0ff95f
use explicit GetModuleFileNameW
2022-04-18 14:12:22 -04:00
pionere
de711e1685
simplify SDL_GetBasePath on windows
...
- use GetModuleFileName directly (as recommended)
2022-04-18 14:12:22 -04:00
Ozkan Sezer
dfbe1f7248
SDL_GetBasePath() fixes for OS/2
2022-03-17 03:50:02 +03:00
Ozkan Sezer
df1474b46e
psp/SDL_sysfilesystem.c: fixed a minor compiler warning.
...
src/filesystem/psp/SDL_sysfilesystem.c: In function 'SDL_GetPrefPath':
src/filesystem/psp/SDL_sysfilesystem.c:71: warning: passing argument 1 of 'free' discards qualifiers from pointer target type
2022-01-08 11:55:10 +03:00
Wouter Wijsman
6d46e30fed
Remove extra / in PSP GetPrefPath
2022-01-05 08:29:35 -08:00
Wouter Wijsman
33dccbb381
Make sure GetPrefPath also works without org
2022-01-05 08:29:35 -08:00
Sam Lantinga
120c76c84b
Updated copyright for 2022
2022-01-03 09:40:21 -08:00
Francisco Javier Trujillo Mata
13a9cd4797
Adding sysfilesystem driver to PSP
2022-01-02 08:06:04 -08:00
Ozkan Sezer
8d14e6ea44
replaced use of _MAX_PATH with CCHMAXPATH in os/2 code,
...
it now compiles without HAVE_LIBC
2021-12-08 14:01:02 +03:00
Sylvain
aef7105408
Use SDL_free
2021-11-22 08:38:46 -08:00
Sylvain
30338beb61
Minor comment
2021-11-22 08:38:46 -08:00
Sylvain
d31251b014
use SDL's functions version inplace of libc version
2021-11-22 08:38:46 -08:00
Cameron Cawley
9ee6942e79
Improve RISC OS implementations of SDL_GetBasePath and SDL_GetPrefPath
2021-10-12 13:07:52 -07:00
Cameron Cawley
3db898c5b6
riscos: Implement SDL_GetPrefPath()
2021-10-12 13:07:52 -07:00
Sam Lantinga
345c161feb
Fixed some accidental uses of external C runtime functions
2021-09-22 09:06:45 -07:00
Phillip Trudeau
bc7ac134db
Windows: Fix SDL_GetBasePath() truncating paths
...
SDL_GetBasePath grows its path buffer for long paths, but GetModuleFileNameExW always truncates and succeeds,
so `len` was always equal to (buflen - 1) which is 127. This is easily fixed by checking for (buflen - 1) instead of buflen.
For paths longer than MAX_PATH, this problem sometimes got hidden by Windows path shortening ("C:\PROGRA~1\" etc.).
Tested on Windows 10 x64 19041 and 10586.
2021-06-12 23:07:46 -04:00
Ryan C. Gordon
03503423e9
filesystem: Better OpenBSD support for SDL_GetBasePath().
...
Fixes #3752 .
2021-04-19 23:32:45 -04:00
Ivan Epifanov
e58a955e68
Deprecate dolcesdk
2021-03-08 09:07:12 -08:00
Ivan Epifanov
ca5e5d6154
VITASDK compatibility
2021-03-08 09:07:12 -08:00
Ivan Epifanov
194c813893
Fix filesystem
2021-03-08 09:07:12 -08:00
Ivan Epifanov
41d6c80b07
Filesystem module
2021-03-08 09:07:12 -08:00
Cameron Cawley
391bb80bb9
Replace duplicate functions and lstrlen/lstrcat with SDL string functions
2021-03-05 12:03:58 -08:00
Charlie Birks
1a48ca666f
emscripten: Create directory recursively in GetPrefPath
2021-02-13 11:56:01 -05:00
Ozkan Sezer
265a1cc97a
use WIN_StringToUTF8W instead of WIN_StringToUTF8 where needed ( #2 )
...
cf. bug #5435 .
- SDL_wasapi_win32.c (GetWasapiDeviceName): pwszVal is WCHAR*
- windows/SDL_sysfilesystem.c (SDL_GetBasePath, SDL_GetPrefPath)
- windows/SDL_sysurl.c (SDL_SYS_OpenURL): wurl is WCHAR*
- SDL_windowssensor.c (ConnectSensor): bstr_name is WCHAR*
- windows/SDL_systhread.c (SDL_SYS_SetupThread): strw is WCHAR*
2021-01-05 15:50:02 +03:00
Ozkan Sezer
01a2f27679
consistently use TEXT() macro with LoadLibrary() and GetModuleHandle()
...
cf. bug #5435 .
2021-01-04 01:23:50 +03:00
Sam Lantinga
9130f7c377
Updated copyright for 2021
2021-01-02 10:25:38 -08:00
Ethan Lee
f1c7cc710b
winrt: Buildfix for older UWP SDKs
2020-12-14 12:36:04 -05:00
Ethan Lee
169cfe5a7c
winrt: EffectiveLocation still needs an ifdef, IsApiContractPresent is for runtime
2020-12-14 11:52:09 -05:00
Sam Lantinga
cb36189692
Fixed bug 5235 - All internal sources should include SDL_assert.h
...
Ryan C. Gordon
We should really stick this in SDL_internal.h or something so it's always available.
2020-12-09 07:16:22 -08:00
Ethan Lee
a7d91ebaa5
winrt: Add EffectiveLocation support for newer Win10 releases
2020-11-09 17:05:21 -05:00
Ozkan Sezer
a90f0400a5
os2: a _lot_ of coding style cleanup, sot that they match the SDL style.
...
also renamed the 'debug' macro to debug_os2: the former was dangerously
a common name.
the binary (dll) output is precisely the same as before.
2020-10-15 21:37:30 +03:00
Ozkan Sezer
1d9cf23e4c
os2: updated copyright dates for 2020. header guard fixes.
2020-10-14 23:01:05 +03:00
Ozkan Sezer
5d89217f6b
os2/SDL_sysfilesystem.c: fix crash if one of the parameters is NULL
...
Has been happening with testfilesystem from 2.0.6 and newer because
of commit 572a721879ef.
Also set error strings in certain error conditions.
Also applied coding style / whitespace fixes, while I was there.
2020-10-14 23:01:03 +03:00
Ozkan Sezer
5f3f67b16b
os2/SDL_sysfilesystem.c: use OS/2 api DosCreateDir() instead of mkdir().
...
mkdir() from watcom and emx differ - the latter being unix-ish, so this
change avoids ifdefs.
2020-10-14 23:01:03 +03:00
Ozkan Sezer
aa790837eb
os2: several warning fixes.
...
mostly those "W007: '&array' may not produce intended result" warnings
from Watcom, visible only in C++ mode. one or two others here & there.
2020-10-14 23:01:02 +03:00
Ozkan Sezer
74cfb81dbb
os2: add port files for SDL2-2.0.4 from Andrey Vasilkin
...
only geniconv/iconv.h (was from LGPL libiconv) is replaced with a generic
minimal iconv.h based on public knowledge.
2020-10-14 23:01:00 +03:00
Sam Lantinga
b6afbe6317
Added SDL_log.h to SDL_internal.h so logging is available everywhere
2020-04-07 09:38:57 -07:00
Sam Lantinga
a8780c6a28
Updated copyright date for 2020
2020-01-16 20:49:25 -08:00
Sylvain Becker
b458d7a28f
Readability: remove redundant cast to the same type
2019-10-30 15:13:55 +01:00
Sam Lantinga
e954e32b0e
Fixed bug 4726 - Fix for tvOS GetPrefPath
...
Caleb Cornett
Unlike iOS and macOS, tvOS does not have any persistent local storage. In fact, the ApplicationSupport directory pointed to by the existing Cocoa GetPrefPath() throws an error whenever any attempt is made to access it. To get any local storage on an Apple TV, our only option is to use a temporary cache directory.
This patch changes the tvOS PrefPath to this cache directory and also logs a critical warning that this if developers want their save data to persist across game sessions, they must use some form of iCloud storage.
2019-07-18 19:33:17 -07:00
Sam Lantinga
5e13087b0f
Updated copyright for 2019
2019-01-04 22:01:14 -08:00
sezero
40b27fd51b
revert the recent typecast assignment changes (see bug #4079 )
...
also change the void* typedefs for the two vulkan function
pointers added in vulkan_internal.h into generic function
pointer typedefs.
2018-02-12 17:00:00 +03:00