Screen share issue in Android 12 and 13

  1. → I am using Jitsi SDK 6.1.0 but Screen sharing is not working also my app crashes when i join Second time on jitsiview.

  2. → Here is your patch which i use here in Android → JitsiMeetOngoingConferenceService.launch(this@MainActivity,extraData);

  3. → Here is the code how i manage jitsiview →

protected fun getJitsiView(): JitsiMeetView? {

view =  JitsiMeetView(this);

view = findViewById(R.id.test_JitsiMeetView) as JitsiMeetView
return view
}

fun join(options: JitsiMeetConferenceOptions?) {

val view = getJitsiView()

if (view != null) {
view!!.join(options)
}

                                                                 }

fun leave() {

if (view != null) {
view.dispose();
view = null;
JitsiMeetActivityDelegate.onHostDestroy(this);
}

          }
  1. → Here is app Crash Error → Caused by: android.app.StackTrace: Last startServiceCommon() call for this service was made here
    at android.app.ContextImpl.startServiceCommon(ContextImpl.java:1988)
    at android.app.ContextImpl.startForegroundService(ContextImpl.java:1933)
    at android.content.ContextWrapper.startForegroundService(ContextWrapper.java:839)
    at android.content.ContextWrapper.startForegroundService(ContextWrapper.java:839)
    at org.jitsi.meet.sdk.JitsiMeetOngoingConferenceService.launch(JitsiMeetOngoingConferenceService.java:67)
    at com.cbc.views.MainActivity.onConferenceWillJoin(MainActivity.kt:3314)
    at com.cbc.views.MainActivity.onBroadcastReceived(MainActivity.kt:3227)
    at com.cbc.views.MainActivity.access$onBroadcastReceived(MainActivity.kt:92)
    at com.cbc.views.MainActivity$broadcastReceiver$1.onReceive(MainActivity.kt:3215)
    2023-02-16 15:33:08.565 31451-31451/com.cbc E/JitsiMeetSDK: at androidx.localbroadcastmanager.content.LocalBroadcastManager.executePendingBroadcasts(LocalBroadcastManager.java:313)
    at androidx.localbroadcastmanager.content.LocalBroadcastManager$1.handleMessage(LocalBroadcastManager.java:121)

Replied on GH.

ok sir

I am using JitsiMeetView because I do customization on screen.I also tested SDK 7.0.1 but issue remain same because of the Forground service use in the patch which is restricted by the google in android 11 & 12 .

Let’s continue on GH please, posting the same thing in 2 places is making things confusing.