diff --git a/UI/Common/English.lproj/Localizable.strings b/UI/Common/English.lproj/Localizable.strings index bb9c1bf5d..9af10007e 100644 --- a/UI/Common/English.lproj/Localizable.strings +++ b/UI/Common/English.lproj/Localizable.strings @@ -26,3 +26,9 @@ "Default Roles" = "Default Roles"; "Sorry, the user rights can not be configured for that object." = "Sorry, the user rights can not be configured for that object."; + +/* generic.js */ +"Unable to subscribe to that folder!" = "Unable to subscribe to that folder!"; +"You cannot subscribe to a folder that you own!" = "You cannot subscribe to a folder that you own!"; +"Unable to unsubscribe from that folder!" = "Unable to unsubscribe from that folder!"; +"You cannot unsubscribe from a folder that you own!" = "You cannot unsubscribe from a folder that you own!"; diff --git a/UI/Common/French.lproj/Localizable.strings b/UI/Common/French.lproj/Localizable.strings index 5264f182a..18a984d3b 100644 --- a/UI/Common/French.lproj/Localizable.strings +++ b/UI/Common/French.lproj/Localizable.strings @@ -27,3 +27,9 @@ "Default Roles" = "Rôles par défaut"; "Sorry, the user rights can not be configured for that object." = "Sorry, the user rights can not be configured for that object."; + +/* generic.js */ +"Unable to subscribe to that folder!" = "Impossible de s'abonner à ce dossier."; +"You cannot subscribe to a folder that you own!" = "Impossible de vous abonner à un dossier qui vous appartient."; +"Unable to unsubscribe from that folder!" = "Impossible de se désabonner de ce dossier."; +"You cannot unsubscribe from a folder that you own!" = "Impossible de vous désabonner d'un dossier qui vous appartient."; diff --git a/UI/MailPartViewers/UIxMailRenderingContext.m b/UI/MailPartViewers/UIxMailRenderingContext.m index e2a101ae0..3d8186eba 100644 --- a/UI/MailPartViewers/UIxMailRenderingContext.m +++ b/UI/MailPartViewers/UIxMailRenderingContext.m @@ -21,7 +21,7 @@ #include "UIxMailRenderingContext.h" #include -#include "common.h" +#include @implementation UIxMailRenderingContext diff --git a/UI/Templates/UIxPageFrame.wox b/UI/Templates/UIxPageFrame.wox index f1bd213e4..b2b87f6ad 100644 --- a/UI/Templates/UIxPageFrame.wox +++ b/UI/Templates/UIxPageFrame.wox @@ -57,6 +57,8 @@ + 1) { var parentNode = nodes[0]; var userInfos = parentNode.split(":"); @@ -41,7 +41,7 @@ function addLineToTree(tree, parent, line) { offset = nodes.length - 1; } else - window.alert("nope:" + window.userFolderType); + window.alert("nope:" + window.opener.userFolderType); return offset; } @@ -95,19 +95,18 @@ function userFoldersCallback(http) { div.innerHTML = buildTree(http.responseText); var nodes = document.getElementsByClassName("node", $("d")); for (i = 0; i < nodes.length; i++) - nodes[i].addEventListener("click", - onFolderTreeItemClick, false); + Event.observe(nodes[i], "click", onFolderTreeItemClick.bindAsEventListener(nodes[i])); } } } function onConfirmFolderSelection(event) { - var topNode = $("d"); - if (topNode.selectedEntry) { + var topNode = $("d"); + if (topNode.selectedEntry) { var node = topNode.selectedEntry.parentNode; var folder = node.getAttribute("dataname"); var folderName; - if (window.userFolderType == "user") { + if (window.opener.userFolderType == "user") { var spans = document.getElementsByClassName("nodeName", topNode.selectedEntry); var email = spans[0].innerHTML; @@ -125,14 +124,14 @@ function onConfirmFolderSelection(event) { email = email.replace(">", ">"); folderName = spans1[0].innerHTML + ' (' + email + ')'; } - var data = { folderName: folderName, folder: folder }; - window.opener.subscribeToFolder(window.userFolderCallback, data); + var data = { folderName: folderName, folder: folder, window: window }; + window.opener.subscribeToFolder(window.opener.userFolderCallback, data); } } function initUserFoldersWindow() { configureSearchField(); - $("addButton").addEventListener("click", onConfirmFolderSelection, false); + Event.observe($("addButton"), "click", onConfirmFolderSelection); } -window.addEventListener("load", initUserFoldersWindow, false); +addEvent(window, 'load', initUserFoldersWindow); diff --git a/UI/WebServerResources/generic.js b/UI/WebServerResources/generic.js index 188457957..7c5aa1bdd 100644 --- a/UI/WebServerResources/generic.js +++ b/UI/WebServerResources/generic.js @@ -201,14 +201,14 @@ function sanitizeMailTo(dirtyMailTo) { function openUserFolderSelector(callback, type) { var urlstr = ApplicationBaseURL; - if (urlstr[urlstr.length-1] != '/') + if (! urlstr.endsWith('/')) urlstr += '/'; urlstr += ("../../" + UserLogin + "/Contacts/userFolders"); - var w = window.open(urlstr, "User Selector", + var w = window.open(urlstr, "_blank", "width=322,height=250,resizable=1,scrollbars=0"); w.opener = window; - w.userFolderCallback = callback; - w.userFolderType = type; + window.userFolderCallback = callback; + window.userFolderType = type; w.focus(); } @@ -862,7 +862,7 @@ function onSearchKeyDown(event) { this.timer = setTimeout("onSearchFormSubmit()", 1000); } -function onSearchFormSubmit(event) { +function onSearchFormSubmit(event) { log("generic.onSearchFormSubmit") var searchValue = $("searchValue"); var searchCriteria = $("searchCriteria"); @@ -895,9 +895,9 @@ function popupToolbarMenu(node, menuId) { hideMenu(document.currentPopupMenu); var popup = $(menuId); - var top = node.top + node.offsetHeight - 2; + var top = ($(node).getStyle('top') || 0) + node.offsetHeight - 2; popup.setStyle({ top: top + "px", - left: node.cascadeLeftOffset() + "px", + left: $(node).cascadeLeftOffset() + "px", visibility: "visible" }); document.currentPopupMenu = popup; @@ -913,11 +913,11 @@ function folderSubscriptionCallback(http) { http.callbackData["method"](http.callbackData["data"]); } else - window.alert(labels["Unable to subscribe to that folder!"].decodeEntities()); + window.alert(clabels["Unable to subscribe to that folder!"].decodeEntities()); document.subscriptionAjaxRequest = null; } else - log ("ajax fuckage"); + log ("folderSubscriptionCallback Ajax error"); } function subscribeToFolder(refreshCallback, refreshCallbackData) { @@ -937,7 +937,7 @@ function subscribeToFolder(refreshCallback, refreshCallbackData) { rfCbData); } else - window.alert(labels["You cannot subscribe to a folder that you own!"] + refreshCallbackData["window"].alert(clabels["You cannot subscribe to a folder that you own!"] .decodeEntities()); } @@ -948,7 +948,7 @@ function folderUnsubscriptionCallback(http) { http.callbackData["method"](http.callbackData["data"]); } else - window.alert(labels["Unable to unsubscribe from that folder!"].decodeEntities()); + window.alert(clabels["Unable to unsubscribe from that folder!"].decodeEntities()); document.unsubscriptionAjaxRequest = null; } } @@ -975,7 +975,7 @@ function unsubscribeFromFolder(folder, refreshCallback, refreshCallbackData) { rfCbData); } else - window.alert(labels["You cannot unsubscribe from a folder that you own!"].decodeEntities()); + window.alert(clabels["You cannot unsubscribe from a folder that you own!"].decodeEntities()); } } diff --git a/UI/WebServerResources/skycalendar.html b/UI/WebServerResources/skycalendar.html index 97e7dd313..265205de6 100644 --- a/UI/WebServerResources/skycalendar.html +++ b/UI/WebServerResources/skycalendar.html @@ -20,6 +20,7 @@ modified by Martin Hoerning, mh@skyrix.com, 2002-12-05 +