W3C home > Mailing lists > Public > public-secondscreen@w3.org > September 2015

Re: [presentation-api] Refine how to do session teardown/disconnect/closing

From: Jonas Sicking via GitHub <sysbot+gh@w3.org>
Date: Wed, 02 Sep 2015 23:25:55 +0000
To: public-secondscreen@w3.org
Message-ID: <issue_comment.created-137272420-1441236354-sysbot+gh@w3.org>
@mounirlamouri if the netflix website calls `.close()`, then the 
PresentationSession would transition to a `terminated` state. If we 
have the `lastsessionterminated` event, then that would automatically 
close the application on the TV. If we don't have the 
`lastsessionterminated` event, then the presumption is that the 
application would have code similar to what @mfoltzgoogle provided 
which would cause the application to close.

Either way, the result would be that if the netflix website calls 
`.close()`, that the netflix application on the TV would be closed.

I think @mfoltzgoogle and I are largely in agreement. That we'd have 
just a `.close()` function on PresentationSession which would cause 
the connection to transition to the `terminated` state. And we'd have 
no `.terminate()` function.

The only point of difference in our proposals is whether we have a 
`lastsessionterminated` event which by default would close the page. I
 think whether we do that or not is a function of what default 
behavior we want to have, and how much work it would be to implement 
such an event.

I can definitely live with or without the `lastsessionterminated` 
event. But I kind'a like the default behavior of closing the 
application when the last controller goes away, and I don't think 
implementing the event would be very hard (though I could be wrong 
about that). So the event gets my vote.

But I can really live with either solution.

GitHub Notif of comment by sicking
Received on Wednesday, 2 September 2015 23:25:58 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 2 September 2015 23:25:59 UTC