diff options
| author | Stephen Blott | 2018-08-10 13:27:17 +0100 |
|---|---|---|
| committer | GitHub | 2018-08-10 13:27:17 +0100 |
| commit | a34083ed954019fafd27b4fe355c07472c5eac4e (patch) | |
| tree | d27126a60775f4bb742b91299c61579b759ef006 /lib | |
| parent | 17fb86e02971948f90215934cbe5417674364a29 (diff) | |
| parent | 7ccaf67e7be5b600948e57a2f2fa63ec7cb0fc5c (diff) | |
| download | vimium-a34083ed954019fafd27b4fe355c07472c5eac4e.tar.bz2 | |
Merge pull request #2217 from gdh1995/replace-xA0-for-clipboard
replace \xA0 on copying and pasting
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/clipboard.coffee | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/clipboard.coffee b/lib/clipboard.coffee index a9e2e82e..11542b11 100644 --- a/lib/clipboard.coffee +++ b/lib/clipboard.coffee @@ -9,7 +9,7 @@ Clipboard = # http://groups.google.com/group/chromium-extensions/browse_thread/thread/49027e7f3b04f68/f6ab2457dee5bf55 copy: ({data}) -> textArea = @_createTextArea() - textArea.value = data + textArea.value = data.replace /\xa0/g, " " document.body.appendChild(textArea) textArea.select() @@ -23,7 +23,7 @@ Clipboard = document.execCommand("Paste") value = textArea.innerText document.body.removeChild(textArea) - value + value.replace /\xa0/g, " " root = exports ? (window.root ?= {}) |
