livekit / client-sdk-android

LiveKit SDK for Android
https://docs.livekit.io
Apache License 2.0
176 stars 69 forks source link

Could you add Resuming/Resumed State for Room #380

Closed usayplz closed 7 months ago

usayplz commented 7 months ago

Describe the bug Where is no way to know Room.State (reconnecting, resuming) when using ReconnectType.FORCE_SOFT_RECONNECT

To Reproduce Steps to reproduce the behavior:

  1. val room = LiveKit.create(appContext = context)
  2. room.setReconnectionType(ReconnectType.FORCE_SOFT_RECONNECT)
  3. room::state.flow.collect { state -> if (state == Room.state.RECONNECTING) { state.show() }}

Expected behavior Please add existing reconnecting state or add new state resuming for Room.state

davidliu commented 7 months ago

room.setReconnectType is not meant for production use, and is only there for testing purposes. It's marked @VisibleForTesting for this very reason.