gecko-dev/extensions/spellcheck
Masayuki Nakano 043e93a8ba Bug 1451672 - part 21: Refine TextEditor::TypedText() r=m_kato
According to existing comments, TextEditor::TypedText() and
HTMLEditor::TypedText() are intentional bottleneck to debug.  However, only
for that purpose, it and its internal methods are made virtual.  This really
doesn't make sense.

So, this patch creates TextEditor::OnInputText() for callers of TypedText()
with non-empty string, TextEditor::OnInputParagraphSeparator() for callers
of TypedText() with eTypeBreak (Enter key or insertParagraphSeparator),
HTMLEditor::OnInputLineBreak() for callers of TypedText() with eTypeBR
(Shift + Enter or insertLineBreak).  Additionally, this creates internal
non-virtual methods for XPCOM methods which are used as internal methods of
TypedText().  One is InsertTextAsAction() for nsIPlatintextEditor.insertText().
the other is InsertParagraphSeparator() for nsIPlaintextEditor.insertLineBreak().

Although those new methods are not have "WithTransaction" postfix, they must
be clearer they'll use transactions since user input and actions should be
undo-able.

MozReview-Commit-ID: AmOkMqovIKA

--HG--
extra : rebase_source : 9c0f4b25fa2a36ad2f3394f72eb290824c31d82a
2018-04-16 23:43:36 +09:00
..
hunspell Bug 1448071 - Support UNC paths for spell check dictionaries. r=masayuki 2018-03-23 21:29:16 +09:00
idl Bug 1286877 - do not set c-basic-offset for python-mode; r=gps 2016-07-14 10:16:42 -06:00
locales Bug 1450620 - Add words to en-US dictionary. r=ehsan 2018-04-03 11:42:28 +07:00
src Bug 1451672 - part 21: Refine TextEditor::TypedText() r=m_kato 2018-04-16 23:43:36 +09:00
tests Bug 1454813: Part 2b - Rename SpawnTask.js to AddTask.js. r=florian 2018-04-18 11:43:45 -07:00
moz.build Bug 1332423 - add BUG_COMPONENT to extensions/* files. r=bsmedberg 2017-01-27 08:19:19 -05:00