gecko-dev/editor/txtsvc
Masayuki Nakano 61af94acbd Bug 1367683 Optimize initializing nsRange r=smaug
nsRange::DoSetRange() adds/remove its root to/from mutation observer, initializes common ancestor, registers itself to the common ancestor, unregisters itself from old common ancestor, and notifies selection listeners of selection change.

However, those runtime cost is expensive but on the other hand, a lot of callers set both start and end of the range and that causes calling DoSetRange() twice.

This patch renames Set() to SetStartAndEnd() for easier to understand the meaning and make it call DoSetRange() only once.

MozReview-Commit-ID: FRV55tuBAgg

--HG--
extra : rebase_source : 67adf929cf119e2425f7d3741651217522094590
2017-05-30 13:18:25 +09:00
..
moz.build
nsFilteredContentIterator.cpp
nsFilteredContentIterator.h
nsIInlineSpellChecker.idl
nsISpellChecker.h Bug 1330912 - Part 1. Add async version of SetCurrentDictionary using list. r=Ehsan 2017-04-10 18:29:16 +09:00
nsITextService.h
nsITextServicesDocument.h
nsITextServicesFilter.idl
nsTextServicesCID.h
nsTextServicesDocument.cpp Bug 1367683 Optimize initializing nsRange r=smaug 2017-05-30 13:18:25 +09:00
nsTextServicesDocument.h
nsTextServicesFactory.cpp
nsTSAtomList.h