Chromium Code Reviews
DescriptionFix stale focusedElement in unloaded document.
When appendChild()/adoptNode() moves a node between different documents,
any focused node under moving node will be cleared, but it is done before
"unload" event is dispatched.
So if combined with <iframe>, focusing that frame in "unload" event can
trigger stale focused element reference from the old document tree.
This CL tries to fix that by checking if the element is the owner of
the frame that is being unloaded.
BUG=677690
Review-Url: https://codereview.chromium.org/2692423006
Cr-Commit-Position: refs/heads/master@{#451271}
Committed: https://chromium.googlesource.com/chromium/src/+/b16ecc7508fb9da7626dad7708d04b1f745c54e1
Patch Set 1 #
Total comments: 1
Patch Set 2 : Check nullptr. #
Messages
Total messages: 22 (13 generated)
|
||||||||||||||||||||||||||||