diff options
author | Alex Yatskov <alex@foosoft.net> | 2016-07-25 20:07:54 -0700 |
---|---|---|
committer | Alex Yatskov <alex@foosoft.net> | 2016-07-25 20:07:54 -0700 |
commit | f88f8dc97fa4baa354a7e04c125dd6968a22c85f (patch) | |
tree | d8e6cb61234aa5bb5b55e329fad764933062657e /ext/fg/js/source-input.js | |
parent | d26ecab0b521e8da19c01521e5a5a3e3ada331eb (diff) |
Sentence and URL support
Diffstat (limited to 'ext/fg/js/source-input.js')
-rw-r--r-- | ext/fg/js/source-input.js | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/ext/fg/js/source-input.js b/ext/fg/js/source-input.js index 9f5a76a0..d3c92793 100644 --- a/ext/fg/js/source-input.js +++ b/ext/fg/js/source-input.js @@ -18,9 +18,13 @@ class TextSourceInput { - constructor(input) { + constructor(input, length=-1) { this.input = input; - this.length = -1; + this.length = length; + } + + clone() { + return new TextSourceInput(this.input, this.length); } text() { |