From 3f2b814c531ba798e3be9bc13ed709b9b4fb8c77 Mon Sep 17 00:00:00 2001 From: Wolfgang Sourdeau Date: Wed, 31 Oct 2007 17:04:15 +0000 Subject: [PATCH] Monotone-Parent: c63be943c6ed8307cd0bd6059b5dd4d20e644c15 Monotone-Revision: 14af1c089766685ea8ad6be31a8ef96d384e1ab2 Monotone-Author: wsourdeau@inverse.ca Monotone-Date: 2007-10-31T17:04:15 Monotone-Branch: ca.inverse.sogo --- UI/MailPartViewers/UIxMailPartTextViewer.m | 2 ++ UI/WebServerResources/generic.js | 38 ---------------------- 2 files changed, 2 insertions(+), 38 deletions(-) diff --git a/UI/MailPartViewers/UIxMailPartTextViewer.m b/UI/MailPartViewers/UIxMailPartTextViewer.m index 22d41a386..450c14217 100644 --- a/UI/MailPartViewers/UIxMailPartTextViewer.m +++ b/UI/MailPartViewers/UIxMailPartTextViewer.m @@ -44,6 +44,8 @@ content = [NSMutableString string]; superContent = [[super flatContentAsString] stringByEscapingHTMLString]; [content appendString: [superContent stringByDetectingURLs]]; + [content replaceString: @"\r\n" withString: @"
"]; + [content replaceString: @"\n" withString: @"
"]; return content; } diff --git a/UI/WebServerResources/generic.js b/UI/WebServerResources/generic.js index 5e7ffceac..5581a0084 100644 --- a/UI/WebServerResources/generic.js +++ b/UI/WebServerResources/generic.js @@ -445,44 +445,6 @@ function generateQueryString(queryDict) { return s; } -function getQueryParaArray(s) { - if (s.charAt(0) == "?") s = s.substr(1, s.length - 1); - return s.split("&"); -} - -function getQueryParaValue(s, name) { - var t; - - t = getQueryParaArray(s); - for (var i = 0; i < t.length; i++) { - var s = t[i]; - - if (s.indexOf(name) != 0) - continue; - - s = s.substr(name.length, s.length - name.length); - return decodeURIComponent(s); - } - return null; -} - -/* opener callback */ - -function triggerOpenerCallback() { - /* this code has some issue if the folder has no proper trailing slash! */ - if (window.opener && !window.opener.closed) { - var t, cburl; - - t = getQueryParaValue(window.location.search, "openerurl="); - cburl = window.opener.location.href; - if (cburl[cburl.length - 1] != "/") { - cburl = cburl.substr(0, cburl.lastIndexOf("/") + 1); - } - cburl = cburl + t; - window.opener.location.href = cburl; - } -} - /* selection mechanism */ function deselectAll(parent) {