gecko-dev/editor/libeditor
Masayuki Nakano 537b829474 Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato
A lot of methods take |const EditorRawDOMPoint&| as their argument.  However,
some of them are called with EditorDOMPoint::AsRaw(). This is not good for
performance because:
1. Needs to create temporary instance of EditorRawDOMPoint.
2. EditorRawDOMPoint::AsRaw() may be used by simple mistake.
3. Such methods may call EditorRawDOMPoint::Offset(), however, it's not copied
   to the original EditorDOMPoint instance.  So, callers may need to compute
   offset again.

So, such methods should be changed to template methods if they are not virtual
method and AsRaw() should be gotten rid of for prevent it looking not expensive.

MozReview-Commit-ID: DAqqW4a2EMS

--HG--
extra : rebase_source : 120b920477fe6e7231271411a00994325acdb842
2018-03-20 14:05:47 +09:00
..
crashtests Bug 1444630 - Don't update dictionary after calling UninitSpellChecker. r=masayuki 2018-03-20 14:27:06 +09:00
tests Bug 1446253 - Make EventUtils.synthesizeComposition() dispatch keydown and keyup event in default r=smaug 2018-03-16 22:35:07 +09:00
ChangeAttributeTransaction.cpp Bug 1379891 - remove nsPIEditorTransaction interface, GetTxnDescription methods. r=m_kato,masayuki 2018-01-14 16:01:41 +01:00
ChangeAttributeTransaction.h Bug 1425412 - part 9: Create factory methods of ChangeAttributeTransaction and remove EditorBase::CreateTxnForSetAttribute() and EditorBase::CreateTxnForRemoveAttribute() r=m_kato 2017-12-18 17:07:52 +09:00
ChangeStyleTransaction.cpp Bug 1428610 part 7. Make the nsICSSDeclaration length API nicer. r=emilio 2018-01-30 14:48:27 -05:00
ChangeStyleTransaction.h Bug 1425412 - part 11: Create factory methods for ChangeStyleTransaction and remove CSSEditUtils::CreateCSSPropertyTxn() r=m_kato 2017-12-18 17:46:57 +09:00
CompositionTransaction.cpp Bug 1446533 part 9. Remove nsIDOMCharacterData::ReplaceData. r=mystor 2018-03-19 15:45:34 -04:00
CompositionTransaction.h Bug 1425412 - part 4: Create CompositionTransaction::Create() and remove EditorBase::CreateTxnForComposition() r=m_kato 2017-12-15 18:26:37 +09:00
CreateElementTransaction.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
CreateElementTransaction.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
CSSEditUtils.cpp Bug 1447358: Unifdef the old style system code. r=jwatt 2018-03-21 10:20:34 +01:00
CSSEditUtils.h Bug 1435149 - Part 1. Change some methods to static or const method in CSSEditUtils. r=masayuki 2018-02-06 12:57:37 +09:00
DeleteNodeTransaction.cpp Bug 1379891 - remove nsPIEditorTransaction interface, GetTxnDescription methods. r=m_kato,masayuki 2018-01-14 16:01:41 +01:00
DeleteNodeTransaction.h Bug 1425412 - part 6: Create DeleteNodeTransaction::MaybeCreate() and remove EditorBaseTransaction::CreateTxnForDeleteNode() r=m_kato 2017-12-15 21:24:33 +09:00
DeleteRangeTransaction.cpp Bug 1446533 part 1. Rename nsGenericDOMDataNode to CharacterData. r=mystor 2018-03-19 15:18:06 -04:00
DeleteRangeTransaction.h Bug 1425412 - part 12: Create factory methods for DeleteRangeTransaction, EditAggregateTransaction and PlaceholderTransaction for consistency with the other transaction classes r=m_kato 2017-12-18 18:08:43 +09:00
DeleteTextTransaction.cpp Bug 1446533 part 7. Remove nsIDOMCharacterData::InsertData. r=mystor 2018-03-19 15:38:04 -04:00
DeleteTextTransaction.h Bug 1446533 part 2. Rename nsGenericDOMDataNode.{h,cpp} to CharacterData. r=mystor 2018-03-19 15:18:07 -04:00
EditAction.h Bug 1430021 - part 1: Move |RefPtr<TextEditRules> mRules| from TextEditor to EditorBase r=m_kato 2018-01-12 19:01:04 +09:00
EditActionListener.h
EditAggregateTransaction.cpp Bug 1379891 - remove nsPIEditorTransaction interface, GetTxnDescription methods. r=m_kato,masayuki 2018-01-14 16:01:41 +01:00
EditAggregateTransaction.h Bug 1425412 - part 12: Create factory methods for DeleteRangeTransaction, EditAggregateTransaction and PlaceholderTransaction for consistency with the other transaction classes r=m_kato 2017-12-18 18:08:43 +09:00
EditorBase.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
EditorBase.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
EditorCommands.cpp
EditorCommands.h
EditorController.cpp
EditorController.h
EditorDOMPoint.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
EditorEventListener.cpp Bug 1446711 part 8. Get rid of nsIDOMMouseEvent. r=qdot 2018-03-20 00:16:07 -04:00
EditorEventListener.h Bug 1446711 part 8. Get rid of nsIDOMMouseEvent. r=qdot 2018-03-20 00:16:07 -04:00
EditorUtils.cpp Bug 1432186 part 15. Remove nsIDOMNode::HasChildNodes. r=mccr8 2018-01-29 23:10:51 -05:00
EditorUtils.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
EditorUtils.js Bug 1432992, part 1 - Remove definitions of Ci, Cr, Cc, and Cu. r=florian 2018-02-06 09:36:57 -08:00
EditorUtils.manifest
EditTransactionBase.cpp Bug 1379891 - remove nsPIEditorTransaction interface, GetTxnDescription methods. r=m_kato,masayuki 2018-01-14 16:01:41 +01:00
EditTransactionBase.h Bug 1379891 - remove nsPIEditorTransaction interface, GetTxnDescription methods. r=m_kato,masayuki 2018-01-14 16:01:41 +01:00
HTMLAbsPositionEditor.cpp Bug 1447483: Merge nsStyleContext and ServoStyleContext, rename to ComputedStyle. r=jwatt on a CLOSED TREE 2018-03-22 20:06:24 +01:00
HTMLAnonymousNodeEditor.cpp Bug 1447098 part 1. Rename FromContent on various DOM classes to FromNode. r=mystor 2018-03-21 17:39:04 -04:00
HTMLEditor.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
HTMLEditor.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
HTMLEditorDataTransfer.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
HTMLEditorEventListener.cpp Bug 1446711 part 8. Get rid of nsIDOMMouseEvent. r=qdot 2018-03-20 00:16:07 -04:00
HTMLEditorEventListener.h Bug 1446711 part 8. Get rid of nsIDOMMouseEvent. r=qdot 2018-03-20 00:16:07 -04:00
HTMLEditorObjectResizer.cpp Bug 1446711 part 2. Get rid of nsIDOMMouseEvent::GetClientX/Y. r=qdot 2018-03-20 00:16:05 -04:00
HTMLEditorObjectResizerUtils.h Bug 1433345 - part 4: Make EditorBase derived from nsISelectionListener and notify its owning classes of selection change r=m_kato 2018-01-26 17:25:45 +09:00
HTMLEditRules.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
HTMLEditRules.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
HTMLEditUtils.cpp Bug 1447098 part 1. Rename FromContent on various DOM classes to FromNode. r=mystor 2018-03-21 17:39:04 -04:00
HTMLEditUtils.h Bug 1432944 part 6. Remove the nsIDOMNode overloads of HTMLEditUtils::IsNamedAnchor and HTMLEditUtils::IsTable. r=m_kato 2018-01-29 23:27:59 -05:00
HTMLInlineTableEditor.cpp Bug 1447098 part 1. Rename FromContent on various DOM classes to FromNode. r=mystor 2018-03-21 17:39:04 -04:00
HTMLStyleEditor.cpp Bug 1446861 - Remove more nsIDOMElement usages from editor. r=masayuki 2018-03-19 14:14:45 +09:00
HTMLTableEditor.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
HTMLURIRefObject.cpp Bug 1446861 - Remove more nsIDOMElement usages from editor. r=masayuki 2018-03-19 14:14:45 +09:00
HTMLURIRefObject.h Bug 1432186 part 2. Clean up the string handling in HTMLURIRefObject::GetNextURI. r=mccr8 2018-01-29 23:10:50 -05:00
InsertNodeTransaction.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
InsertNodeTransaction.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
InsertTextTransaction.cpp Bug 1446533 part 8. Remove nsIDOMCharacterData::DeleteData. r=mystor 2018-03-19 15:45:31 -04:00
InsertTextTransaction.h Bug 1425412 - part 1: Create InsertTextTransaction::Create() and remove EditorBase::CreateTxnForInsertText() r=m_kato 2017-12-15 17:26:52 +09:00
InternetCiter.cpp Bug 1424898 - patch 2 - De-virtualize nsIWordBreaker and rename to mozilla::intl::WordBreaker. r=m_kato 2017-12-13 22:17:38 -06:00
InternetCiter.h
JoinNodeTransaction.cpp Bug 1446533 part 10. Remove remaining nsIDOMCharacterData uses in editor. r=mystor 2018-03-19 15:45:55 -04:00
JoinNodeTransaction.h Bug 1425412 - part 8: Create JoinNodeTransaction::MaybeCreate() and remove EditorBase::CreateTxnForJoinNode() r=m_kato 2017-12-15 21:53:08 +09:00
ManualNAC.h
moz.build Bug 1430021 - part 1: Move |RefPtr<TextEditRules> mRules| from TextEditor to EditorBase r=m_kato 2018-01-12 19:01:04 +09:00
nsIAbsorbingTransaction.h Bug 1400460 - Rename nsIAtom as nsAtom. r=hiro. 2017-10-03 09:05:19 +11:00
PlaceholderTransaction.cpp Bug 1379891 - remove nsPIEditorTransaction interface, GetTxnDescription methods. r=m_kato,masayuki 2018-01-14 16:01:41 +01:00
PlaceholderTransaction.h Bug 1425412 - part 12: Create factory methods for DeleteRangeTransaction, EditAggregateTransaction and PlaceholderTransaction for consistency with the other transaction classes r=m_kato 2017-12-18 18:08:43 +09:00
SelectionState.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
SelectionState.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
SplitNodeTransaction.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
SplitNodeTransaction.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
StyleSheetTransactions.cpp Bug 1379891 - remove nsPIEditorTransaction interface, GetTxnDescription methods. r=m_kato,masayuki 2018-01-14 16:01:41 +01:00
StyleSheetTransactions.h Bug 1425412 - part 10: Create factory methods for AddStyleSheetTransaction and RemoveStyleSheetTransaction, and remove EditorBase::CreateTxnForAddStyleSheet() and EditorBase::CreateTxnForRemoveStyleSheet() r=m_kato 2017-12-18 17:29:32 +09:00
TextEditor.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
TextEditor.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
TextEditorDataTransfer.cpp Bug 1444686 part 13. Remove remaining nsIDOMDataTransfer uses. r=mystor 2018-03-13 16:24:00 -04:00
TextEditorTest.cpp Bug 1446533 part 10. Remove remaining nsIDOMCharacterData uses in editor. r=mystor 2018-03-19 15:45:55 -04:00
TextEditorTest.h
TextEditRules.cpp Bug 1446533 part 9. Remove nsIDOMCharacterData::ReplaceData. r=mystor 2018-03-19 15:45:34 -04:00
TextEditRules.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
TextEditRulesBidi.cpp Bug 1445569 - part 3: Make TextEditRules::CheckBidiLevelForDeletion() take |const EditorRawDOMPoint&| instead of |nsINode*| and offset in it r=m_kato 2018-03-15 18:38:46 +09:00
TextEditUtils.cpp Bug 1446861 - Remove more nsIDOMElement usages from editor. r=masayuki 2018-03-19 14:14:45 +09:00
TextEditUtils.h Bug 1408125 - part 4: Redesign HTMLEditor::InsertNodeAtPoint() with EditorRawDOMPoint r=m_kato 2017-11-28 22:28:07 +09:00
TypeInState.cpp Bug 1445569 - part 4: Get rid of EditorBase::GetStartNodeAndOffset() and EditorBase::GetEndNodeAndOffset() r=m_kato 2018-03-15 21:25:41 +09:00
TypeInState.h Bug 1445569 - part 4: Get rid of EditorBase::GetStartNodeAndOffset() and EditorBase::GetEndNodeAndOffset() r=m_kato 2018-03-15 21:25:41 +09:00
WSRunObject.cpp Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00
WSRunObject.h Bug 1447213 - Change editor methods which take |const EditorRawDOMPoint&| but called with EditorDOMPoint.AsRaw() to template methods r=m_kato 2018-03-20 14:05:47 +09:00