mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-29 20:07:30 +09:00
Issue #2112 - Part 2: Stub out Servo functions
This commit is contained in:
parent
656ee639c5
commit
88ac168f96
8 changed files with 77 additions and 1228 deletions
|
|
@ -16,30 +16,11 @@ ServoElementSnapshot::ServoElementSnapshot(Element* aElement)
|
|||
, mExplicitRestyleHint(nsRestyleHint(0))
|
||||
, mExplicitChangeHint(nsChangeHint(0))
|
||||
{
|
||||
mIsHTMLElementInHTMLDocument =
|
||||
aElement->IsHTMLElement() && aElement->IsInHTMLDocument();
|
||||
mIsInChromeDocument =
|
||||
nsContentUtils::IsChromeDoc(aElement->OwnerDoc());
|
||||
}
|
||||
|
||||
void
|
||||
ServoElementSnapshot::AddAttrs(Element* aElement)
|
||||
{
|
||||
MOZ_ASSERT(aElement);
|
||||
|
||||
if (HasAny(Flags::Attributes)) {
|
||||
return;
|
||||
}
|
||||
|
||||
uint32_t attrCount = aElement->GetAttrCount();
|
||||
const nsAttrName* attrName;
|
||||
for (uint32_t i = 0; i < attrCount; ++i) {
|
||||
attrName = aElement->GetAttrNameAt(i);
|
||||
const nsAttrValue* attrValue =
|
||||
aElement->GetParsedAttr(attrName->LocalName(), attrName->NamespaceID());
|
||||
mAttrs.AppendElement(ServoAttrSnapshot(*attrName, *attrValue));
|
||||
}
|
||||
mContains |= Flags::Attributes;
|
||||
}
|
||||
|
||||
} // namespace mozilla
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue