diff options
author | dec05eba <dec05eba@protonmail.com> | 2023-07-31 00:39:23 +0200 |
---|---|---|
committer | dec05eba <dec05eba@protonmail.com> | 2023-07-31 00:39:23 +0200 |
commit | 5a790f5b77e364063295ea6ebc355df5091e853e (patch) | |
tree | 6dfacf7993eb659f0ce0709d8e56a72d8fb8daf5 | |
parent | 53f79e38f22a11640edce141a3e6f96c4f39a9bb (diff) |
Video: dont update watch progress when watch progress hasn't changed (when paused for example)
-rw-r--r-- | src/QuickMedia.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/QuickMedia.cpp b/src/QuickMedia.cpp index df5984d..04ba62f 100644 --- a/src/QuickMedia.cpp +++ b/src/QuickMedia.cpp @@ -3326,9 +3326,10 @@ namespace QuickMedia { if(update_time_pos) { update_time_pos = false; + const double prev_video_time_pos = video_time_pos; if(video_player->get_time_in_file(&video_time_pos) == VideoPlayer::Error::OK) { successfully_fetched_time_pos = true; - if(successfully_fetched_video_duration) + if(successfully_fetched_video_duration && fabs(video_time_pos - prev_video_time_pos) >= 1.0) video_page->set_watch_progress(video_time_pos, video_info.duration); } } |