diff options
author | Dylan Hardison <dylan@mozilla.com> | 2016-07-19 23:49:01 +0200 |
---|---|---|
committer | Dylan Hardison <dylan@mozilla.com> | 2016-07-19 23:49:10 +0200 |
commit | 3105082f7df647cca14062eef340d4158574b163 (patch) | |
tree | 14a6a468d38b9190debfee097427bfcb89904443 /extensions/BugModal/web | |
parent | 771a917aed2ca46fac22ca6fc79af2364dffa499 (diff) | |
download | bugzilla-3105082f7df647cca14062eef340d4158574b163.tar.gz bugzilla-3105082f7df647cca14062eef340d4158574b163.tar.xz |
Bug 1275595 - document.execCommand('cut'/'copy') was denied because it was not called from inside a short running user-generated event handler.
Diffstat (limited to 'extensions/BugModal/web')
-rw-r--r-- | extensions/BugModal/web/bug_modal.js | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/extensions/BugModal/web/bug_modal.js b/extensions/BugModal/web/bug_modal.js index e7a182580..dfbe06bad 100644 --- a/extensions/BugModal/web/bug_modal.js +++ b/extensions/BugModal/web/bug_modal.js @@ -255,14 +255,9 @@ $(function() { } if ($('#copy-summary').length) { - - // probe for document.execCommand("copy") support var hasExecCopy = false; try { - // on page load nothing will be selected, so we don't smash the - // clipboard doing this - document.execCommand("copy"); - hasExecCopy = true; + hasExecCopy = document.queryCommandSupported("copy"); } catch(ex) { // ignore } |