mirror of
https://github.com/RGBCube/serenity
synced 2025-05-23 18:15:06 +00:00
LibWeb: Move CSS Parser into new Web::CSS::Parser namespace
The goal here is to move the parser-internal classes into this namespace so they can have more convenient names without causing collisions. The Parser itself won't collide, and would be more convenient to just remain `CSS::Parser`, but having a namespace and a class with the same name makes C++ unhappy.
This commit is contained in:
parent
1304bf5a21
commit
c449cabae3
23 changed files with 61 additions and 58 deletions
|
@ -17,7 +17,7 @@ namespace Web::DOM {
|
|||
|
||||
ExceptionOr<RefPtr<Element>> ParentNode::query_selector(StringView selector_text)
|
||||
{
|
||||
auto maybe_selectors = parse_selector(CSS::ParsingContext(*this), selector_text);
|
||||
auto maybe_selectors = parse_selector(CSS::Parser::ParsingContext(*this), selector_text);
|
||||
if (!maybe_selectors.has_value())
|
||||
return DOM::SyntaxError::create("Failed to parse selector");
|
||||
|
||||
|
@ -40,7 +40,7 @@ ExceptionOr<RefPtr<Element>> ParentNode::query_selector(StringView selector_text
|
|||
|
||||
ExceptionOr<NonnullRefPtr<NodeList>> ParentNode::query_selector_all(StringView selector_text)
|
||||
{
|
||||
auto maybe_selectors = parse_selector(CSS::ParsingContext(*this), selector_text);
|
||||
auto maybe_selectors = parse_selector(CSS::Parser::ParsingContext(*this), selector_text);
|
||||
if (!maybe_selectors.has_value())
|
||||
return DOM::SyntaxError::create("Failed to parse selector");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue