Zoom's `MeetingActivity` immediately destroys itself when backgrounded

Description
Zoom’s MeetingActivity will destroy itself immediately when backgrounded. This deviates from normal Android application behavior.

Consider the following custom MeetingActivity, registered in the config.xml file:

class CustomZoomActivity : MeetingActivity() {

    override fun onBackPressed() {
        // Zoom's MeetingActivity appears to close the
        // application when back is pressed by default.
        // Override this behavior.
        finish()
    }

    override fun onPause() { super.onPause() }

    override fun onStop() { super.onStop() }

    override fun onDestroy() { super.onDestroy() }
}

If a user joins a meeting and then backgrounds the application (by either clicking the home button, the recent apps button, etc.) the CustomMeetingActivity/MeetingActivity will immediately go through onPause(), onStop, and onDestroy(). Thus, when the application returns to the foreground, the relevant meeting Activity is closed.

As mentioned, this sort of behavior deviates from the basic lifecycle of Android applications, and results in a very odd user experience. Note that the user does not even need to switch apps for this issue to occur; simply clicking the “recent apps” button and immediately going back to the same app will also produce this issue.

Questions:

  1. Why does the relevant meeting Activity close itself when backgrounded?
  2. How can this issue be resolved?

Which version?
SDK version v5.0.24433.0616

To Reproduce
Steps to reproduce the behavior:

  1. Create and register an Activity for use as the meeting Activity, as shown above.
  2. Join an existing meeting (either by entering a waiting room or directly entering a meeting).
  3. Background the application by any means, and then immediately return to the application to observe the issue.

Smartphone:

  • Device: Pixel 3 Emulator
  • OS: Android
  • Version: API 29

Additional context
This matter is rather urgent, a prompt response would be highly appreciated.

Hi @caleb.c,

Thanks for the post. Are you using Zoom default UI or Custom UI? I just tried to reproduce this issue with our demo app but when I put the app in the background and then bring it foreground, I am still able to continue the meeting in both modes.

Any logs you could provide so that we could investigate what is going on?

Thanks!

Hi, I am using zoom default UI. I’m also facing the same issue (destroys when click home button) for devices with android version 11(Vivo Y73, Samsung M30S).Zoom SDK version v5.10.1

Hi @ociuzteam, thanks for using the dev forum.

Sorry to hear you’re running into a similar issue. After some testing on my side, I was unable to reproduce the behavior you are seeing. Are you seeing any other behavior aside from the onDestroy callback being triggered?

Thanks!

Thank you for the response. There is no other important issues. When press home button(in device), exits from Meeting Activity instead of minimizing.

Hi @ociuzteam,

The Android meeting SDK does not handle automatically showing the mini meeting window when your app is backgrounded like the Zoom client does. You can call showMiniMeetingWindow to minimize the meeting UI programmatically and hideMiniMeetingWindow to hide it, which can help with imitating the Zoom client’s behavior.

Thanks!