mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-25 17:25:08 +02:00
LibMedia+LibWeb: Remove an unnecessary parameter from on_track_added
The TrackType parameter is redundant, since the actual Track object already contains it.
This commit is contained in:
committed by
Gregory Bertilson
parent
d6f821f22d
commit
9664c11c15
Notes:
github-actions[bot]
2026-04-01 07:58:44 +00:00
Author: https://github.com/Zaggy1024 Commit: https://github.com/LadybirdBrowser/ladybird/commit/9664c11c15c Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/8655 Reviewed-by: https://github.com/tcl3
@@ -1536,8 +1536,8 @@ void HTMLMediaElement::set_up_playback_manager()
|
||||
|
||||
// -> If the media resource is found to have an audio track
|
||||
// -> If the media resource is found to have a video track
|
||||
m_playback_manager->on_track_added = GC::weak_callback(*this, [](auto& self, auto track_type, auto& track) {
|
||||
if (track_type == Media::TrackType::Audio)
|
||||
m_playback_manager->on_track_added = GC::weak_callback(*this, [](auto& self, auto& track) {
|
||||
if (track.type() == Media::TrackType::Audio)
|
||||
self.on_audio_track_added(track);
|
||||
else
|
||||
self.on_video_track_added(track);
|
||||
|
||||
Reference in New Issue
Block a user