Ticket #20834: 20834.patch
| File 20834.patch, 1.3 KB (added by azaozz, 10 months ago) |
|---|
-
wp-includes/js/autosave.dev.js
96 96 $('input#wp-preview').val(''); 97 97 } 98 98 99 // This code is meant to allow tabbing from Title to Post if tinymce is defined. 100 if ( typeof tinymce != 'undefined' ) { 101 $('#title').bind('keydown.focus-tinymce', function(e) { 102 if ( e.which != 9 ) 103 return; 99 // This code is meant to allow tabbing from Title to Post content. 100 $('#title').bind('keydown.editor-focus', function(e) { 101 var ed; 104 102 105 if ( !e.ctrlKey && !e.altKey && !e.shiftKey && tinymce.activeEditor && !tinymce.activeEditor.isHidden() ) { 106 $('td.mceToolbar > a').focus(); 107 e.preventDefault(); 108 } 109 }); 110 } 103 if ( e.which != 9 ) 104 return; 111 105 106 if ( !e.ctrlKey && !e.altKey && !e.shiftKey ) { 107 if ( typeof(tinymce) != 'undefined' ) 108 ed = tinymce.get('content'); 109 110 if ( ed && !ed.isHidden() ) 111 $('#content_tbl td.mceToolbar > a').focus(); 112 else 113 $('#content').focus(); 114 115 e.preventDefault(); 116 } 117 }); 118 112 119 // autosave new posts after a title is typed but not if Publish or Save Draft is clicked 113 120 if ( '1' == $('#auto_draft').val() ) { 114 121 $('#title').blur( function() {
