我正在尝试在以下情况下捕获Ctrl+V事件中的文本。
Creating a textarea in the page and setting height 0px and width 0px. like below
<textarea id="a" style="height:0px;width:0px"></textarea>
On pressing V key i am setting the focus to that textarea and then using Ctrl+V button. Like below..
shortcut.add("X",function() { $('#a').focus(); }); // In between user have to press Ctrl+V to paste the content shortcut.add("V",function() { alert($('#a').val()); });