[Android] Fix NoSuchMethodError for Android 25-
Nicolas Pomepuy
git at videolan.org
Tue Oct 8 09:52:48 UTC 2024
vlc-android | branch: 3.5.x | Nicolas Pomepuy <nicolas at videolabs.io> | Tue Oct 8 10:55:50 2024 +0200| [e2f1f1ff69ba1cbd03c5cfde583db50f2405eee6] | committer: Nicolas Pomepuy
Fix NoSuchMethodError for Android 25-
> https://code.videolan.org/videolan/vlc-android/commit/e2f1f1ff69ba1cbd03c5cfde583db50f2405eee6
---
application/vlc-android/src/org/videolan/vlc/MediaParsingService.kt | 2 +-
application/vlc-android/src/org/videolan/vlc/PlaybackService.kt | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/application/vlc-android/src/org/videolan/vlc/MediaParsingService.kt b/application/vlc-android/src/org/videolan/vlc/MediaParsingService.kt
index c358a6309f..1001d3c4f1 100644
--- a/application/vlc-android/src/org/videolan/vlc/MediaParsingService.kt
+++ b/application/vlc-android/src/org/videolan/vlc/MediaParsingService.kt
@@ -134,7 +134,7 @@ class MediaParsingService : LifecycleService(), DevicesDiscoveryCb {
val filter = IntentFilter()
filter.addAction(ACTION_PAUSE_SCAN)
filter.addAction(ACTION_RESUME_SCAN)
- registerReceiver(receiver, filter, RECEIVER_NOT_EXPORTED)
+ registerReceiverCompat(receiver, filter, false)
val pm = applicationContext.getSystemService<PowerManager>()!!
wakeLock = pm.newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, "VLC:MediaParsingService")
diff --git a/application/vlc-android/src/org/videolan/vlc/PlaybackService.kt b/application/vlc-android/src/org/videolan/vlc/PlaybackService.kt
index e692e1c25f..9e41b49a34 100644
--- a/application/vlc-android/src/org/videolan/vlc/PlaybackService.kt
+++ b/application/vlc-android/src/org/videolan/vlc/PlaybackService.kt
@@ -643,7 +643,7 @@ class PlaybackService : MediaBrowserServiceCompat(), LifecycleOwner, CoroutineSc
addAction(ACTION_CAR_MODE_EXIT)
addAction(CUSTOM_ACTION)
}
- registerReceiver(receiver, filter, RECEIVER_NOT_EXPORTED)
+ registerReceiverCompat(receiver, filter, false)
if (CarConnectionHandler.preferCarConnectionHandler()) {
carConnectionHandler = CarConnectionHandler(contentResolver)
carConnectionHandler.connectionType.observeForever {
More information about the Android
mailing list