X-Git-Url: https://jasonwoof.com/gitweb/?p=ckeditor.git;a=blobdiff_plain;f=_source%2Fplugins%2Fclipboard%2Fplugin.js;h=3c53ab1007fd63f9f395502127f6bac600976ef0;hp=3740057b50aaeb9c254a7f7410b7d87f6bb2e91c;hb=f0610347140239143439a511ee2bd48cb784f470;hpb=4e70ea24db840898be8cc21c950363a52a2a6aba diff --git a/_source/plugins/clipboard/plugin.js b/_source/plugins/clipboard/plugin.js index 3740057..3c53ab1 100644 --- a/_source/plugins/clipboard/plugin.js +++ b/_source/plugins/clipboard/plugin.js @@ -398,6 +398,13 @@ For licensing, see LICENSE.html or http://ckeditor.com/license } ); }); + // Dismiss the (wrong) 'beforepaste' event fired on context menu open. (#7953) + body.on( 'contextmenu', function() + { + depressBeforeEvent = 1; + setTimeout( function() { depressBeforeEvent = 0; }, 10 ); + }); + body.on( 'beforecut', function() { !depressBeforeEvent && fixCut( editor ); } ); body.on( 'mouseup', function(){ setTimeout( function(){ setToolbarStates.call( editor ); }, 0 ); }, editor );