Bug 1613349 - Rename nsINode::DeleteProperty to RemoveProperty. r=smaug

And the related methods as well.

Differential Revision: https://phabricator.services.mozilla.com/D61768

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Emilio Cobos Álvarez 2020-02-06 16:06:49 +00:00
parent c5c0ef9787
commit 69c87f6cb2
26 changed files with 89 additions and 88 deletions

View File

@ -31,7 +31,7 @@ CSSPseudoElement::CSSPseudoElement(dom::Element* aElement,
CSSPseudoElement::~CSSPseudoElement() {
// Element might have been unlinked already, so we have to do null check.
if (mOriginatingElement) {
mOriginatingElement->DeleteProperty(
mOriginatingElement->RemoveProperty(
GetCSSPseudoElementPropertyAtom(mPseudoType));
}
}

View File

@ -137,7 +137,7 @@ void EffectSet::DestroyEffectSet(dom::Element* aElement,
"Should not destroy an effect set while it is being enumerated");
effectSet = nullptr;
aElement->DeleteProperty(propName);
aElement->RemoveProperty(propName);
}
void EffectSet::UpdateAnimationGeneration(nsPresContext* aPresContext) {

View File

@ -118,7 +118,7 @@ nsresult Attr::SetOwnerDocument(Document* aDocument) {
Document* doc = OwnerDoc();
NS_ASSERTION(doc != aDocument, "bad call to Attr::SetOwnerDocument");
doc->DeleteAllPropertiesFor(this);
doc->RemoveAllPropertiesFor(this);
RefPtr<dom::NodeInfo> newNodeInfo = aDocument->NodeInfoManager()->GetNodeInfo(
mNodeInfo->NameAtom(), mNodeInfo->GetPrefixAtom(),

View File

@ -538,7 +538,7 @@ class nsTextNodeDirectionalityMap {
mElements.Remove(aElement);
aElement->ClearHasDirAutoSet();
aElement->DeleteProperty(nsGkAtoms::dirAutoSetBy);
aElement->RemoveProperty(nsGkAtoms::dirAutoSetBy);
}
void RemoveEntryForProperty(Element* aElement) {
@ -604,7 +604,7 @@ class nsTextNodeDirectionalityMap {
nsTextNodeDirectionalityMap::AddEntryToMap(newTextNode, rootNode);
} else {
rootNode->ClearHasDirAutoSet();
rootNode->DeleteProperty(nsGkAtoms::dirAutoSetBy);
rootNode->RemoveProperty(nsGkAtoms::dirAutoSetBy);
}
return OpRemove;
}
@ -633,7 +633,7 @@ class nsTextNodeDirectionalityMap {
mElements.EnumerateEntries(TakeEntries, &entries);
for (Element* el : entries) {
el->ClearHasDirAutoSet();
el->DeleteProperty(nsGkAtoms::dirAutoSetBy);
el->RemoveProperty(nsGkAtoms::dirAutoSetBy);
}
}

View File

@ -2400,10 +2400,10 @@ nsresult Document::Init() {
return NS_OK;
}
void Document::DeleteAllProperties() { PropertyTable().DeleteAllProperties(); }
void Document::RemoveAllProperties() { PropertyTable().RemoveAllProperties(); }
void Document::DeleteAllPropertiesFor(nsINode* aNode) {
PropertyTable().DeleteAllPropertiesFor(aNode);
void Document::RemoveAllPropertiesFor(nsINode* aNode) {
PropertyTable().RemoveAllPropertiesFor(aNode);
}
bool Document::IsVisibleConsideringAncestors() const {
@ -9364,7 +9364,7 @@ nsINode* Document::AdoptNode(nsINode& aAdoptedNode, ErrorResult& rv) {
if (!sameDocument && oldDocument) {
for (nsINode* node : nodesWithProperties) {
// Remove all properties.
oldDocument->PropertyTable().DeleteAllPropertiesFor(node);
oldDocument->PropertyTable().RemoveAllPropertiesFor(node);
}
}
@ -9375,7 +9375,7 @@ nsINode* Document::AdoptNode(nsINode& aAdoptedNode, ErrorResult& rv) {
nsPropertyTable& oldTable = oldDocument->PropertyTable();
nsPropertyTable& newTable = PropertyTable();
for (nsINode* node : nodesWithProperties) {
rv = oldTable.TransferOrDeleteAllPropertiesFor(node, newTable);
rv = oldTable.TransferOrRemoveAllPropertiesFor(node, newTable);
}
if (rv.Failed()) {

View File

@ -2237,8 +2237,8 @@ class Document : public nsINode,
*/
int32_t GetDefaultNamespaceID() const { return mDefaultElementType; }
void DeleteAllProperties();
void DeleteAllPropertiesFor(nsINode* aNode);
void RemoveAllProperties();
void RemoveAllPropertiesFor(nsINode* aNode);
nsPropertyTable& PropertyTable() { return mPropertyTable; }

View File

@ -455,7 +455,7 @@ void Element::UnlockStyleStates(EventStates aStates) {
locks->mLocks &= ~aStates;
if (locks->mLocks.IsEmpty()) {
DeleteProperty(nsGkAtoms::lockedStyleStates);
RemoveProperty(nsGkAtoms::lockedStyleStates);
ClearHasLockedStyleStates();
delete locks;
} else {
@ -469,7 +469,7 @@ void Element::UnlockStyleStates(EventStates aStates) {
void Element::ClearStyleStateLocks() {
StyleStateLocks locks = LockedStyleStates();
DeleteProperty(nsGkAtoms::lockedStyleStates);
RemoveProperty(nsGkAtoms::lockedStyleStates);
ClearHasLockedStyleStates();
NotifyStyleStateChange(locks.mLocks);
@ -1735,14 +1735,14 @@ void Element::UnbindFromTree(bool aNullParent) {
//
// FIXME (Bug 522599): Need a test for this.
if (MayHaveAnimations()) {
DeleteProperty(nsGkAtoms::transitionsOfBeforeProperty);
DeleteProperty(nsGkAtoms::transitionsOfAfterProperty);
DeleteProperty(nsGkAtoms::transitionsOfMarkerProperty);
DeleteProperty(nsGkAtoms::transitionsProperty);
DeleteProperty(nsGkAtoms::animationsOfBeforeProperty);
DeleteProperty(nsGkAtoms::animationsOfAfterProperty);
DeleteProperty(nsGkAtoms::animationsOfMarkerProperty);
DeleteProperty(nsGkAtoms::animationsProperty);
RemoveProperty(nsGkAtoms::transitionsOfBeforeProperty);
RemoveProperty(nsGkAtoms::transitionsOfAfterProperty);
RemoveProperty(nsGkAtoms::transitionsOfMarkerProperty);
RemoveProperty(nsGkAtoms::transitionsProperty);
RemoveProperty(nsGkAtoms::animationsOfBeforeProperty);
RemoveProperty(nsGkAtoms::animationsOfAfterProperty);
RemoveProperty(nsGkAtoms::animationsOfMarkerProperty);
RemoveProperty(nsGkAtoms::animationsProperty);
if (document) {
if (nsPresContext* presContext = document->GetPresContext()) {
// We have to clear all pending restyle requests for the animations on

View File

@ -1239,14 +1239,14 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_BEGIN(FragmentOrElement)
nsStaticAtom* const* props =
Element::HTMLSVGPropertiesToTraverseAndUnlink();
for (uint32_t i = 0; props[i]; ++i) {
tmp->DeleteProperty(props[i]);
tmp->RemoveProperty(props[i]);
}
}
if (tmp->MayHaveAnimations()) {
nsAtom** effectProps = EffectSet::GetEffectSetPropertyAtoms();
for (uint32_t i = 0; effectProps[i]; ++i) {
tmp->DeleteProperty(effectProps[i]);
tmp->RemoveProperty(effectProps[i]);
}
}
}

View File

@ -215,8 +215,8 @@ nsresult nsINode::SetProperty(nsAtom* aPropertyName, void* aValue,
return rv;
}
void nsINode::DeleteProperty(const nsAtom* aPropertyName) {
OwnerDoc()->PropertyTable().DeleteProperty(this, aPropertyName);
void nsINode::RemoveProperty(const nsAtom* aPropertyName) {
OwnerDoc()->PropertyTable().RemoveProperty(this, aPropertyName);
}
void* nsINode::TakeProperty(const nsAtom* aPropertyName, nsresult* aStatus) {
@ -621,13 +621,13 @@ void nsINode::LastRelease() {
// Delete all properties before tearing down the document. Some of the
// properties are bound to nsINode objects and the destructor functions of
// the properties may want to use the owner document of the nsINode.
AsDocument()->DeleteAllProperties();
AsDocument()->RemoveAllProperties();
} else {
if (HasProperties()) {
// Strong reference to the document so that deleting properties can't
// delete the document.
nsCOMPtr<Document> document = OwnerDoc();
document->DeleteAllPropertiesFor(this);
document->RemoveAllPropertiesFor(this);
}
// I wonder whether it's faster to do the HasFlag check first....
@ -1380,8 +1380,8 @@ void nsINode::Unlink(nsINode* tmp) {
}
if (tmp->HasProperties()) {
tmp->DeleteProperty(nsGkAtoms::keepobjectsalive);
tmp->DeleteProperty(nsGkAtoms::accessiblenode);
tmp->RemoveProperty(nsGkAtoms::keepobjectsalive);
tmp->RemoveProperty(nsGkAtoms::accessiblenode);
}
}

View File

@ -864,12 +864,12 @@ class nsINode : public mozilla::dom::EventTarget {
}
/**
* Destroys a property associated with this node. The value is destroyed
* using the destruction function given when that value was set.
* Removes a property associated with this node. The value is destroyed using
* the destruction function given when that value was set.
*
* @param aPropertyName name of property to destroy.
*/
void DeleteProperty(const nsAtom* aPropertyName);
void RemoveProperty(const nsAtom* aPropertyName);
/**
* Take a property associated with this node. The value will not be destroyed

View File

@ -34,7 +34,7 @@ class nsPropertyTable::PropertyList {
// Removes the property associated with the given object, and destroys
// the property value
bool DeletePropertyFor(nsPropertyOwner aObject);
bool RemovePropertyFor(nsPropertyOwner aObject);
// Destroy all remaining properties (without removing them)
void Destroy();
@ -48,12 +48,12 @@ class nsPropertyTable::PropertyList {
NSPropertyDtorFunc mDtorFunc; // property specific value dtor function
void* mDtorData; // pointer to pass to dtor
bool mTransfer; // whether to transfer in
// TransferOrDeleteAllPropertiesFor
// TransferOrRemoveAllPropertiesFor
PropertyList* mNext;
};
void nsPropertyTable::DeleteAllProperties() {
void nsPropertyTable::RemoveAllProperties() {
while (mPropertyList) {
PropertyList* tmp = mPropertyList;
@ -63,13 +63,13 @@ void nsPropertyTable::DeleteAllProperties() {
}
}
void nsPropertyTable::DeleteAllPropertiesFor(nsPropertyOwner aObject) {
void nsPropertyTable::RemoveAllPropertiesFor(nsPropertyOwner aObject) {
for (PropertyList* prop = mPropertyList; prop; prop = prop->mNext) {
prop->DeletePropertyFor(aObject);
prop->RemovePropertyFor(aObject);
}
}
nsresult nsPropertyTable::TransferOrDeleteAllPropertiesFor(
nsresult nsPropertyTable::TransferOrRemoveAllPropertiesFor(
nsPropertyOwner aObject, nsPropertyTable& aOtherTable) {
nsresult rv = NS_OK;
for (PropertyList* prop = mPropertyList; prop; prop = prop->mNext) {
@ -81,15 +81,15 @@ nsresult nsPropertyTable::TransferOrDeleteAllPropertiesFor(
prop->mDtorFunc, prop->mDtorData,
prop->mTransfer);
if (NS_FAILED(rv)) {
DeleteAllPropertiesFor(aObject);
aOtherTable.DeleteAllPropertiesFor(aObject);
RemoveAllPropertiesFor(aObject);
aOtherTable.RemoveAllPropertiesFor(aObject);
break;
}
prop->mObjectValueMap.RemoveEntry(entry);
}
} else {
prop->DeletePropertyFor(aObject);
prop->RemovePropertyFor(aObject);
}
}
@ -189,13 +189,15 @@ nsresult nsPropertyTable::SetPropertyInternal(
return result;
}
nsresult nsPropertyTable::DeleteProperty(nsPropertyOwner aObject,
nsresult nsPropertyTable::RemoveProperty(nsPropertyOwner aObject,
const nsAtom* aPropertyName) {
MOZ_ASSERT(aPropertyName && aObject, "unexpected null param");
PropertyList* propertyList = GetPropertyListFor(aPropertyName);
if (propertyList) {
if (propertyList->DeletePropertyFor(aObject)) return NS_OK;
if (propertyList->RemovePropertyFor(aObject)) {
return NS_OK;
}
}
return NS_PROPTABLE_PROP_NOT_THERE;
@ -238,7 +240,7 @@ void nsPropertyTable::PropertyList::Destroy() {
}
}
bool nsPropertyTable::PropertyList::DeletePropertyFor(nsPropertyOwner aObject) {
bool nsPropertyTable::PropertyList::RemovePropertyFor(nsPropertyOwner aObject) {
auto entry =
static_cast<PropertyListMapEntry*>(mObjectValueMap.Search(aObject));
if (!entry) return false;

View File

@ -83,10 +83,10 @@ class nsPropertyTable {
}
/**
* Delete the property |aPropertyName| in the global category for object
* Remove the property |aPropertyName| in the global category for object
* |aObject|. The property's destructor function will be called.
*/
nsresult DeleteProperty(nsPropertyOwner aObject, const nsAtom* aPropertyName);
nsresult RemoveProperty(nsPropertyOwner aObject, const nsAtom* aPropertyName);
/**
* Remove the property |aPropertyName| in the global category for object
@ -100,19 +100,19 @@ class nsPropertyTable {
}
/**
* Deletes all of the properties for object |aObject|, calling the
* destructor function for each property.
* Removes all of the properties for object |aObject|, calling the destructor
* function for each property.
*/
void DeleteAllPropertiesFor(nsPropertyOwner aObject);
void RemoveAllPropertiesFor(nsPropertyOwner aObject);
/**
* Transfers all properties for object |aObject| that were set with the
* |aTransfer| argument as true to |aTable|. Deletes the other properties
* for object |aObject|, calling the destructor function for each property.
* If transfering a property fails, this deletes all the properties for
* object |aObject|.
* |aTransfer| argument as true to |aTable|. Removes the other properties for
* object |aObject|, calling the destructor function for each property.
* If transfering a property fails, this deletes all the properties for object
* |aObject|.
*/
nsresult TransferOrDeleteAllPropertiesFor(nsPropertyOwner aObject,
nsresult TransferOrRemoveAllPropertiesFor(nsPropertyOwner aObject,
nsPropertyTable& aOtherTable);
/**
@ -131,13 +131,13 @@ class nsPropertyTable {
void EnumerateAll(NSPropertyFunc aCallback, void* aData);
/**
* Deletes all of the properties for all objects in the property
* table, calling the destructor function for each property.
* Removes all of the properties for all objects in the property table,
* calling the destructor function for each property.
*/
void DeleteAllProperties();
void RemoveAllProperties();
nsPropertyTable() : mPropertyList(nullptr) {}
~nsPropertyTable() { DeleteAllProperties(); }
~nsPropertyTable() { RemoveAllProperties(); }
/**
* Function useable as destructor function for property data that is

View File

@ -554,8 +554,7 @@ void XULKeySetGlobalKeyListener::DetachKeyHandler(Element* aElementTarget) {
static_cast<XULKeySetGlobalKeyListener*>(handler)
->RemoveKeyboardEventListenersFrom(manager);
aElementTarget->DeleteProperty(nsGkAtoms::listener);
aElementTarget->RemoveProperty(nsGkAtoms::listener);
}
XULKeySetGlobalKeyListener::XULKeySetGlobalKeyListener(Element* aElement,

View File

@ -110,7 +110,7 @@ nsresult HTMLLabelElement::PostHandleEvent(EventChainPostVisitor& aVisitor) {
bool dragSelect = false;
if (mouseDownPoint) {
LayoutDeviceIntPoint dragDistance = *mouseDownPoint;
DeleteProperty(nsGkAtoms::labelMouseDownPtProperty);
RemoveProperty(nsGkAtoms::labelMouseDownPtProperty);
dragDistance -= mouseEvent->mRefPoint;
const int CLICK_DISTANCE = 2;

View File

@ -169,8 +169,8 @@ void DecoderDoctorDocumentWatcher::RemovePropertyFromDocument() {
"DecoderDoctorDocumentWatcher[%p, "
"doc=%p]::RemovePropertyFromDocument()\n",
watcher, watcher->mDocument);
// This will remove the property and call our DestroyPropertyCallback.
mDocument->DeleteProperty(nsGkAtoms::decoderDoctor);
// This will call our DestroyPropertyCallback.
mDocument->RemoveProperty(nsGkAtoms::decoderDoctor);
}
// Callback for property destructors. |aObject| is the object

View File

@ -43,7 +43,7 @@ void nsXMLElement::UnbindFromTree(bool aNullParent) {
if (property) {
MOZ_ASSERT(GetParent());
MOZ_ASSERT(GetParent()->IsElement());
GetParent()->DeleteProperty(property);
GetParent()->RemoveProperty(property);
}
Element::UnbindFromTree(aNullParent);
}

View File

@ -79,7 +79,7 @@ class ManualNACPtr final {
if (nac) {
nac->RemoveElement(aAnonymousContent);
if (nac->IsEmpty()) {
parentContent->DeleteProperty(nsGkAtoms::manualNACProperty);
parentContent->RemoveProperty(nsGkAtoms::manualNACProperty);
}
}

View File

@ -1227,7 +1227,7 @@ void PresShell::Destroy() {
EventHandler::OnPresShellDestroy(mDocument);
if (mContentToScrollTo) {
mContentToScrollTo->DeleteProperty(nsGkAtoms::scrolling);
mContentToScrollTo->RemoveProperty(nsGkAtoms::scrolling);
mContentToScrollTo = nullptr;
}
@ -3378,7 +3378,7 @@ nsresult PresShell::ScrollContentIntoView(nsIContent* aContent,
NS_ASSERTION(mDidInitialize, "should have done initial reflow by now");
if (mContentToScrollTo) {
mContentToScrollTo->DeleteProperty(nsGkAtoms::scrolling);
mContentToScrollTo->RemoveProperty(nsGkAtoms::scrolling);
}
mContentToScrollTo = aContent;
ScrollIntoViewData* data = new ScrollIntoViewData();
@ -3416,7 +3416,7 @@ void PresShell::DoScrollContentIntoView() {
nsIFrame* frame = mContentToScrollTo->GetPrimaryFrame();
if (!frame) {
mContentToScrollTo->DeleteProperty(nsGkAtoms::scrolling);
mContentToScrollTo->RemoveProperty(nsGkAtoms::scrolling);
mContentToScrollTo = nullptr;
return;
}
@ -4122,7 +4122,7 @@ void PresShell::DoFlushPendingNotifications(mozilla::ChangesToFlush aFlush) {
if (mContentToScrollTo) {
DoScrollContentIntoView();
if (mContentToScrollTo) {
mContentToScrollTo->DeleteProperty(nsGkAtoms::scrolling);
mContentToScrollTo->RemoveProperty(nsGkAtoms::scrolling);
mContentToScrollTo = nullptr;
}
}

View File

@ -871,7 +871,7 @@ nsFrameConstructorState::~nsFrameConstructorState() {
MOZ_COUNT_DTOR(nsFrameConstructorState);
ProcessFrameInsertionsForAllLists();
for (auto& content : Reversed(mGeneratedContentWithInitializer)) {
content->DeleteProperty(nsGkAtoms::genConInitializerProperty);
content->RemoveProperty(nsGkAtoms::genConInitializerProperty);
}
}

View File

@ -1382,8 +1382,8 @@ bool nsLayoutUtils::GetHighResolutionDisplayPort(nsIContent* aContent,
}
void nsLayoutUtils::RemoveDisplayPort(nsIContent* aContent) {
aContent->DeleteProperty(nsGkAtoms::DisplayPort);
aContent->DeleteProperty(nsGkAtoms::DisplayPortMargins);
aContent->RemoveProperty(nsGkAtoms::DisplayPort);
aContent->RemoveProperty(nsGkAtoms::DisplayPortMargins);
}
void nsLayoutUtils::NotifyPaintSkipTransaction(ViewID aScrollId) {
@ -8990,7 +8990,7 @@ ScrollMetadata nsLayoutUtils::ComputeScrollMetadata(
if (void* paintRequestTime =
aContent->GetProperty(nsGkAtoms::paintRequestTime)) {
metrics.SetPaintRequestTime(*static_cast<TimeStamp*>(paintRequestTime));
aContent->DeleteProperty(nsGkAtoms::paintRequestTime);
aContent->RemoveProperty(nsGkAtoms::paintRequestTime);
}
scrollId = nsLayoutUtils::FindOrCreateIDFor(aContent);
nsRect dp;

View File

@ -4294,11 +4294,11 @@ void nsTextFrame::Init(nsIContent* aContent, nsContainerFrame* aParent,
// Remove any NewlineOffsetProperty or InFlowContentLengthProperty since they
// might be invalid if the content was modified while there was no frame
if (aContent->HasFlag(NS_HAS_NEWLINE_PROPERTY)) {
aContent->DeleteProperty(nsGkAtoms::newline);
aContent->RemoveProperty(nsGkAtoms::newline);
aContent->UnsetFlags(NS_HAS_NEWLINE_PROPERTY);
}
if (aContent->HasFlag(NS_HAS_FLOWLENGTH_PROPERTY)) {
aContent->DeleteProperty(nsGkAtoms::flowlength);
aContent->RemoveProperty(nsGkAtoms::flowlength);
aContent->UnsetFlags(NS_HAS_FLOWLENGTH_PROPERTY);
}
@ -4730,11 +4730,11 @@ void nsTextFrame::NotifyNativeAnonymousTextnodeChange(uint32_t aOldLength) {
nsresult nsTextFrame::CharacterDataChanged(
const CharacterDataChangeInfo& aInfo) {
if (mContent->HasFlag(NS_HAS_NEWLINE_PROPERTY)) {
mContent->DeleteProperty(nsGkAtoms::newline);
mContent->RemoveProperty(nsGkAtoms::newline);
mContent->UnsetFlags(NS_HAS_NEWLINE_PROPERTY);
}
if (mContent->HasFlag(NS_HAS_FLOWLENGTH_PROPERTY)) {
mContent->DeleteProperty(nsGkAtoms::flowlength);
mContent->RemoveProperty(nsGkAtoms::flowlength);
mContent->UnsetFlags(NS_HAS_FLOWLENGTH_PROPERTY);
}
@ -9519,7 +9519,7 @@ void nsTextFrame::ReflowText(nsLineLayout& aLineLayout, nscoord aAvailableWidth,
cachedNewlineOffset->mNewlineOffset = contentNewLineOffset;
}
} else if (cachedNewlineOffset) {
mContent->DeleteProperty(nsGkAtoms::newline);
mContent->RemoveProperty(nsGkAtoms::newline);
mContent->UnsetFlags(NS_HAS_NEWLINE_PROPERTY);
}
@ -10021,7 +10021,7 @@ void nsTextFrame::List(FILE* out, const char* aPrefix, uint32_t aFlags) const {
void nsTextFrame::AdjustOffsetsForBidi(int32_t aStart, int32_t aEnd) {
AddStateBits(NS_FRAME_IS_BIDI);
if (mContent->HasFlag(NS_HAS_FLOWLENGTH_PROPERTY)) {
mContent->DeleteProperty(nsGkAtoms::flowlength);
mContent->RemoveProperty(nsGkAtoms::flowlength);
mContent->UnsetFlags(NS_HAS_FLOWLENGTH_PROPERTY);
}

View File

@ -255,7 +255,7 @@ class nsTextFrame : public nsFrame {
// Setting a non-fluid continuation might affect our flow length (they're
// quite rare so we assume it always does) so we delete our cached value:
if (GetContent()->HasFlag(NS_HAS_FLOWLENGTH_PROPERTY)) {
GetContent()->DeleteProperty(nsGkAtoms::flowlength);
GetContent()->RemoveProperty(nsGkAtoms::flowlength);
GetContent()->UnsetFlags(NS_HAS_FLOWLENGTH_PROPERTY);
}
}
@ -277,7 +277,7 @@ class nsTextFrame : public nsFrame {
// Changing from non-fluid to fluid continuation might affect our flow
// length, so we delete our cached value:
if (GetContent()->HasFlag(NS_HAS_FLOWLENGTH_PROPERTY)) {
GetContent()->DeleteProperty(nsGkAtoms::flowlength);
GetContent()->RemoveProperty(nsGkAtoms::flowlength);
GetContent()->UnsetFlags(NS_HAS_FLOWLENGTH_PROPERTY);
}
}

View File

@ -200,7 +200,7 @@ void LayerActivityTracker::NotifyExpired(LayerActivity* aObject) {
f->RemoveStateBits(NS_FRAME_HAS_LAYER_ACTIVITY_PROPERTY);
f->RemoveProperty(LayerActivityProperty());
} else {
c->DeleteProperty(nsGkAtoms::LayerActivity);
c->RemoveProperty(nsGkAtoms::LayerActivity);
}
}

View File

@ -2906,7 +2906,7 @@ void nsPrintJob::TurnScriptingOn(bool aDoTurnOn) {
&propThere);
if (aDoTurnOn) {
if (propThere != NS_PROPTABLE_PROP_NOT_THERE) {
doc->DeleteProperty(nsGkAtoms::scriptEnabledBeforePrintOrPreview);
doc->RemoveProperty(nsGkAtoms::scriptEnabledBeforePrintOrPreview);
if (go->HasJSGlobal()) {
xpc::Scriptability::Get(go->GetGlobalJSObjectPreserveColor())
.Unblock();

View File

@ -52,7 +52,7 @@ class AnimationCollection
mCalledDestroy = true;
// This will call our destructor.
mElement->DeleteProperty(mElementProperty);
mElement->RemoveProperty(mElementProperty);
}
static void PropertyDtor(void* aObject, nsAtom* aPropertyName,
@ -92,7 +92,7 @@ class AnimationCollection
static nsAtom* GetPropertyAtomForPseudoType(PseudoStyleType aPseudoType);
// We distinguish between destroying this by calling Destroy() vs directly
// calling DeleteProperty on an element.
// calling RemoveProperty on an element.
//
// The former case represents regular updating due to style changes and should
// trigger subsequent restyles.

View File

@ -477,7 +477,7 @@ void nsResizerFrame::RestoreOriginalSize(nsIContent* aContent) {
NS_ASSERTION(sizeInfo, "We set a null sizeInfo!?");
Direction direction = {1, 1};
ResizeContent(aContent, direction, *sizeInfo, nullptr);
aContent->DeleteProperty(nsGkAtoms::_moz_original_size);
aContent->RemoveProperty(nsGkAtoms::_moz_original_size);
}
/* returns a Direction struct containing the horizontal and vertical direction