diff options
author | Aleksander Machniak <alec@alec.pl> | 2014-05-28 15:52:30 +0200 |
---|---|---|
committer | Aleksander Machniak <alec@alec.pl> | 2014-05-28 15:52:30 +0200 |
commit | 731d190fecb1976d845f6bd18768ee528b007232 (patch) | |
tree | 323c63555256ad7e5faa6a9d3c10f957295d0ce1 /program/js/tinymce/plugins/contextmenu/plugin.min.js | |
parent | 586ed69aa8f9df34076f4e3bb5e1ecf0cfc6581a (diff) | |
parent | 8763170d224408bb01998d0a3393d2eacfc781ad (diff) |
Merge branch 'tinymce4'
Conflicts:
program/js/app.js
program/js/editor.js
program/js/tiny_mce/tiny_mce.js
program/steps/utils/spell_html.inc
Diffstat (limited to 'program/js/tinymce/plugins/contextmenu/plugin.min.js')
-rw-r--r-- | program/js/tinymce/plugins/contextmenu/plugin.min.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/program/js/tinymce/plugins/contextmenu/plugin.min.js b/program/js/tinymce/plugins/contextmenu/plugin.min.js new file mode 100644 index 000000000..06f0d4bd5 --- /dev/null +++ b/program/js/tinymce/plugins/contextmenu/plugin.min.js @@ -0,0 +1 @@ +tinymce.PluginManager.add("contextmenu",function(e){var n,t=e.settings.contextmenu_never_use_native;e.on("contextmenu",function(i){var o;if(!i.ctrlKey||t){if(i.preventDefault(),o=e.settings.contextmenu||"link image inserttable | cell row column deletetable",n)n.show();else{var c=[];tinymce.each(o.split(/[ ,]/),function(n){var t=e.menuItems[n];"|"==n&&(t={text:n}),t&&(t.shortcut="",c.push(t))});for(var a=0;a<c.length;a++)"|"==c[a].text&&(0===a||a==c.length-1)&&c.splice(a,1);n=new tinymce.ui.Menu({items:c,context:"contextmenu"}).addClass("contextmenu").renderTo(),e.on("remove",function(){n.remove(),n=null})}var l={x:i.pageX,y:i.pageY};e.inline||(l=tinymce.DOM.getPos(e.getContentAreaContainer()),l.x+=i.clientX,l.y+=i.clientY),n.moveTo(l.x,l.y)}})});
\ No newline at end of file |