mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-12-08 06:09:58 +00:00
LibMedia+LibWeb: Never return errors when getting PlaybackStream time
We should be fine to just fall back to zero or the last returned value if we encounter an error in PlaybackStream::total_time_played(), and this also simplifies the using code.
This commit is contained in:
parent
9da723b5c6
commit
27742ef26d
Notes:
github-actions[bot]
2025-10-28 00:36:34 +00:00
Author: https://github.com/Zaggy1024
Commit: 27742ef26d
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6410
Reviewed-by: https://github.com/R-Goc
Reviewed-by: https://github.com/gmta ✅
11 changed files with 23 additions and 27 deletions
|
|
@ -34,7 +34,6 @@ private:
|
|||
AK::Duration m_duration { AK::Duration::zero() };
|
||||
AK::Duration m_last_resume_in_media_time { AK::Duration::zero() };
|
||||
AK::Duration m_last_resume_in_device_time { AK::Duration::zero() };
|
||||
AK::Duration m_last_good_device_time { AK::Duration::zero() };
|
||||
Core::EventLoop& m_main_thread_event_loop;
|
||||
NonnullRefPtr<Core::Timer> m_update_timer;
|
||||
bool m_paused { true };
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue