From 359f1bf5d2abb96a9940d28c2b362a75f2102ff4 Mon Sep 17 00:00:00 2001 From: Diego Mello Date: Tue, 21 Apr 2026 21:29:27 -0300 Subject: [PATCH 1/2] feat(android): create VoipCallService with FOREGROUND_SERVICE_MICROPHONE New `VoipCallService` extends `Service` and runs as a foreground service with `foregroundServiceType="microphone"`. Keeps VoIP audio calls alive when the app moves to the background (Android terminates background processes without a foreground service). - Service starts via `VoipCallService.startService(context, callId)` with ACTION_START - Service stops via `VoipCallService.stopService(context)` with ACTION_STOP - Starts with `ServiceInfo.FOREGROUND_SERVICE_TYPE_MICROPHONE` on API 29+ - Creates low-priority notification channel and ongoing notification - Manifest declares service with `foregroundServiceType="microphone"` Fixes: C2 (missing VoipCallService with FOREGROUND_SERVICE_MICROPHONE) --- android/app/src/main/AndroidManifest.xml | 7 + .../reactnative/voip/VoipCallService.kt | 156 ++++++++++++++++++ 2 files changed, 163 insertions(+) create mode 100644 android/app/src/main/java/chat/rocket/reactnative/voip/VoipCallService.kt diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index eb755ca9953..acea030650c 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -147,6 +147,13 @@ + + +