- From: Mark Foltz via GitHub <sysbot+gh@w3.org>
- Date: Thu, 10 Sep 2015 16:54:42 +0000
- To: public-secondscreen@w3.org
@avayvod All good points. I am in favor of landing a smaller change
now, and using feedback to add the additional features discussed in
this thread.
In particular, it seems like the question of the default behavior for
the presentation when all sessions are disconnected will be difficult
to answer without additional real world experience. I can say that
for Google Cast applications, the default behavior is to leave the
presentation running; it's suggested that the presentation close
itself when the last sender disconnects [1], but many implement some
timeout before doing that.
Here is a simplified version of the proposal in
https://github.com/w3c/presentation-api/issues/35#issuecomment-138727080:
```
enum PresentationSessionState {
"connected",
"closed",
"terminated"
};
partial interface PresentationSession {
readonly attribute PresentationSessionState state;
// Both sides transition to "closed." Presenting context remains
// running.
void close();
// All connected sessions transition to "terminated." Presenting
// context is closed.
void terminate();
// Fired on change to .state
attribute EventHandler onstatechange;
};
```

[1]
https://developers.google.com/cast/docs/custom_receiver#session-management
I plan to prepare a PR to implement this,
--
GitHub Notif of comment by mfoltzgoogle
See
https://github.com/w3c/presentation-api/issues/35#issuecomment-139308539
Received on Thursday, 10 September 2015 16:54:45 UTC