-
-
Notifications
You must be signed in to change notification settings - Fork 141
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow user to quick play items with play button #332
Conversation
I like the idea. Not had a chance to try the code yet, but hopefully this weekend. Wondering if there was maybe something we could do to avoid having to modify IF statement when we add new supported types (E.g. Music albums, tracks, photos etc). Perhaps we could have a CanQuickplay property of the JFContentItem class that could be set for each type that inherits it? And possibly even a GetQuickplayItem() function that each item type can override to provide the media info to play. This would let TV Series or Seasons to implement it to return the appropriate video? |
I like that idea but the home screen uses HomeData I believe - not JFContentItem but I'd have to double check. Also, I'm not sure the API call I'm using can support all of those different types. If we need different API calls for each type then we can't avoid the type check. we'd have to either validate type before sending to function or have one giant function that writes api call based on type.
I don't follow. Where would this code live? |
No, you're right. I thought I had moved the home screen over to using the items based of JFContentItem but not yet.
I think I probably need to think this through some more. I was thinking that the end goal for the selection stuff would be to have a single "Selected Item" (that would be based on a JFContentItem) and for it to have an additional property to tell us whether it should be Viewed or Played. There was then just one function in the main even loop that observed the selectedItem and would perform the appropriate action based on the type
The JFContentItem would define the As I say, needs to thought through some more (if it's even a direction we want to go). |
On one hand, I like where your heads at. It seems like the more "roku" way of doing things - attaching the data to nodes. But on the other hand, it seems unnecessary. We can't get rid of the type check, we'll still have to manually modify the logic as we add support for more item types, and doing this before the home screen rewrite would create extra work. Like you said, I think we should think it out more. Maybe make issues for all of our big picture stuff i.e. the future plans for JFContentItem, quick play etc. PS: I also thought quickplay could be used as a way to support deep links but i still need to look into that more. |
This allows the user to "quick play" an item with type "Movie" or "Episode" from the home screen, itemgrid2, and the tv season episode list using the play button on the remote.
Changes
Create field
quickPlayNode
to hold selected (focused) item nodeCreate observers on the
quickPlayNode
fields that report to main loopValidate and play video from main loop
Issues
N/A