In my application, There is one activity where a publisher and three subscribers can have a conversation among each other in a single session. I have developed the whole concept in portrait mode. Now the requirement is when user rotate his device from portrait mode to landscape mode the current view what I am showing in portrait mode will be changed and new view will be shown to the user.
Problem 1. Are these things feasible with Open Tok (Can Session, publisher and subscriber be maintained on orientation changes)?
Problem 2. I don't want to recreate the session with publisher and subscriber. How can I retain the current session, created publisher and subscriber on Activity orientation changes?
Problem 3. As Open Tok provides an Android View for publisher and subscriber is it a good idea to hold them in memory on orientation changes.
Problem 4. When I try this thing with the Fragment where I set "setRetainInstance(true);" After rotating the screen first time it worked fine for me but the second time it gave the following exception :
com.getvokl.android.GetVoklAPP E/ActivityThread: Activity com.getvokl.android.GetVoklAPP.framework.activity.CallFriendActivity has leaked IntentReceiver com.opentok.android.Session$20@d210317 that was originally registered here. Are you missing a call to unregisterReceiver()?
When I checked It occurred on onResume() method of my Fragment class where I mentioned session.onResume().