-
Notifications
You must be signed in to change notification settings - Fork 347
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
Support displaying bookmark state and watched progress in video manager #742
Conversation
The terminus 'Plugin' has a special semantic within MythTV. |
Yes, no problem. I just followed the naming of the function to register the formerly used MediaCallback, which is called 'RegisterMediaPlugin'. I could rename 'MythMediaPlugin' to 'MythMediaHandler', but then the register function should be also renamed to avoid confusion. |
9e44f4f
to
9e150e2
Compare
62e21c7
to
dbdbc67
Compare
hambre One Q: is this code allows to have also watched progressbars on video lists entries? |
Hi Warpme, yes it allows progress bars for video list entries. If you look at the left red mark on the screenshot, you can see a green progressbar under the video title. However for that to work the video length entry within the videomarkup table needs to be present. |
Ah - i missed green bar on screenshot :-) Also - isn't be good idea also to add new field in filemarkup with total frames for movie? |
I think the total duration mark is given in frames. The problem is where to get this value from without relying on mythcommflag. I would love to add that, so I would not need a script to actually create this using mythcommflag. Any ideas? |
Well - simple idea might be to do (or estimate) total_frames in mythplayer. |
btw: i love your work with Monochrome! |
Hmm ok, I can have a look to come up with something. Thanks for the hint! |
@warpme Thanks to your hint I added saving the total frame count for video files automatically without needing to use external tooling. You might want to check if that works for you. |
@hambre One Q: isn't worth to have behavior of video progress as much as possible similar to recordings progress behavior? Also - i see small issue when user enters videolist: there is no progress-bar on list entries unless user gives active focus on list entry. |
@warpme |
@hambre But i still think idea that: user see progress bar on video only when: status is "not watched" & progress is > 0 is worth to do? |
You mention:
I'm reading this as alternative use-case to current mythtv offers: mythv: your needs: So ideally will be to add setting like: "always show watching progress" which functionally will be opposite to "show watching progress only for unwatched" (like in current mythtv). With this we can cover: current presentation model & your alternative preferred model.... What you think? |
Yes this might work to support the different use cases. I will look into it. |
Extend ProgramInfo to load, delete and insert MARK_TOTAL_FRAMES entries in filemarkup table. This markup type can now be written by mythcommflag when rebuilding the seektable for a video file. This is in preparation to support displaying watched progress within the video manager.
When exiting the media player, check if the current video file alreadey has a total frame count saved within the filemarkup table. If it is not yet present, then save the total frame count from the player. This way the watched progress does not need extra tooling to provide the total frame count of a video file.
Query and cache playback state related data from database so the watched progress can be shown for multiple video list items.
Add support for displaying a bookmark state within the video manager. This uses the playback state class for caching the playback state for all videos. Also adds support for displaying watched progress state to video manager. This needs the last playing position (already supported) as well as a total frames markup datum within the filemarkup table. The watched progress is then calculated and can be displayed via a progress in the currently selected list item.
Signal removal of last played position and bookmark to video dialog, so it can update the respective button list item.
When watching a video to the end, the player can mark (if enabled by a setting) the video as watched. This was not reflected in the GUI state until now. So after receiving the playback stopped event, we load the video metadata of the current video and sync it with the metadata from the cache.
Adds a setting to always show watched progress even if the recording or video is marked as watched. Make behaviour of displaying the watched progress the same in recordings and video lists.
2f86ddb
to
21dd2aa
Compare
@warpme |
@hambre |
It seems not. String freeze for Myth 34 is already in effect. |
Can still be added to v34 as far as I know. It will be then only in English and not translated. |
Good to know. It still needs one of the developers to look at the PR and hopefully merge it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks OK to me. It does not appear to break anything. To make it useful there must be changes in the themes but I expect that then to be added later. There is one translatable string added but I expect at least the German translation can still be done before v34 is really frozen.
I am OK with merging this now.
Thanks for your approval! I can do the German translation for the new string as soon as this is merged, no problem. However I do not have the permissions to merge myself, so you or one of the other devs need to do that. |
@kmdewaal Thanks for merging! |
This adds support of displaying the bookmark state and the watched progress
within the video manager.
I have added preliminary support to display bookmark state and watched progress to the Monochrome theme
as seen in the image below:
Checklist