gecko-dev/editor
Masayuki Nakano 0fadf6b9da Bug 1467796 - part 3: Make mozInlineSpellChecker::ReplaceWord() use TextEditor::ReplaceTextAsAction() r=m_kato,smaug
mozInlineSpellChecker::ReplaceWord() is used for replacing misspelled word
with a word.  So, this is necessary to be distinguished from insertText
command when we implement InputEvent.inputType.  So, we should make it
use TextEditor::ReplaceTextAsAction() instead (same as autocomplete).

This patch makes TextEditor::ReplaceTextAsAction() take optional argument
to make callers can specify replace range.  Then, the range is a spellchecker
selection range if the caller is mozInlineSpellChecker::ReplaceWord().
Prior to this patch, it clones the range for normal selection, but it's
expensive and we may be able to reuse cached range of Selection in this case.
So, this patch makes Selection::AddRangeInternal() checks if given range is
in another Selection and use mCachedRange as far as possible.

MozReview-Commit-ID: JIOTTsxlj4Q

--HG--
extra : rebase_source : 7c26b0255f08608ebe8c7045c9bcdca1dc70cadf
2018-07-04 22:51:55 +09:00
..
composer Bug 1446940 part 5. Stop getting docshells from windows via getInterface in dom/editor/etc code. r=kmag 2018-08-01 13:07:11 -04:00
libeditor Bug 1467796 - part 3: Make mozInlineSpellChecker::ReplaceWord() use TextEditor::ReplaceTextAsAction() r=m_kato,smaug 2018-07-04 22:51:55 +09:00
reftests Bug 1443902 - Reinitilize selection after destroying nsIEditingSession. r=masayuki 2018-07-09 16:53:47 +09:00
spellchecker Bug 1446940 part 5. Stop getting docshells from windows via getInterface in dom/editor/etc code. r=kmag 2018-08-01 13:07:11 -04:00
txmgr Bug 1473515 - Make AutoDisableUndo restores enabled state of undo/redo with previous number of maximum transactions r=m_kato 2018-07-05 19:44:23 +09:00
AsyncSpellCheckTestHelper.jsm Bug 1446940 part 5. Stop getting docshells from windows via getInterface in dom/editor/etc code. r=kmag 2018-08-01 13:07:11 -04:00
moz.build
nsEditorCID.h
nsIDocumentStateListener.idl
nsIEditActionListener.idl
nsIEditor.idl Bug 1467693 - Merge EditorBase::SwitchTextDirection() and EditorBase::SwitchTextDirectionTo() r=m_kato 2018-06-07 23:26:59 +09:00
nsIEditorMailSupport.idl Bug 1264876 - Remove StripCites() from nsIEditorMailSupport r=m_kato 2018-07-19 16:55:31 +09:00
nsIEditorObserver.idl
nsIEditorSpellCheck.idl
nsIEditorStyleSheets.idl Bug 1470361: Remove nsIEditorStyleSheets.addStyleSheet / removeStyleSheet / replaceStyleSheet. r=m_kato 2018-06-25 10:46:38 +02:00
nsIEditorUtils.idl
nsIHTMLAbsPosEditor.idl
nsIHTMLEditor.idl Bug 1476906 - Change nsIHTMLEditor::ReplaceHeadContentsWithHTML() to a non-virtual method of HTMLEditor r=m_kato 2018-07-19 21:31:19 +09:00
nsIHTMLInlineTableEditor.idl
nsIHTMLObjectResizer.idl
nsIPlaintextEditor.idl
nsITableEditor.idl
nsIURIRefObject.idl