Commit Graph

2452 Commits

Author SHA1 Message Date
JMC47
099ea79c43
Merge pull request #14098 from Simonx22/android/dolphin-application-kotlin
Android: Convert DolphinApplication to Kotlin
2025-11-11 16:58:27 -05:00
Jordan Woyak
731849c239
Merge pull request #14103 from Simonx22/android/agp-8.11.0-to-8.13.0
Android: Upgrade AGP dependency from 8.11.0 to 8.13.0
2025-11-11 14:33:05 -06:00
Simonx22
cd62125385 Android: Upgrade AGP dependency from 8.11.0 to 8.13.0 2025-11-11 07:12:46 -05:00
Simonx22
4a3a0228ef Android: Keep main toolbar pinned on game grid
Prevents the version/build bar from sliding behind the status bar when scrolling so the time and build info remain readable instead of overlapping.
2025-11-10 06:47:10 -05:00
Simonx22
469782292c Android: Convert DolphinApplication to Kotlin 2025-11-09 19:45:41 -05:00
Simonx22
b733213bcf Android: Prevent dismissing the System Update dialog by tapping outside
Tapping outside the System Update dialog would previously close it and leave the update in a partially canceled, inconsistent state. This change disables outside-touch dismissal to avoid accidental interruptions and ensure the process completes cleanly.
2025-11-09 01:21:58 -05:00
OatmealDome
4f849ec827
Merge pull request #14047 from Simonx22/reset-all-dolphin-settings-android
Android: Add Reset Dolphin Settings functionality
2025-11-08 14:03:44 -05:00
OatmealDome
5ee1ae43bb
Merge pull request #14077 from Simonx22/android-alert-message-kotlin
Android: Convert AlertMessage dialog to Kotlin
2025-11-08 14:03:19 -05:00
OatmealDome
02ad041866
Merge pull request #14086 from Simonx22/android/use-native-analytics
Android: Use the shared HTTP analytics backend
2025-11-08 14:03:06 -05:00
Simonx22
8ee767f292 Android: Convert AlertMessage dialog to Kotlin 2025-11-08 12:21:12 -05:00
Simonx22
82f658a28f Android: Use the shared HTTP analytics backend
We can now route Android analytics through Common::HttpAnalyticsBackend, drop the Volley sender, and keep the JNI layer limited to only transfer metadata since https://bugs.dolphin-emu.org/issues/11772 has been fixed.
2025-11-08 12:14:40 -05:00
JosJuice
ba14222a2b
Merge pull request #13939 from Dentomologist/logging_avoid_overwriting_debug_verbosity_in_release_builds
Logging: Don't overwrite LDEBUG level in Release builds
2025-11-08 14:47:27 +01:00
Simonx22
ddbbb2ea4b Android: Replace Action1 helper with Kotlin lambda 2025-11-07 11:56:11 -05:00
Simonx22
f718a6b72f Android: Add Reset Dolphin Settings functionality 2025-11-02 20:09:23 -05:00
JosJuice
249f999c6a
Merge pull request #13655 from JosJuice/android-always-expand-sheets
Android: Expand bottom sheets on devices with touch too
2025-11-01 12:22:45 +01:00
JosJuice
35c5b51b62
Merge pull request #14048 from Simonx22/android-instant-settings-saving
Android: Save settings instantly after edits
2025-11-01 12:22:35 +01:00
JosJuice
1b8a54024c Android: Expand bottom sheets on devices with touch too
In a few places in Dolphin, we're using BottomSheetDialogFragments.
These unhelpfully tend to start out in a "collapsed" state when in
landscape mode (presumably depending on factors like screen size). The
user then has to manually expand them before they can meaningfully
interact with them.

We've been automatically setting BottomSheetDialogFragments to the
expanded state if the device Dolphin is running on doesn't support
touch, since with d-pad navigation it's impossible to expand these
sheets. But I think we should set them to expanded on devices that
support touch too. I haven't encountered a single case where you can do
anything useful with any of Dolphin's BottomSheetDialogFragments while
they're collapsed, so the user always has to expand sheets manually if
they start out collapsed. And just because a device supports touch
doesn't necessarily mean you're interacting with it through the touch
screen right now - you could be using a gamepad, for instance.
2025-10-30 21:22:41 +01:00
Dentomologist
570ec7c322 Android: Fix unused value warning
Remove "env, " from "return env, GetControlPointer..." since the left
side of a comma operator has no effect.

This was presumably a copy/paste error from the function above it.
2025-10-29 16:19:15 -07:00
Simonx22
82c86221d6 Android: Save settings instantly after edits 2025-10-29 16:49:16 -04:00
JosJuice
f05f89e6b4 Android: Update NDK version to 29.0.14206865 2025-10-15 19:57:53 +02:00
JMC47
e1c7734ee4
Merge pull request #13260 from JosJuice/android-gcadapter-hotplug-callback
Android: Detect GCAdapter hotplug using BroadcastReceiver
2025-09-28 14:03:50 -04:00
Dentomologist
2d48043b61 Logging: Don't overwrite LDEBUG verbosity in Release builds
Preserve the configured logging verbosity unless the user actually
changes it, rather than capping it to LINFO on release builds.

Rename LogManager::m_level to m_effective_level and distinguish between
the config and effective level in various function/variable names.

Make m_effective_level atomic to prevent data races when setting the
effective log level from the config changed callback.
2025-09-19 13:25:42 -07:00
Marocco2
008c292b4e Android: Set Dolphin documents' root supports testing parent child relationships.
Adds `DocumentsContract.Root.FLAG_SUPPORTS_IS_CHILD` to the list of the flags in order to show up for third-party apps for easier file syncing with local/cloud file server providers
2025-08-26 15:40:32 +02:00
Marocco2
834f3634a8 Android: Set Dolphin documents as Local only
Adds `DocumentsContract.Root.FLAG_LOCAL_ONLY` to the list of the flags in order to show up for third-party apps for easier file syncing with local/cloud file server providers
2025-08-25 19:52:36 +02:00
JosJuice
be669c7ce3
Merge pull request #13841 from JosJuice/android-opt-out-back
Android: Opt out of back invoked callback
2025-08-05 08:10:43 +02:00
Dentomologist
530ea7528e Host: Remove unnecessary functions
Remove Host_RefreshDSPDebuggerWindow (which hasn't done anything since
DolphinWX was removed in 44b22c90) and DSP::Host::UpdateDebugger (which
only called Host_RefreshDSPDebuggerWindow).
2025-08-03 13:19:30 -07:00
Dentomologist
d0de0a3f47 Host: Remove unnecessary function
Remove Host_UpdateMainFrame(). The only non-empty call happened in
DolphinNoGUI which called s_update_main_frame_event.Set(), but
DolphinNoGUI never waits on that event.
2025-08-03 13:12:01 -07:00
Admiral H. Curtiss
5439a345a7
Merge pull request #13829 from JosJuice/android-retroachievements-pause-override
Android: Don't let RetroAchievements override onPause
2025-08-01 21:23:28 +02:00
JosJuice
5c7e8db26e Android: Opt out of back invoked callback
When 9d9b6d8 changed our target SDK version to Android 16, it made
Android 16 stop calling onBackPressed and stop delivering KEYCODE_BACK
events. Dolphin's code isn't ready for that yet.

Android lets us opt out of this new behavior for now, so let's do so.
But the opt-out will presumably stop working once we start targeting
Android 17, so we're going to have to update Dolphin's code within the
next one or two years to support the replacement API.
2025-08-01 19:18:09 +02:00
JosJuice
8524e725a8 Android: Add additional null check in GCAdapter
Just in case, since the documentation says this could be null.
2025-07-27 11:37:45 +02:00
JosJuice
e2e33becc9 Android: Detect GCAdapter connection using BroadcastReceiver
We can register a BroadcastReceiver to have Android tell us when a GC
adapter gets connected instead of having a loop where we continuously
call SleepCurrentThread(1000) and poll the current status. When waiting
for a GC adapter to connect, this both reduces power usage and improves
responsiveness.

Note that I made openAdapter get the UsbDevice that's been stored by the
hotplug code instead of having openAdapter find the UsbDevice on its own
like before. This is only because I want to ensure that the UsbDevice
being tracked for disconnection is the same as the UsbDevice actually
being used, in case the user has multiple adapters connected.
2025-07-27 11:21:04 +02:00
JosJuice
7508842859 Android: Clean up naming in Java_GCAdapter and Java_WiimoteAdapter
This isn't how we name things in Java/Kotlin.
2025-07-27 11:13:44 +02:00
JosJuice
c3be049571 Android: Don't let RetroAchievements override onPause
When Android sends Dolphin to the background, emulation *must* pause,
otherwise emulation continues running and continues outputting audio to
the user. RetroAchievements mustn't be allowed to override it.
2025-07-26 19:59:08 +02:00
JosJuice
a6642d5f79
Merge pull request #13789 from Simonx22/update-sdk36-gradle813
Android: Bump SDK to 36 and Gradle to 8.13
2025-07-26 11:19:44 +02:00
Simon
9d9b6d8705 Android: Bump SDK to 36 and Gradle to 8.13
Starting August 31, 2025, targeting at least Android 15 (API level 35) will be required: https://support.google.com/googleplay/android-developer/answer/11926878
This commit sets the target SDK to API level 36 (Android 16), the latest available version.
2025-07-24 15:43:52 -04:00
Jordan Woyak
c39c8277b7
Merge pull request #13674 from JosJuice/android-visualize-input
Android: Show input indicators in controller settings
2025-07-20 17:46:47 -05:00
JMC47
42d5f2b705
Merge pull request #13702 from CostPerUnit/master
MappingWidget: Add Advanced Configuration Button to Point And Point Passthrough "Enable" boxes
2025-06-09 00:09:35 -04:00
JMC47
24b0bf01d5
Merge pull request #12836 from JosJuice/opensles-buffer-size
Android: Ask system for optimal audio buffer size and sample rate
2025-06-07 23:07:37 -04:00
JosJuice
43b254aaad Android: Update advanced mapping dialog when devices change
Without this, there was a bug where if you turned the device's screen
off and on again while in the advanced mapping dialog, the input
indicators would stop updating. This is because turning the screen on
again causes devices to refresh, which causes all devices to be
recreated, leaving the AdvancedMappingControlViewHolders stuck
referencing controls belonging to devices that are no longer being
updated.
2025-06-07 10:20:21 +02:00
JosJuice
1002f29691 Android: Show input indicators in controller settings 2025-06-07 10:20:20 +02:00
JosJuice
0dd601577d Android: Set parent when inflating RecyclerView.ViewHolders
This makes sure view holders get proper widths when they use
layout_width="match_parent". This becomes quite noticeable for
AdvancedMappingControlAdapter in the next commit, but I'm also
making the change for other adapters while I'm at it.
2025-06-07 10:20:19 +02:00
JosJuice
cf7b141eb9 Android: Make input mapping view holders observe input state changes 2025-06-07 10:20:19 +02:00
JosJuice
22fd0472ed Android: Pass CoreDevice.Control to AdvancedMappingControlViewHolder 2025-06-07 10:20:19 +02:00
JosJuice
4b4a775d5a Android: Make AdvancedMappingControlViewHolder a LifecycleOwner 2025-06-07 10:20:19 +02:00
JosJuice
5d7cba8cd9 Android: Make SettingViewHolder a LifecycleOwner 2025-06-07 10:20:19 +02:00
JosJuice
4214cb6eb8 Android: Make input state changes observable 2025-06-07 10:20:18 +02:00
JosJuice
5d2518d490 Android: Add android.hardware.microphone to manifest
Google Play is now blocking distribution for Android TV unless we
explicitly set the android.hardware.microphone hardware feature as
android:required="false", because it's inferring
android.hardware.microphone from the android.permission.RECORD_AUDIO we
added for Wii Speak emulation, with android:required defaulting to true.
I was under the belief that setting android:required="false" on
android.permission.RECORD_AUDIO would solve this, but looking closer at
the definition of <uses-permission>, it doesn't actually support
android:required attributes, so that presumably has no effect.
2025-06-04 21:30:51 +02:00
CostPerUnit
a5b4a0b9e4 InputCommon/DolphinQt: Add advanced settings button for "Point" and "Point (Passthrough)" "Enabled" checkboxes. 2025-05-29 19:39:10 -05:00
JosJuice
f99d3dbd5c Android: Ask system for optimal audio buffer size and sample rate
This can reduce audio latency according to
https://developer.android.com/ndk/guides/audio/opensl/opensl-prog-notes#perform.

Previously we were using the hardcoded values of 48000 Hz and 256 frames
per buffer. The sample rate we use with this change is 48000 Hz on all
devices I'm aware of, but the buffer size does vary across devices.

Terminology note: The old code used the term "sample" to refer to what
Android refers to as a "frame". "Frame" is a clearer term to use for
this, so I've changed OpenSLESStream's terminology. One frame consists
of one sample per channel.
2025-05-25 11:59:33 +02:00
JMC47
a62449711f
Merge pull request #12769 from sepalani/wii-speak
IOS/USB: Emulate Wii Speak using cubeb
2025-05-21 13:54:56 -04:00