Ticket #13070: 13070.1.patch
File 13070.1.patch, 2.0 KB (added by , 13 years ago) |
---|
-
wp-includes/script-loader.php
79 79 'enterImageURL' => __('Enter the URL of the image'), 80 80 'enterImageDescription' => __('Enter a description of the image'), 81 81 'fullscreen' => __('fullscreen'), 82 'toggleFullscreen' => esc_attr( __('Toggle fullscreen mode') ) 82 'toggleFullscreen' => esc_attr( __('Toggle fullscreen mode') ), 83 'textdirection' => esc_attr( __('text direction') ), 84 'toggleTextdirection' => esc_attr( __('Toggle Editor Text Direction') ) 83 85 ) ); 84 86 85 87 $scripts->add( 'colorpicker', "/wp-includes/js/colorpicker$suffix.js", array('prototype'), '3517m' ); -
wp-includes/js/quicktags.dev.js
264 264 html += theButtons['fullscreen'].html(name + '_'); 265 265 } 266 266 267 if ( !( 'undefined' == typeof isRtl || !isRtl ) ) { 268 theButtons['textdirection'] = new qt.TextDirectionButton(); 269 html += theButtons['textdirection'].html(name + '_'); 270 } 271 267 272 ed.toolbar.innerHTML = html; 268 273 ed.theButtons = theButtons; 269 274 } … … 605 610 fullscreen.on(); 606 611 }; 607 612 613 qt.TextDirectionButton = function() { 614 qt.Button.call(this, 'textdirection', quicktagsL10n.textdirection, '', quicktagsL10n.toggleTextdirection) 615 }; 616 qt.TextDirectionButton.prototype = new qt.Button(); 617 qt.TextDirectionButton.prototype.callback = function(e, c) { 618 619 var isRTL = !( 'undefined' == typeof isRtl || !isRtl ); 620 currentDirection = c.style.direction; 621 622 if ( '' == currentDirection ) 623 currentDirection = ( isRTL ) ? 'rtl' : 'ltr' ; 624 625 c.style.direction = ( 'rtl' == currentDirection ) ? 'ltr' : 'rtl'; 626 627 c.focus(); 628 } 629 608 630 // ensure backward compatibility 609 631 edButtons[10] = new qt.TagButton('strong','b','<strong>','</strong>','b'); 610 632 edButtons[20] = new qt.TagButton('em','i','<em>','</em>','i'),