diff --git a/Userland/Applications/VideoPlayer/VideoPlayerWidget.cpp b/Userland/Applications/VideoPlayer/VideoPlayerWidget.cpp index 61d15e69fe..fe3b11ba51 100644 --- a/Userland/Applications/VideoPlayer/VideoPlayerWidget.cpp +++ b/Userland/Applications/VideoPlayer/VideoPlayerWidget.cpp @@ -234,7 +234,7 @@ void VideoPlayerWidget::event(Core::Event& event) set_current_timestamp(m_playback_manager->current_playback_time()); frame_event.accept(); - } else if (event.type() == Video::EventType::PlaybackStatusChange) { + } else if (event.type() == Video::EventType::PlaybackStateChange) { update_play_pause_icon(); event.accept(); } diff --git a/Userland/Libraries/LibVideo/PlaybackManager.cpp b/Userland/Libraries/LibVideo/PlaybackManager.cpp index 672bf4dbed..c60f83f582 100644 --- a/Userland/Libraries/LibVideo/PlaybackManager.cpp +++ b/Userland/Libraries/LibVideo/PlaybackManager.cpp @@ -57,7 +57,7 @@ void PlaybackManager::set_playback_status(PlaybackStatus status) m_present_timer->stop(); } - m_main_loop.post_event(m_event_handler, make(status, old_status)); + m_main_loop.post_event(m_event_handler, make()); } } diff --git a/Userland/Libraries/LibVideo/PlaybackManager.h b/Userland/Libraries/LibVideo/PlaybackManager.h index abc26d0f03..c31a01b34d 100644 --- a/Userland/Libraries/LibVideo/PlaybackManager.h +++ b/Userland/Libraries/LibVideo/PlaybackManager.h @@ -165,7 +165,7 @@ private: enum EventType : unsigned { DecoderErrorOccurred = (('v' << 2) | ('i' << 1) | 'd') << 4, VideoFramePresent, - PlaybackStatusChange, + PlaybackStateChange, }; class DecoderErrorEvent : public Core::Event { @@ -199,20 +199,13 @@ private: RefPtr m_frame; }; -class PlaybackStatusChangeEvent : public Core::Event { +class PlaybackStateChangeEvent : public Core::Event { public: - PlaybackStatusChangeEvent() = default; - explicit PlaybackStatusChangeEvent(PlaybackStatus status, PlaybackStatus previous_status) - : Core::Event(PlaybackStatusChange) - , m_status(status) - , m_previous_status(previous_status) + explicit PlaybackStateChangeEvent() + : Core::Event(PlaybackStateChange) { } - virtual ~PlaybackStatusChangeEvent() = default; - -private: - PlaybackStatus m_status; - PlaybackStatus m_previous_status; + virtual ~PlaybackStateChangeEvent() = default; }; inline StringView playback_status_to_string(PlaybackStatus status)