Changeset 33484
- Timestamp:
- 07/29/2015 01:48:58 PM (9 years ago)
- Location:
- trunk/src/wp-includes/js
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/js/mce-view.js
r33428 r33484 422 422 replaceMarkers: function() { 423 423 this.getMarkers( function( editor, node ) { 424 var selected = node === editor.selection.getNode(), 425 $viewNode; 426 424 427 if ( ! this.loader && $( node ).text() !== this.text ) { 425 428 editor.dom.setAttrib( node, 'data-wpview-marker', null ); … … 427 430 } 428 431 429 editor.dom.replace( 430 editor.dom.createFragment( 431 '<div class="wpview-wrap" data-wpview-text="' + this.encodedText + '" data-wpview-type="' + this.type + '">' + 432 '<p class="wpview-selection-before">\u00a0</p>' + 433 '<div class="wpview-body" contenteditable="false">' + 434 '<div class="wpview-content wpview-type-' + this.type + '"></div>' + 435 '</div>' + 436 '<p class="wpview-selection-after">\u00a0</p>' + 437 '</div>' 438 ), 439 node 432 $viewNode = editor.$( 433 '<div class="wpview-wrap" data-wpview-text="' + this.encodedText + '" data-wpview-type="' + this.type + '">' + 434 '<p class="wpview-selection-before">\u00a0</p>' + 435 '<div class="wpview-body" contenteditable="false">' + 436 '<div class="wpview-content wpview-type-' + this.type + '"></div>' + 437 '</div>' + 438 '<p class="wpview-selection-after">\u00a0</p>' + 439 '</div>' 440 440 ); 441 442 editor.$( node ).replaceWith( $viewNode ); 443 444 if ( selected ) { 445 editor.wp.setViewCursor( false, $viewNode[0] ); 446 } 441 447 } ); 442 448 }, -
trunk/src/wp-includes/js/tinymce/plugins/wpview/plugin.js
r32678 r33484 730 730 editor.wp = editor.wp || {}; 731 731 editor.wp.getView = getView; 732 editor.wp.setViewCursor = setViewCursor; 732 733 733 734 // Keep for back-compat.
Note: See TracChangeset
for help on using the changeset viewer.