зеркало из https://github.com/mozilla/gecko-dev.git
Bug 380716, Crash [@ nsContentUtils::ContentIsDescendantOf], r+sr=jst
This commit is contained in:
Родитель
6b77e511dd
Коммит
66b98ebaff
|
@ -1904,13 +1904,17 @@ nsGenericElement::doPreHandleEvent(nsIContent* aContent,
|
||||||
(aVisitor.mEvent->originalTarget == aContent &&
|
(aVisitor.mEvent->originalTarget == aContent &&
|
||||||
(aVisitor.mRelatedTargetIsInAnon = IsInAnonContent(relatedTarget)))) {
|
(aVisitor.mRelatedTargetIsInAnon = IsInAnonContent(relatedTarget)))) {
|
||||||
nsIContent* nonAnon = FindFirstNonAnonContent(aContent);
|
nsIContent* nonAnon = FindFirstNonAnonContent(aContent);
|
||||||
nsIContent* nonAnonRelated = FindFirstNonAnonContent(relatedTarget);
|
if (nonAnon) {
|
||||||
if (nonAnon == nonAnonRelated ||
|
nsIContent* nonAnonRelated = FindFirstNonAnonContent(relatedTarget);
|
||||||
nsContentUtils::ContentIsDescendantOf(nonAnonRelated, nonAnon)) {
|
if (nonAnonRelated) {
|
||||||
aVisitor.mParentTarget = nsnull;
|
if (nonAnon == nonAnonRelated ||
|
||||||
// Event should not propagate to non-anon content.
|
nsContentUtils::ContentIsDescendantOf(nonAnonRelated, nonAnon)) {
|
||||||
aVisitor.mCanHandle = isAnonForEvents;
|
aVisitor.mParentTarget = nsnull;
|
||||||
return NS_OK;
|
// Event should not propagate to non-anon content.
|
||||||
|
aVisitor.mCanHandle = isAnonForEvents;
|
||||||
|
return NS_OK;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Загрузка…
Ссылка в новой задаче