[Webkit-unassigned] [Bug 35791] 2x execCommand ReadAV at NULL

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sun Apr 4 23:21:15 PDT 2010


--- Comment #9 from MORITA Hajime <morrita at google.com>  2010-04-04 23:21:15 PST ---
Darin, thank you for your feedback.

> Could you explain why inDocument is the right check? The node could be
> somewhere far away in the same document, say in an absolute positioned element,
> and that wouldn't be good. 
In applyBlockStyle(), we assume that nextParagraphStart and paragraphStart
start with a valid, non-orphan node (or null node). 
Such assumption should be OK because these are created from current selection 
and every VisibleSelections are validated. 
Based on such assumption, what we do here is just discarding invalid 
VisiblePosition and re-creating valid one.

The VisiblePosition can become invalid because
sometimes modify the tree to make it ready to apply style, 
And nodes are possibly removed during the process.

Another approach may be making moveParagraphContentsToNewBlockIfNecessary() not
to remove
any nodes. But I'm not sure it is feasible.

Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the webkit-unassigned mailing list