Commit Graph

5240 Commits

Author SHA1 Message Date
Sylvain
87b02d3795
Linux thread name limitation: test for ERANGE (see bug #5283) 2022-02-02 15:09:29 +01:00
Sylvain
220a9596f3
Remove testing instruction (see bug #5283) 2022-02-02 10:01:11 +01:00
Sylvain
9e46a512b1
Fixed bug #5283 - limit thread name to 16 characters when using pthread_setname_np() 2022-02-02 09:58:15 +01:00
Weng Xuetian
b11dfd7611 Only generate key repetition for keys that should repeat on wayland.
This fix repetition on modifier keys, e.g. Control.
2022-02-01 17:56:04 -05:00
Weng Xuetian
a90a2e7582 Fix text_input_v3 preedit string
For every batch of text_input_v3 updates, if there is no preedit in this
batch, preedit should be cleared.
2022-02-01 15:51:26 -05:00
Sam Lantinga
03c4405b3b Fixed D-Bus battery refresh call 2022-02-01 09:33:18 -08:00
Sylvain
d224a63bda
Fix compilation for non Android 2022-02-01 11:34:01 +01:00
Sylvain
fe2ed6cf6f
Fixed bug #5221 - Add SDL_AndroidSendMessage() 2022-02-01 11:30:43 +01:00
pionere
97269e143d adjustments to ime_candidates
- allocate ime_candidates on demand
- allow write to the whole allocated memory of ime_candidates
- ensure ime_candcount is set to zero in case the candidates can not be queried for any reason
2022-01-31 22:06:26 -05:00
pionere
6f404d0f04 cleanup IME_GetCandidateList / UILess_GetCandidateList
- move IME_ShowCandidateList, ImmGetContext and ImmReleaseContext to this function
- set ime_candpgsize to MAX_CANDLIST if dwPageSize is zero
- comment out deselection of ime_candsel in case of korean language for the moment (LANG_CHT does not work anyway)
2022-01-31 22:06:26 -05:00
Sam Lantinga
ec8e3104c8 Refresh the battery state before we query it on Linux 2022-01-31 17:01:08 -08:00
Frank Praznik
0b34f18045 audio: pipewire: Don't double free properties on init failure
The context and stream creation functions will destroy the passed properties object on failure, so no need to do it manually.

The pw_properties_free() function pointer is no longer needed, so it can be removed.
2022-01-30 23:23:03 -05:00
Sylvain
f7d3abddba
Fixed bug #964 - SDL_RenderCopy stretch loses proportion on viewport.
Handle the case when there is blending
2022-01-29 10:19:08 +01:00
pionere
a5c610b0a3 revert 'Changed to use 0xFE instead of 0xFF for better sound quality.' 2022-01-28 20:40:19 -05:00
Ryan C. Gordon
43f0271b4e Revert "fix compiler warnings in SDL_windows_gaming_input.c"
This reverts commit ca36cdb185f2f26241598068927821896f36b904.

The older Windows SDK's headers are wrong, and this change would crash if
you hotplug a device.
2022-01-28 20:40:19 -05:00
pionere
a70bb259c7 drop handle parameter of OpenDevice 2022-01-28 20:40:19 -05:00
pionere
47ddb04e17 cleanup/sync the main loop of *_OpenDevice functions to pick audio format II. 2022-01-28 20:40:19 -05:00
pionere
2eafe4340c cleanup/sync the main loop of *_OpenDevice functions to pick audio format 2022-01-28 20:40:19 -05:00
pionere
3939ef72f8 cleanup SDL_GetAudioDeviceSpec
- drop unnecessary hascapture check
- call SDL_InvalidParamError and return -1 in case the index is out of range
- do not zfill SDL_AudioSpec
- adjust documentation to reflect the behavior
2022-01-28 20:40:19 -05:00
pionere
113109f839 cleanup SDL_GetAudioDeviceName
- drop unnecessary hascapture check
- call SDL_InvalidParamError in case the index is out of range
2022-01-28 20:40:19 -05:00
pionere
f91211eb17 cleanup WASAPI_PrepDevice
- reorganize the loop which checks for the right wave-format
- use the return value of UpdateAudioStream
- ensure SetError is called in SDL_NewAudioStream
2022-01-28 20:40:19 -05:00
pionere
c9e8d1573a re-use return value of SDL_SetError/WIN_SetErrorFromHRESULT/SDL_OutOfMemory II. 2022-01-28 20:40:19 -05:00
pionere
1043dd8c0d adjust handling of iscapture
- drop iscapture parameter of OpenDevice
- use SDL_bool for iscapture
2022-01-28 20:40:19 -05:00
pionere
e2f70a2dff cleanup SDL_EventState 2022-01-28 20:40:19 -05:00
pionere
32c7d5d352 cleanup IME_UpdateInputLocale
- do not store the HKL in a static variable
- always set the ime_candvertical value in case the HKL is changed
2022-01-28 20:40:19 -05:00
pionere
25aa7244dc cleanup IME_GetId
- use assert instead of a check (it is a static function with constant parameter)
- assume it is called with 0 first (simplifies the logic)
- reuse dwLang value instead of a new 'call' to LANG()
2022-01-28 20:40:19 -05:00
pionere
60deadba59 re-use return value of SDL_SetError/WIN_SetErrorFromHRESULT/SDL_OutOfMemory 2022-01-28 20:40:19 -05:00
pionere
ebdd536676 use SDL_InvalidParamError or SDL_assert instead of custom SDL_SetError 2022-01-28 20:40:19 -05:00
pionere
4a17612bff get rid of BeginLoopIteration 2022-01-28 20:40:19 -05:00
pionere
0770c5829c get rid of PrepareToClose 2022-01-28 20:40:19 -05:00
Ryan C. Gordon
e0236c02ce audio: Removed an unnecessary commented-out line. 2022-01-28 20:40:19 -05:00
pionere
0dda8a7f4c cleanup init functions of audio
- use SDL_bool if possible
- assume NULL/SDL_FALSE filled impl
- skip zfill of current_audio at the beginning of SDL_AudioInit (done before the init() calls)
2022-01-28 20:40:19 -05:00
pionere
6fcfcc3d6f get rid of SkipMixerLock 2022-01-28 20:40:19 -05:00
pionere
3c85cef46c cleanup SDL_RegisterApp
- fix memory leak when RegisterClassEx fails
- set style according to the documentation
- eliminate duplicated SDL_Instance setter
2022-01-28 20:40:19 -05:00
pionere
014e2bbdb2 use SDL_COMPILE_TIME_ASSERT instead of SDL_STATIC_ASSERT 2022-01-28 20:40:19 -05:00
pionere
95f30c7a48 fix compiler warnings in video/uikit 2022-01-28 20:40:19 -05:00
pionere
176941a4fb allow MacOS build without SDL_FILE 2022-01-28 20:40:19 -05:00
pionere
eb80f2c65a sync handling of subsystems II. 2022-01-28 20:40:19 -05:00
pionere
942b01a54c do not use RWOps in WIN_SetWindowIcon 2022-01-28 20:40:19 -05:00
pionere
bf66720a4d fix mixing of U16 audio 2022-01-28 20:40:19 -05:00
pionere
905e2e22ef cleanup of SDL_MixAudioFormat 2022-01-28 20:40:19 -05:00
pionere
d7110b4490 fix compiler warnings in SDL_windows_gaming_input.c 2022-01-28 20:40:19 -05:00
pionere
e11ba0f5d9 do not load/unload opengl library when SDL_WINDOW_METAL flag is changed 2022-01-28 20:40:19 -05:00
Sylvain
f5911bdc59 GLES2: disable texcoord when not using it (see bug #5235)
similar to opengl backend code:
- glDisableVertexAttribArray doesn't need to depend on 'drawstate.texture' value
- move binding code to SetCopyState()
2022-01-28 19:25:40 +01:00
Sylvain
096fe37bb2 GLES2: revert 7bf8c5a388 2022-01-28 19:25:40 +01:00
Sylvain
a988ce5544
Fixed bug #964 - SDL_RenderCopy stretch loses proportion on viewport boundaries 2022-01-28 17:24:59 +01:00
Sylvain
7bf8c5a388 GLES2: disable texcoord when not using it (see bug #5235) 2022-01-27 21:49:05 -05:00
Vitaliy Zhmurikov
5b74459255 Update SDL_joystick.c
Add Logitech Momo Racing Wheel VID & PID  to SDL_IsJoystickProductWheel function
2022-01-27 12:30:41 -08:00
Ryan C. Gordon
19ae71b2db
video: Don't add SDL_WINDOW_(METAL|OPENGL) to new windows if unsupported.
Fixes #4656.

(Better than the previous fix in 3044310518dbb2d4814b32c6521f332b8d69aae5.)
2022-01-27 11:49:15 -05:00
Ivan Epifanov
d7e0c54dde PSVita: send initial SDL_JOYDEVICEADDED events 2022-01-27 08:47:53 -08:00