Sam Lantinga
8bb9fc0467
Ensure we wait on the surface resize before returning from setting fullscreen mode.
2018-09-28 20:39:57 -07:00
Sam Lantinga
00aad31722
Fixed bug 4270 - Android HIDDeviceManager function needs to be public
...
Sylvain
Can't run an android app without declaring the JNI interface function as public.
2018-09-25 20:11:52 -07:00
Sam Lantinga
018357cfcc
Fixed rare null pointer dereference
2018-09-24 20:31:24 -07:00
Sam Lantinga
175f9bc0e2
Support relative mouse for Samsung DeX on Samsung Experience 9.5 or later (Android 8.1 or later)
2018-09-24 11:53:04 -07:00
Sam Lantinga
70b54e55ba
Fixed NullPointerException if there's no singleton
2018-09-17 12:08:05 -07:00
Sam Lantinga
393f3ab5c4
Guard against Steam Controller input when we're shutting down.
2018-09-14 18:31:03 -07:00
Sam Lantinga
1c88fc1cbf
Fixed bug 4002 - Android, nativeRunMain() fails on some phone with arm64-v8a
...
Sylvain
The issue is totally reproducible on P8 Lite.
"The dlopen() call doesn't include the app's native library directory. The behavior of dlopen() by Android is not guaranteed".
Workaround in getMainSharedObject()
Just replace
return library;
with
return getContext().getApplicationInfo().nativeLibraryDir + "/" + library;
2018-09-05 15:54:46 -07:00
Sam Lantinga
7ac9576351
Implement SDL_HapticStopEffect on Android (thanks Rachel!)
2018-08-24 10:41:57 -07:00
Sam Lantinga
3020a91dba
Implemented SDL_GetDisplayOrientation() on Android (thanks Rachel!)
2018-08-23 14:05:25 -07:00
Sam Lantinga
abed52cd4a
Don't crash if the app doesn't have Bluetooth permissions
2018-08-21 11:59:13 -07:00
Sam Lantinga
ce26218414
Add SDL_IsTablet() to Android and iOS SDL.
2018-08-21 11:23:47 -07:00
Sam Lantinga
09b42932bc
Don't crash if the app doesn't have Bluetooth permissions
2018-08-21 11:07:56 -07:00
Sam Lantinga
f76036a5b8
Fixed Android build error
2018-08-21 10:37:26 -07:00
Sam Lantinga
02498210e3
The MINIX NEO-U1 is now being reported as Android TV
2018-08-09 16:04:25 -07:00
Sam Lantinga
a7f26f9e6c
Added HIDAPI joystick drivers for more consistent support for Xbox, PS4 and Nintendo Switch Pro controller support across platforms.
...
Added SDL_GameControllerRumble() and SDL_JoystickRumble() for simple force feedback outside of the SDL haptics API
2018-08-09 16:00:17 -07:00
Sam Lantinga
0b0fb478b6
Clean up captured pointer code to avoid logcat clutter on pre-8.0 systems (thanks Rachel!)
2018-07-13 12:55:50 -07:00
Sam Lantinga
b5aa40ef52
Allow trapping the back button so right mouse click can work on some Android systems (thanks Rachel!)
...
Also, added a function SDL_AndroidBackButton() so applications can respond to the back button directly
2018-07-12 13:28:13 -07:00
Sam Lantinga
1b23f13ffe
Added support for external mouse in Samsung DeX mode
...
relative mode doesn't work, but absolute coordinates are functional
2018-06-18 13:14:02 -07:00
Sam Lantinga
7a11c8c485
Make certain we only hide system UI when we're fullscreen for real. (thanks Rachel!)
2018-06-18 13:14:00 -07:00
Sam Lantinga
263a8707e6
Deal with situations where the system UI is shown when the keyboard pops up (thanks Rachel!)
2018-06-18 13:13:58 -07:00
Sam Lantinga
02b611aa15
SDL Android fullscreen code extensively tested on Steam Link with no issues reported
2018-06-13 14:24:30 -07:00
Sam Lantinga
af64f3405e
Don't crash on exit from SDLActivity if we don't have a singleton for some reason. (Thanks Rachel!)
2018-06-07 17:07:05 -07:00
Sam Lantinga
43be720699
Track android device panel width & height as well as window surface & height.
...
Expand SDLActivity::SDLSurface::surfaceChanged() callback to grab the panel width and height at the same time and pass that along to the native code. Only works on API 17+. Duplicates surface dimensions whenever it fails.
Add Android_DeviceWidth/Android_DeviceHeight globals to native code.
Disambiguate Android_ScreenWidth/Android_ScreenHeight -> Android_SurfaceWidth/Android_SurfaceHeight
Use device width/height for all display mode settings.
2018-06-07 17:07:03 -07:00
Sam Lantinga
788a386710
Added Android hardware feature support to the default manifest
2018-06-06 09:42:12 -07:00
Sam Lantinga
f136438f71
Added improved mouse pointer capture under API 26. (Thanks Rachel!)
2018-06-05 14:08:39 -07:00
Sam Lantinga
af2e341ea6
Added SDL_IsChromebook() to determine if we're running on a Chromebook.
2018-06-05 12:46:13 -07:00
Sam Lantinga
a3a46e3084
Added support for Android relative mouse mode on API 24 and above
2018-05-29 11:18:01 -07:00
Sam Lantinga
c25dc3a5a4
Better fix for axis sorting with some Android controllers
2018-05-23 17:15:35 -07:00
Sam Lantinga
84b38f9ecf
Reimplemented Android cursor API support using reflection so it builds with older SDKs
2018-03-16 11:08:53 -07:00
Sam Lantinga
e99c0c8b98
Added Android custom cursor implementation
...
This is commented out in SDLActivity.java, with the note #CURSORIMPLEENTATION because it requires API 24, which is higher than the minimum required SDK
2018-03-15 18:22:48 -07:00
Sam Lantinga
542e3d764e
Try to dynamically create a default Android game controller mapping based on the buttons and axes on the controller.
...
Include the controller USB VID/PID in the GUID where possible, as we do on other platforms.
2018-03-06 14:51:50 -08:00
Sam Lantinga
47c07044ad
Temporarily disabled fullscreen switching code on Android, until we can resolve bug 4096 - Enabling fullscreen on Android causes the app to toggle fullscreen mode continuously in a loop
2018-03-01 08:22:56 -08:00
Sam Lantinga
6fcd640364
On Android show the system UI when an SDL window is windowed, hide the system UI when it's fullscreen, like we do on iOS.
...
We're increasing the Android SDK minimum version to API 19, this doesn't increase the minimum target API, which is API 14.
2018-02-11 18:23:37 -08:00
Sam Lantinga
f1e0f8998a
Fixed bug 4021 - Android, hard-coded Keycode value
...
Sylvain
There is an hard-coded keycode value in SDLActivity.java
2018-02-07 15:10:50 -08:00
Sam Lantinga
2c08c2b899
Added SDL_IsAndroidTV()
2018-02-06 15:03:35 -08:00
Sam Lantinga
e7ea3f1100
Fixed bug 4001 - Android, prevent error message box to crash
...
Sylvain
Prevent the error message box to crash after being clicked.
Because of "SDLActivity.mSingleton.finish();"
2017-12-19 11:19:10 -08:00
Sam Lantinga
ef7a48c03e
Fixed bug 4004 - iOS: don't hide keyboard on RETURN
...
Dominik Reichardt
As discussed in 2012 the iOS onscreen keyboard hides when you hit RETURN (see https://discourse.libsdl.org/t/on-screen-keyboard-change/19216 ).
IMO this is a bad idea to not be able to influence this behavior and just recently this was fixed for Android by adding the hint SDL_HINT_ANDROID_RETURN_HIDES_IME in changeset 11768 0f2fb9ec6ad6.
2017-12-19 10:57:21 -08:00
Sam Lantinga
46de6618ab
Add the ability to set SDL to handle Return as 'hide IME' on Android softkeyboard. (thanks Rachel!)
2017-12-12 12:52:23 -08:00
Sam Lantinga
605298f114
Fixed Android build error on older SDK
2017-11-12 10:59:05 -08:00
Sam Lantinga
8fc8354b07
Fixed bug 3917 - Android, issues with getManifestEnvironmentVariable
...
Sylvain
What about getting some return code instead of creating another native function.
2017-11-04 22:03:28 -07:00
Sam Lantinga
46bbc5d328
Fixed bug 3917 - Android, issues with getManifestEnvironmentVariable
...
We're going to push the manifest environment variables from the Java side instead of continually querying for them from the native side.
2017-11-04 09:37:29 -07:00
Sam Lantinga
65195e610d
Make SDL fullscreen windows on Android actually fullscreen
2017-11-02 10:41:55 -07:00
Sam Lantinga
084cfc4173
Fixed bug 3933 - Android, no need of the listener thread
...
Sylvain
A listener thread has been added to know when the native thread would end.
But now, it is more easy to only check that after the main function has returned. It's one thread less.
2017-11-02 08:46:14 -07:00
Sam Lantinga
b4e2edf099
Allow the activity to persist through connecting or disconnecting a keyboard
2017-11-01 18:41:11 -07:00
Sam Lantinga
efa038fbaf
Moved the meta-data into the right section
2017-11-01 18:40:11 -07:00
Sam Lantinga
98af57285f
Added controller mapping for Android TV remotes
...
Also fixed the back button on the remote exiting the application
2017-11-01 10:06:58 -07:00
Sam Lantinga
8c4dc3c464
Add SDL_GetDisplayDPI implementation on Android. (thanks Rachel!)
2017-10-31 13:49:59 -07:00
Sam Lantinga
082143db78
Fixed Java string comparison with ""
2017-10-29 21:09:09 -07:00
Sam Lantinga
d985978f55
android: Fix softkeyboard issue in SDL on Android.
2017-10-26 10:41:38 -07:00
Sam Lantinga
467aa0904e
Added the ability to set SDL hints from AndroidManifest.xml (thanks Rachel!)
...
This is especially useful for things like the accelerometer hint which could be needed before application main().
2017-10-24 00:17:07 -07:00