mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 05:38:11 +00:00
LibHTML: Add an empty CSS parser.
This commit is contained in:
parent
85d71024f7
commit
891e668e35
14 changed files with 67 additions and 11 deletions
1
LibHTML/CSS/.gitignore
vendored
Normal file
1
LibHTML/CSS/.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
|||
DefaultStyleSheetSource.cpp
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
class StyleDeclaration : public RefCounted<StyleDeclaration> {
|
||||
public:
|
||||
NonnullRefPtr<StyleDeclaration> create(const String& property_name, NonnullRefPtr<StyleValue>&& value)
|
||||
static NonnullRefPtr<StyleDeclaration> create(const String& property_name, NonnullRefPtr<StyleValue>&& value)
|
||||
{
|
||||
return adopt(*new StyleDeclaration(property_name, move(value)));
|
||||
}
|
||||
|
|
|
@ -4,5 +4,8 @@ StyleRule::StyleRule(Vector<Selector>&& selectors, Vector<NonnullRefPtr<StyleDec
|
|||
: m_selectors(move(selectors))
|
||||
, m_declarations(move(declarations))
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
StyleRule::~StyleRule()
|
||||
{
|
||||
}
|
||||
|
|
|
@ -6,7 +6,7 @@
|
|||
|
||||
class StyleRule : public RefCounted<StyleRule> {
|
||||
public:
|
||||
NonnullRefPtr<StyleRule> create(Vector<Selector>&& selectors, Vector<NonnullRefPtr<StyleDeclaration>>&& declarations)
|
||||
static NonnullRefPtr<StyleRule> create(Vector<Selector>&& selectors, Vector<NonnullRefPtr<StyleDeclaration>>&& declarations)
|
||||
{
|
||||
return adopt(*new StyleRule(move(selectors), move(declarations)));
|
||||
}
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
|
||||
class StyleSheet : public RefCounted<StyleSheet> {
|
||||
public:
|
||||
NonnullRefPtr<StyleSheet> create(Vector<NonnullRefPtr<StyleRule>>&& rules)
|
||||
static NonnullRefPtr<StyleSheet> create(Vector<NonnullRefPtr<StyleRule>>&& rules)
|
||||
{
|
||||
return adopt(*new StyleSheet(move(rules)));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue