mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-04 15:45:25 +00:00
LibWeb: Allow toggling playback of media elements with keyboard controls
This allows pausing/playing media elements with the space bar.
This commit is contained in:
committed by
Andreas Kling
parent
2c5c815f44
commit
a4070b1452
@@ -11,6 +11,7 @@
|
||||
#include <AK/Optional.h>
|
||||
#include <AK/Time.h>
|
||||
#include <AK/Variant.h>
|
||||
#include <Kernel/API/KeyCode.h>
|
||||
#include <LibGfx/Rect.h>
|
||||
#include <LibJS/Heap/MarkedVector.h>
|
||||
#include <LibJS/SafeFunction.h>
|
||||
@@ -99,6 +100,8 @@ public:
|
||||
JS::NonnullGCPtr<AudioTrackList> audio_tracks() const { return *m_audio_tracks; }
|
||||
JS::NonnullGCPtr<VideoTrackList> video_tracks() const { return *m_video_tracks; }
|
||||
|
||||
WebIDL::ExceptionOr<void> handle_keydown(Badge<Web::EventHandler>, KeyCode);
|
||||
|
||||
enum class MouseTrackingComponent {
|
||||
Timeline,
|
||||
Volume,
|
||||
|
||||
Reference in New Issue
Block a user