mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 04:07:45 +00:00
LibWeb: Implement the :playing
and :paused
pseudo-classes
These match media elements (`<video>` and `<audio>`) which are playing or paused, respectively.
This commit is contained in:
parent
a336fe4fc4
commit
4df5e24926
6 changed files with 34 additions and 1 deletions
|
@ -115,6 +115,8 @@ public:
|
|||
Lang,
|
||||
Scope,
|
||||
Defined,
|
||||
Playing,
|
||||
Paused,
|
||||
};
|
||||
Type type;
|
||||
|
||||
|
@ -304,6 +306,10 @@ constexpr StringView pseudo_class_name(Selector::SimpleSelector::PseudoClass::Ty
|
|||
return "scope"sv;
|
||||
case Selector::SimpleSelector::PseudoClass::Type::Defined:
|
||||
return "defined"sv;
|
||||
case Selector::SimpleSelector::PseudoClass::Type::Playing:
|
||||
return "playing"sv;
|
||||
case Selector::SimpleSelector::PseudoClass::Type::Paused:
|
||||
return "paused"sv;
|
||||
}
|
||||
VERIFY_NOT_REACHED();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue