Andreas Kling
81047d8f9c
LibCore: Make LocalServer::take_over_from_system_server() return ErrorOr
...
This allows us to use TRY() or MUST() when calling it.
2021-12-06 19:22:16 +01:00
Sam Atkins
46bba44f8b
LibWeb: Move media-query-list serialization code to MediaQuery.{h,cpp}
...
It's not a complicated algorithm, but having it in one place instead of
2, and with spec comments, is nice. :^)
2021-10-15 18:12:20 +01:00
Sam Atkins
1c829e0417
LibWeb: Implement MediaQuery matching :^)
...
Currently, `evaluate()` recalculates whether the MediaQuery matches or
not, and stores it in `m_matches`, which users can query using
`matches()`. This allows us to know when the match-state changes, which
is required to fire MediaQueryList's change event.
2021-10-05 18:51:39 +02:00
Sam Atkins
f1af136925
LibWeb: Make MediaQueryList store MediaQueries instead of a String
2021-10-01 20:03:03 +02:00
Luke Wilde
46686f7f94
LibWeb: Implement MediaQueryList.onchange
2021-10-01 01:35:30 +01:00
Andreas Kling
0ee457dfdf
LibWeb: Provide a default DOM::EventTarget::dispatch_event()
...
All EventTarget subclasses except Window do the same exact thing in
their overrides, so let's just share an implementation in the base.
2021-09-25 23:36:43 +02:00
Luke Wilde
e946316618
LibWeb: Implement MediaQueryList.{addListener,removeListener}
2021-09-13 01:43:03 +02:00
Linus Groh
4155cc7ed5
LibWeb: Start implementing the MediaQueryList interface
2021-09-12 18:25:45 +02:00