0
votes

I am facing a small issue with chromecast application session management on iOS sender app.

I want to be able to create an app session on the receiver and start playback. Close the sender app while playback is happening on the sender. open the app again and connect on the same device. Join the same session and regain control of the receiver without pausing/stopping playback or restarting the whole session.

At the moment I am keeping track of the session ID for the device I'm connected on and execute

- (BOOL)joinApplication:(NSString *)applicationID sessionID:(NSString *)sessionID;

but I am unable to differentiate between a new session and an old one. Is there a way to know the current session id the Chromecast device is connected to? That is to know if I should call join or launch application and start a new session.

1

1 Answers

0
votes

If you want to only join the session if it is your previous one, then calling joinApplication and passing your old sessionId should either succeed (if it is still that very same session) or would fail (if it is a different session, whether from the same app or a different app). Isn't that what you want?