X-Git-Url: https://scm.cri.mines-paristech.fr/git/ckeditor.git/blobdiff_plain/4263e3f11a4150c7a5eec0ca48b64b784f86b556..e7f8fb547940c134de50db80ffaf54be1135ca7b:/skins/ckeditor/filemanager/browser/mac_finder/browser.html.dtml diff --git a/skins/ckeditor/filemanager/browser/mac_finder/browser.html.dtml b/skins/ckeditor/filemanager/browser/mac_finder/browser.html.dtml index 84232c8..300fcfc 100644 --- a/skins/ckeditor/filemanager/browser/mac_finder/browser.html.dtml +++ b/skins/ckeditor/filemanager/browser/mac_finder/browser.html.dtml @@ -64,10 +64,10 @@ return; li = li.parentNode; case 'LI': - // click on the current selected row - if (currentColumn == li.parentNode && currentColumn.currentRow == li) - return; - + // click on the current selected row + if (currentColumn == li.parentNode && currentColumn.currentRow == li) + return; + currentColumn = li.parentNode; // hightlight row if (currentColumn.currentRow) { @@ -82,26 +82,34 @@ } function onDblClickHandler(evt) { - var li = getTargetedObject(evt); + var li = getTargetedObject(evt); - if(li.tagName != 'LI') { - if (li.tagName == 'IMG' && li.parentNode.tagName == 'LI') - li = t.parentNode; - else - return; - } - switch(window.parent.name) { - case 'FCKeditorDialog_PlinnImage' : - if (li.className == 'contentish-selected') { - window.parent.updateOrInsertImage(li.link); - window.close(); - } - break; - case 'FCKBrowseWindow' : - window.opener.SetUrl(li.link); - window.close(); - break; - } + if(li.tagName != 'LI') { + if (li.tagName == 'IMG' && li.parentNode.tagName == 'LI') + li = t.parentNode; + else + return; + } + console.log('dblclick !', li, window.parent); + switch(window.parent.name) { + case 'PlinnImageDialog' : + if (li.className == 'contentish-selected') { + window.parent.updateOrInsertImage(li.link); + window.close(); + } + break; + case 'StandaloneBrowser' : + if (li.className == 'contentish-selected') { + window.opener.SetUrl(li.link); + window.close(); + } + break; + default : + var funcNum = GetUrlParam('CKEditorFuncNum'); + window.opener.CKEDITOR.tools.callFunction(funcNum, li.link); + window.close(); + break; + } } function onKeydownHandler(evt) { @@ -296,18 +304,20 @@ createLinkBtn.appendChild(document.createTextNode(text)); createLinkBtn.onclick = function(){ - var url = respDom.lastChild.firstChild.nodeValue; - switch(window.parent.name) { - case 'FCKeditorDialog_PlinnImage' : - window.parent.updateOrInsertImage(url); - break; - case 'FCKBrowseWindow' : - default: - var funcNum = GetUrlParam('CKEditorFuncNum'); - window.opener.CKEDITOR.tools.callFunction(funcNum, url); - break; - } - window.close(); + var url = respDom.lastChild.firstChild.nodeValue; + switch(window.parent.name) { + case 'PlinnImageDialog' : + window.parent.updateOrInsertImage(url); + break; + case 'StandaloneBrowser' : + window.opener.SetUrl(url); + break; + default: + var funcNum = GetUrlParam('CKEditorFuncNum'); + window.opener.CKEDITOR.tools.callFunction(funcNum, url); + break; + } + window.close(); }; list.appendChild(li); @@ -339,7 +349,7 @@ - +
  • Folder