mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-07 00:29:15 +00:00
LibWeb: Remove for_first_not_loaded_import_rule()
:^)
This was only used for making sure `@import` rules got loaded, and since they handle that themselves now, we can get rid of all this code!
This commit is contained in:
parent
9d72815deb
commit
6fc1810190
Notes:
sideshowbarker
2024-07-18 01:01:01 +09:00
Author: https://github.com/AtkinsSJ
Commit: 6fc1810190
Pull-request: https://github.com/SerenityOS/serenity/pull/10961
8 changed files with 0 additions and 45 deletions
|
@ -103,29 +103,6 @@ void CSSRuleList::for_each_effective_style_rule(Function<void(CSSStyleRule const
|
|||
}
|
||||
}
|
||||
|
||||
bool CSSRuleList::for_first_not_loaded_import_rule(Function<void(CSSImportRule&)> const& callback)
|
||||
{
|
||||
for (auto& rule : m_rules) {
|
||||
if (rule.type() == CSSRule::Type::Import) {
|
||||
auto& import_rule = verify_cast<CSSImportRule>(rule);
|
||||
if (!import_rule.has_import_result()) {
|
||||
callback(import_rule);
|
||||
return true;
|
||||
}
|
||||
|
||||
if (import_rule.loaded_style_sheet()->for_first_not_loaded_import_rule(callback)) {
|
||||
return true;
|
||||
}
|
||||
} else if (rule.type() == CSSRule::Type::Media) {
|
||||
return verify_cast<CSSMediaRule>(rule).for_first_not_loaded_import_rule(callback);
|
||||
} else if (rule.type() == CSSRule::Type::Supports) {
|
||||
return verify_cast<CSSSupportsRule>(rule).for_first_not_loaded_import_rule(callback);
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
void CSSRuleList::evaluate_media_queries(DOM::Window const& window)
|
||||
{
|
||||
for (auto& rule : m_rules) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue