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/tabfocus/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/tabfocus/plugin.min.js')
-rw-r--r-- | program/js/tinymce/plugins/tabfocus/plugin.min.js | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/program/js/tinymce/plugins/tabfocus/plugin.min.js b/program/js/tinymce/plugins/tabfocus/plugin.min.js new file mode 100644 index 000000000..68fe35e35 --- /dev/null +++ b/program/js/tinymce/plugins/tabfocus/plugin.min.js @@ -0,0 +1 @@ +tinymce.PluginManager.add("tabfocus",function(e){function n(e){9!==e.keyCode||e.ctrlKey||e.altKey||e.metaKey||e.preventDefault()}function t(n){function t(n){function t(e){return"BODY"===e.nodeName||"hidden"!=e.type&&"none"!=e.style.display&&"hidden"!=e.style.visibility&&t(e.parentNode)}function r(e){return e.tabIndex||"INPUT"==e.nodeName||"TEXTAREA"==e.nodeName}function c(e){return!r(e)&&"-1"!=e.getAttribute("tabindex")&&t(e)}if(u=i.select(":input:enabled,*[tabindex]:not(iframe)"),o(u,function(n,t){return n.id==e.id?(a=t,!1):void 0}),n>0){for(d=a+1;d<u.length;d++)if(c(u[d]))return u[d]}else for(d=a-1;d>=0;d--)if(c(u[d]))return u[d];return null}var a,u,c,d;if(!(9!==n.keyCode||n.ctrlKey||n.altKey||n.metaKey)&&(c=r(e.getParam("tab_focus",e.getParam("tabfocus_elements",":prev,:next"))),1==c.length&&(c[1]=c[0],c[0]=":prev"),u=n.shiftKey?":prev"==c[0]?t(-1):i.get(c[0]):":next"==c[1]?t(1):i.get(c[1]))){var y=tinymce.get(u.id||u.name);u.id&&y?y.focus():window.setTimeout(function(){tinymce.Env.webkit||window.focus(),u.focus()},10),n.preventDefault()}}var i=tinymce.DOM,o=tinymce.each,r=tinymce.explode;e.on("init",function(){e.inline&&tinymce.DOM.setAttrib(e.getBody(),"tabIndex",null)}),e.on("keyup",n),tinymce.Env.gecko?e.on("keypress keydown",t):e.on("keydown",t)});
\ No newline at end of file |