Changeset 29883
- Timestamp:
- 10/12/2014 06:12:58 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/js/tinymce/plugins/wpgallery/plugin.js
r27640 r29883 62 62 editMedia( editor.selection.getNode() ); 63 63 }); 64 /*65 editor.on( 'init', function( e ) {66 // _createButtons()67 64 68 // iOS6 doesn't show the buttons properly on click, show them on 'touchstart'69 if ( 'ontouchstart' in window ) {70 editor.dom.events.bind( editor.getBody(), 'touchstart', function( e ) {71 var target = e.target;72 73 if ( target.nodeName == 'IMG' && editor.dom.hasClass( target, 'wp-gallery' ) ) {74 editor.selection.select( target );75 editor.dom.events.cancel( e );76 editor.plugins.wordpress._hideButtons();77 editor.plugins.wordpress._showButtons( target, 'wp_gallerybtns' );78 }79 });80 }81 });82 */83 65 editor.on( 'mouseup', function( event ) { 84 66 var dom = editor.dom, … … 118 100 editor.on( 'BeforeSetContent', function( event ) { 119 101 // 'wpview' handles the gallery shortcode when present 120 if ( ! editor.plugins.wpview ) {102 if ( ! editor.plugins.wpview || typeof wp === 'undefined' || ! wp.mce ) { 121 103 event.content = replaceGalleryShortcodes( event.content ); 122 104 }
Note: See TracChangeset
for help on using the changeset viewer.