summaryrefslogtreecommitdiffstats
path: root/dom/html/nsGenericHTMLElement.cpp
diff options
context:
space:
mode:
authorGaming4JC <g4jc@hyperbola.info>2020-01-04 19:48:30 -0500
committerGaming4JC <g4jc@hyperbola.info>2020-01-26 15:50:18 -0500
commitcc533eaee5b800a534b93484598779debcdf5591 (patch)
treef4613faeda690275556065ad825c1c249e155afe /dom/html/nsGenericHTMLElement.cpp
parent59c26110c1124844b5c6820573a8cb4807f1151a (diff)
downloadUXP-cc533eaee5b800a534b93484598779debcdf5591.tar
UXP-cc533eaee5b800a534b93484598779debcdf5591.tar.gz
UXP-cc533eaee5b800a534b93484598779debcdf5591.tar.lz
UXP-cc533eaee5b800a534b93484598779debcdf5591.tar.xz
UXP-cc533eaee5b800a534b93484598779debcdf5591.zip
Bug 1377993 - Make node slots less memory hungry in common cases.
Tag UXP Issue #1344
Diffstat (limited to 'dom/html/nsGenericHTMLElement.cpp')
-rw-r--r--dom/html/nsGenericHTMLElement.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/dom/html/nsGenericHTMLElement.cpp b/dom/html/nsGenericHTMLElement.cpp
index 2f890325a..cbf97f1ea 100644
--- a/dom/html/nsGenericHTMLElement.cpp
+++ b/dom/html/nsGenericHTMLElement.cpp
@@ -497,7 +497,7 @@ nsGenericHTMLElement::BindToTree(nsIDocument* aDocument, nsIContent* aParent,
// We need to consider a labels element is moved to another subtree
// with different root, it needs to update labels list and its root
// as well.
- nsDOMSlots* slots = GetExistingDOMSlots();
+ nsExtendedDOMSlots* slots = GetExistingExtendedDOMSlots();
if (slots && slots->mLabelsList) {
slots->mLabelsList->MaybeResetRoot(SubtreeRoot());
}
@@ -524,7 +524,7 @@ nsGenericHTMLElement::UnbindFromTree(bool aDeep, bool aNullParent)
// We need to consider a labels element is removed from tree,
// it needs to update labels list and its root as well.
- nsDOMSlots* slots = GetExistingDOMSlots();
+ nsExtendedDOMSlots* slots = GetExistingExtendedDOMSlots();
if (slots && slots->mLabelsList) {
slots->mLabelsList->MaybeResetRoot(SubtreeRoot());
}
@@ -1730,7 +1730,7 @@ nsGenericHTMLElement::Labels()
{
MOZ_ASSERT(IsLabelable(),
"Labels() only allow labelable elements to use it.");
- nsDOMSlots* slots = DOMSlots();
+ nsExtendedDOMSlots* slots = ExtendedDOMSlots();
if (!slots->mLabelsList) {
slots->mLabelsList = new nsLabelsNodeList(SubtreeRoot(), MatchLabelsElement,