aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorStephen Blott2017-04-22 07:29:28 +0100
committerStephen Blott2017-04-22 07:32:41 +0100
commit0975076abe3529e19dcd23655697791c39c3ff78 (patch)
tree7ebb2717a132690738d218663249331f8f7ee480 /lib
parent961f7130a60ae041fb0304353160d6fc74529aa7 (diff)
downloadvimium-0975076abe3529e19dcd23655697791c39c3ff78.tar.bz2
Refactor getSelectionType() to DOM utils.
This is a no-op. It is preparatory to implementing a suitable polyfill for `selection.type` for Firefox.
Diffstat (limited to 'lib')
-rw-r--r--lib/dom_utils.coffee4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/dom_utils.coffee b/lib/dom_utils.coffee
index 06db1b9b..8fdc319e 100644
--- a/lib/dom_utils.coffee
+++ b/lib/dom_utils.coffee
@@ -326,6 +326,10 @@ DomUtils =
@suppressEvent event
handlerStack.suppressEvent
+
+ getSelectionType: (selection) ->
+ selection.type
+
# Adapted from: http://roysharon.com/blog/37.
# This finds the element containing the selection focus.
getElementWithFocus: (selection, backwards) ->