mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 02:17:35 +00:00
LibWeb: Make CSSRule and CSSRuleList available to JavaScript :^)
This patch makes both of these classes inherit from RefCounted and Bindings::Wrappable, plus some minimal rejigging to allow us to keep using them internally while also exposing them to web content.
This commit is contained in:
parent
87f0059088
commit
3a4565beec
15 changed files with 64 additions and 13 deletions
|
@ -64,8 +64,9 @@ void CSSLoader::resource_did_load()
|
|||
});
|
||||
|
||||
// Transfer the rules from the successfully parsed sheet into the sheet we've already inserted.
|
||||
// FIXME: @import rules need work.
|
||||
if (!was_imported) {
|
||||
m_style_sheet->rules() = sheet->rules();
|
||||
m_style_sheet->set_rules(sheet->rules());
|
||||
}
|
||||
|
||||
if (on_load)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue