mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-16 23:05:42 +00:00
Bug 1182963 - Use nsTHashTable::Iterator in FramePropertyTable. r=njn
--HG-- extra : commitid : 6i0btK6r2hV extra : rebase_source : 61febc3863f0f87999d813a7c8afde43a6de161b
This commit is contained in:
parent
dfa97f6d66
commit
10aaca0ef1
@ -212,20 +212,16 @@ FramePropertyTable::DeleteAllFor(nsIFrame* aFrame)
|
||||
mEntries.RawRemoveEntry(entry);
|
||||
}
|
||||
|
||||
/* static */ PLDHashOperator
|
||||
FramePropertyTable::DeleteEnumerator(Entry* aEntry, void* aArg)
|
||||
{
|
||||
DeleteAllForEntry(aEntry);
|
||||
return PL_DHASH_REMOVE;
|
||||
}
|
||||
|
||||
void
|
||||
FramePropertyTable::DeleteAll()
|
||||
{
|
||||
mLastFrame = nullptr;
|
||||
mLastEntry = nullptr;
|
||||
|
||||
mEntries.EnumerateEntries(DeleteEnumerator, nullptr);
|
||||
for (auto iter = mEntries.Iter(); !iter.Done(); iter.Next()) {
|
||||
DeleteAllForEntry(iter.Get());
|
||||
}
|
||||
mEntries.Clear();
|
||||
}
|
||||
|
||||
size_t
|
||||
|
@ -204,7 +204,6 @@ protected:
|
||||
};
|
||||
|
||||
static void DeleteAllForEntry(Entry* aEntry);
|
||||
static PLDHashOperator DeleteEnumerator(Entry* aEntry, void* aArg);
|
||||
|
||||
nsTHashtable<Entry> mEntries;
|
||||
nsIFrame* mLastFrame;
|
||||
|
Loading…
Reference in New Issue
Block a user