mozilla/editor/base/nsEditorShell.cpp
- Make sure mSpellChecker is zeroed in Shutdown() just in case something went wrong.
mozilla/editor/txtsvc/src/nsTextServicesDocument.cpp
- Added checks to prevent iterating over a collapsed selection in FistSelectedBlock() and LastSelectedBlock().
r=brade@netscape.com sr,a=sfraser@netscape.com
fix for bug 45662 (updating range impl to dom spec)
fix for some edge case selection issues invloving multiple windows, no bug #
but saari knows about this.
r: sfraser, jfrancis, mjudge, saari
a: beppe
Modified First/LastSelectedBlock() to check if a range is collapsed before
trying to iterate over it.
editor/txtsvc/src/nsTextServicesDocument.cpp
r=jfrancis@netscape.coma=beppe@netscape.com
mozilla/editor/base/nsEditorShell.cpp
mozilla/editor/idl/nsIEditorSpellCheck.idl
- Modified StartSpellChecking() so that it no longer calls
NextMisspelledWord().
- Renamed Start/CloseSpellChecking() to Init/UninitSpellChecker().
- Changed prototype of GetCurrentDictionary() in the idl file.
- Replaced all references of NS_SPELLCHECKER_CID with NS_SPELLCHECKER_PROGID.
mozilla/editor/txtsvc/public/nsISpellChecker.h
- Added NS_SPELLCHECKER_PROGID.
mozilla/editor/txtsvc/public/nsTextServicesCID.h
- Removed NS_SPELLCHECKER_CID.
mozilla/editor/ui/composer/content/ComposerCommands.js
- Replaced all calls to Start/CloseSpellChecking() with
Init/UninitSpellChecker().
- We now call GetNextMisspelledWord() after initing the spellchecker.
mozilla/editor/ui/dialogs/content/EdSpellCheck.js
- Dialog now assumes the spellchecker language has been set before the
dialog is invoked.
- Fixed Recheck() so that it now sets the language.
- Modified DeleteNode() to increment nodeIndex to prevent
an infinite while loop.
- nsIContentIterator::Next() and Prev() now return NS_OK
if you iterate past the end of the list. Modified all
calls to Next() and Prev() so we can catch any errors.
r=jfrancis@netscape.com
Modified all body methods to deal with the body node for HTML documents,
and the document root node for all other types of documents. Renamed
all body methods.
r=sfraser@netscape.com
* added focus listener. Doesn't do much yet, but when focus notifications start appearing, we'll be ready for them. The code is in
place to hide selection when we lose focus and paint selection when we get focus. That's probably not quite right, but it's a start.
We will need to be able to determine the distinction between losing focus to another control within our app, and losing focus to
another app.
* added support for disabled and readonly states in the editor. This is accomplished by having flags set by the client, and letting the
rules system deal with those flags. The flags I added are:
TEXT_EDITOR_FLAG_PLAINTEXT 0x01 // only plain text editing is allowed
TEXT_EDITOR_FLAG_SINGLELINE 0x02 // enter key and CR-LF handled specially
TEXT_EDITOR_FLAG_PASSWORD 0x04 // text is not entered into content, only a representative character
TEXT_EDITOR_FLAG_READONLY 0x08 // editing events are disabled. Editor may still accept focus.
TEXT_EDITOR_FLAG_DISALBED 0x10 // all events are disabled (like scrolling). Editor will not accept focus.
* added WillInsertBreak/DidInsertBreak into text rules, so flags could be checked. This gets us readonly, disabled, and single line
behavior.
* cleaned up the code that allocates, registers, and destroys event listeners. Thanks to Kin and Simon for cleaning up the
ownership model on the listeners, it was a big help.
* added support for a max text length. You can now tell the text editor, be no bigger than n characters.