mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-06 07:48:38 +09:00
Bug 1413619 - Fix insertion point computation when display: contents pseudos are involved.
Tag #1375
This commit is contained in:
parent
9b5061e795
commit
5b1452e120
10 changed files with 192 additions and 243 deletions
|
|
@ -192,17 +192,17 @@ FlattenedChildIterator::Init(bool aIgnoreXBL)
|
|||
}
|
||||
|
||||
bool
|
||||
ExplicitChildIterator::Seek(nsIContent* aChildToFind)
|
||||
ExplicitChildIterator::Seek(const nsIContent* aChildToFind)
|
||||
{
|
||||
if (aChildToFind->GetParent() == mParent &&
|
||||
!aChildToFind->IsRootOfAnonymousSubtree()) {
|
||||
// Fast path: just point ourselves to aChildToFind, which is a
|
||||
// normal DOM child of ours.
|
||||
MOZ_ASSERT(!nsContentUtils::IsContentInsertionPoint(aChildToFind));
|
||||
mChild = aChildToFind;
|
||||
mChild = const_cast<nsIContent*>(aChildToFind);
|
||||
mIndexInInserted = 0;
|
||||
mDefaultChild = nullptr;
|
||||
mIsFirst = false;
|
||||
MOZ_ASSERT(!nsContentUtils::IsContentInsertionPoint(mChild));
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -348,7 +348,7 @@ AllChildrenIterator::Get() const
|
|||
|
||||
|
||||
bool
|
||||
AllChildrenIterator::Seek(nsIContent* aChildToFind)
|
||||
AllChildrenIterator::Seek(const nsIContent* aChildToFind)
|
||||
{
|
||||
if (mPhase == eAtBegin || mPhase == eAtBeforeKid) {
|
||||
mPhase = eAtExplicitKids;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue