1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 05:47:34 +00:00

LibWeb: Implement the :buffering and :stalled pseudo-classes

Currently, HTMLMediaElement doesn't implement the stall timeout, so
`:stalled` always returns false.
This commit is contained in:
Sam Atkins 2023-08-01 15:26:56 +01:00 committed by Tim Flynn
parent eb7cda1172
commit f6e4caf197
7 changed files with 42 additions and 2 deletions

View file

@ -120,6 +120,8 @@ public:
Seeking,
Muted,
VolumeLocked,
Buffering,
Stalled,
};
Type type;
@ -319,6 +321,10 @@ constexpr StringView pseudo_class_name(Selector::SimpleSelector::PseudoClass::Ty
return "muted"sv;
case Selector::SimpleSelector::PseudoClass::Type::VolumeLocked:
return "volume-locked"sv;
case Selector::SimpleSelector::PseudoClass::Type::Buffering:
return "buffering"sv;
case Selector::SimpleSelector::PseudoClass::Type::Stalled:
return "stalled"sv;
}
VERIFY_NOT_REACHED();
}