Changeset 20341
- Timestamp:
- 04/02/2012 10:16:30 PM (14 years ago)
- Location:
- trunk/wp-includes/js
- Files:
-
- 2 edited
-
tinymce/plugins/wpeditimage/js/editimage.dev.js (modified) (6 diffs)
-
wplink.dev.js (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/js/tinymce/plugins/wpeditimage/js/editimage.dev.js
r20174 r20341 4 4 tinyMCEPopup = { 5 5 init: function() { 6 var t = this, w, li, q, i, it; 7 8 li = ('' + document.location.search).replace(/^\?/, '').split('&'); 9 q = {}; 10 for ( i = 0; i < li.length; i++ ) { 11 it = li[i].split('='); 12 q[unescape(it[0])] = unescape(it[1]); 13 } 14 15 if (q.mce_rdomain) 16 document.domain = q.mce_rdomain; 6 var t = this, w, ti; 17 7 18 8 // Find window & API … … 22 12 t.editor = tinymce.EditorManager.activeEditor; 23 13 t.params = t.editor.windowManager.params; 14 t.features = t.editor.windowManager.features; 24 15 25 16 // Setup local DOM … … 29 20 30 21 getWin : function() { 31 return window.dialogArguments|| opener || parent || top;22 return (!window.frameElement && window.dialogArguments) || opener || parent || top; 32 23 }, 33 24 … … 60 51 61 52 storeSelection : function() { 62 this.editor.windowManager.bookmark = tinyMCEPopup.editor.selection.getBookmark( 'simple');53 this.editor.windowManager.bookmark = tinyMCEPopup.editor.selection.getBookmark(1); 63 54 }, 64 55 … … 66 57 var t = tinyMCEPopup; 67 58 68 if ( tinymce.isIE)59 if ( tinymce.isIE ) 69 60 t.editor.selection.moveToBookmark(t.editor.windowManager.bookmark); 70 61 } … … 395 386 f.link_href.value = tinyMCEPopup.editor.documentBaseURI.toAbsolute(f.link_href.value); 396 387 397 if ( tinymce.isWebKit && ed.dom.hasClass(el, 'aligncenter') ) { 398 ed.dom.removeClass(el, 'aligncenter'); 399 fixSafari = 1; 400 } 401 402 tinyMCEPopup.execCommand("CreateLink", false, "#mce_temp_url#", {skip_undo : 1}); 403 if ( fixSafari ) ed.dom.addClass(el, 'aligncenter'); 388 ed.getDoc().execCommand("unlink", false, null); 389 tinyMCEPopup.execCommand("mceInsertLink", false, "#mce_temp_url#", {skip_undo : 1}); 404 390 405 391 tinymce.each(ed.dom.select("a"), function(n) { 406 if ( ed.dom.getAttrib(n, 'href') == '#mce_temp_url#') {392 if ( ed.dom.getAttrib(n, 'href') == '#mce_temp_url#' ) { 407 393 408 394 ed.dom.setAttribs(n, { -
trunk/wp-includes/js/wplink.dev.js
r19460 r20341 244 244 if (e == null) { 245 245 ed.getDoc().execCommand("unlink", false, null); 246 tinyMCEPopup.execCommand(" CreateLink", false, "#mce_temp_url#", {skip_undo : 1});246 tinyMCEPopup.execCommand("mceInsertLink", false, "#mce_temp_url#", {skip_undo : 1}); 247 247 248 248 tinymce.each(ed.dom.select("a"), function(n) {
Note: See TracChangeset
for help on using the changeset viewer.