mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-26 19:55:39 +00:00
c2694625b5
This patch is based on Makoto Kato-san's patch. This patch implements `mozilla::dom::StaticRange` class and creating some static factory methods. Then, makes `AbstractRange` has a utility method of `SetStartAndEnd()` method of `nsRange` and `StaticRange` for sharing same logic in one place. However, there are some additional work is required only in `nsRange`, e.g., `nsRange` needs to start observing mutation of the range, but `StaticRange` does not it. Therefore, it's implemented as a template method which takes `nsRange*` or `StaticRange*` as a parameter. Then, each `DoSetRange()` method of them can do different things without virtual calls. Note that `StaticRange` does not have any properties, methods nor constructor. Therefore, we need additional API to test it. Differential Revision: https://phabricator.services.mozilla.com/D35143 --HG-- extra : moz-landing-system : lando |
||
---|---|---|
.. | ||
collections | ||
events | ||
nodes | ||
historical.html.ini | ||
interfaces.html.ini |