Closed Bug 543651 Opened 12 years ago Closed 2 years ago
Hang [@ ns
HTMLEdit Rules::Get Nodes For Operation] with exec Command insert Paragraph
No description provided.
Is this a regression?
(In reply to comment #1) > Is this a regression? No... The same bug appears in 1.9.2 (and judging from the history of the code involved, it should date back to the original Mozilla days!) So I actually looked into why this happens. Here's the culprit: <http://mxr.mozilla.org/mozilla-central/source/editor/libeditor/html/nsHTMLEditRules.cpp#5944> This block of code causes the array of nodes to operate on to grow excessively in each pass over insertParagraph on this test case. I tried to think of why this is needed, but couldn't come up with any reasons. The CVS blame for the original code <http://bonsai.mozilla.org/cvsview2.cgi?diff_mode=context&whitespace_mode=show&root=/cvsroot&subdir=mozilla/editor/libeditor/html&command=DIFF_FRAMESET&file=nsHTMLEditRules.cpp&rev2=1.112&rev1=1.111> has these comments: lots of improvements to block transformations: 1) looks inside inlines for breaks; 2) fixes the "extra break when unlisting" bug 3) changing paragraph style to normal consistently gets breaks 4) any splitting needed occurs when blocks inserted plus a lot of small bug fixes This doesn't really explain why this code is necessary, but it's also scares me of changing this behavior, since it could lead to some obscure result which may break something on the web. Given the above, and the fact that it should probably be possible for other slightly more complicated test cases to trigger this pathological testcase in slightly different ways, I'm going to retract my suggestion that this should block. Please nom it if you disagree.
blocking2.0: ? → ---
Status: NEW → RESOLVED
Closed: 2 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.