Ticket #1226 (new defect)

Opened 4 months ago

Last modified 2 months ago

[Confirmed] Hitting enter in certain documents causes the rest of the text to disappear in Firefox 3

Reported by: douglas Owned by: gogo
Priority: normal Milestone: 0.96
Component: Xinha Core Version: trunk
Severity: blocker Keywords:
Cc:

Description

Go to http://xinha.gogo.co.nz/xinha-nightly/examples/ExtendedDemo.html and in HTML mode, insert the followin HTML: "General Resources<br /> <h3>mailing lists</h3>"

Go back to document view, click at the end of the first line and hit enter. The second line will disappear. This is because of a bug in FF3 where getSelection incorrectly reports a selection to the end of the iframe. This has been ticketed with Mozilla at: https://bugzilla.mozilla.org/show_bug.cgi?id=437672

Hopefully they'll fix it before release so that we won't have to patch around their bug.

Change History

Changed 2 months ago by gogo

  • severity changed from major to blocker
  • summary changed from Hitting enter in certain documents causes the rest of the text to disappear in Firefox 3 to [Confirmed] Hitting enter in certain documents causes the rest of the text to disappear in Firefox 3

Hi Douglas, I confirm this behaviour. Very nasty.

You indicate in the bugzilla track that it may be an issue in Xinha to be fixed?

I can reproduce the test case every time on many computers...  You have to go
to HTML mode before inserting the text, then return to document mode, but upon
further inspection, the algorithm behind this page is so poorly written that
I've come to believe it's miswritten, and is just dependent on the behavior
pre-Firefox3, even if that behavior is wrong.  I looked at the code differences
in Firefox, and it's a change in nsRange.cpp which looks like it is a valid
change (Before, trying to create a range in reverse resulted in an invalid
range.  Now, trying to create a range in reverse collapses the range...  I see
this as valid behavior, but I was hoping to wait till the end of the week to
finish my testing...

Were you able to determine a possible fix?

Changed 2 months ago by gogo

This appears to be a bug in what was the ExtendedParagraphs? plugin, and is now modules/Gecko/paraHandlerBest.js

Workaround for now is to set editor.config.mozParaHandler = 'built-in'

Changed 2 months ago by gogo

I meant EnterParagraphs of course.

Note: See TracTickets for help on using tickets.