Skip to content
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

Save reading progress for pdfs for each page #3349

Merged
merged 1 commit into from Jan 20, 2022

Conversation

carif
Copy link
Contributor

@carif carif commented Jan 18, 2022

Changes
This removes the 10s interval between saving and instead saves the
reading progress for pdf files every time.

As a side effect, the pdf will appear in the "Continue Watching" section
of Jellyfin. Before this commit, there was no indication that someone
started reading the pdf book.

Issues
Potentially related to #2582, but for pdfs only

Copy link
Contributor

@dmitrylyzo dmitrylyzo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To update the resume button after stopping, do the same as #3034: stopped event, destroy function and streamInfo.item.

As for the Watched state, it requires changes on the server side. It currently doesn't extract the page count (RunTimeTicks is TimeSpan.TicksPerSecond: 10000000), and need to update UserDataManager.UpdatePlayState method.

src/plugins/pdfPlayer/plugin.js Outdated Show resolved Hide resolved
@dmitrylyzo
Copy link
Contributor

Looks good. Could you squash the commits?

@carif
Copy link
Contributor Author

carif commented Jan 19, 2022

To update the resume button after stopping, do the same as #3034: stopped event, destroy function and streamInfo.item.

As I've noticed that the bookPlayer is missing those calls, too, I just created PR #3350 to solve it there.

Looks good. Could you squash the commits?

Sure.

This removes the 10s interval between saving and instead saves the
reading progress for pdf files every time.

As a side effect, the pdf will appear in the "Continue Watching" section
of Jellyfin. Before this commit, there was no indication that someone
started reading the pdf book.

Update the resume button after stopping for the pdf player.
@sonarcloud
Copy link

sonarcloud bot commented Jan 19, 2022

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.9% 0.9% Duplication

@thornbill thornbill added this to Active PRs in Release 10.8.0 via automation Jan 20, 2022
@thornbill thornbill merged commit 29faa69 into jellyfin:master Jan 20, 2022
Release 10.8.0 automation moved this from Active PRs to Completed PRs Jan 20, 2022
@carif carif deleted the book-progress branch January 20, 2022 12:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Release 10.8.0
  
Completed PRs
Development

Successfully merging this pull request may close these issues.

None yet

3 participants