summaryrefslogtreecommitdiff
path: root/program/steps
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2014-10-29 10:33:13 +0100
committerAleksander Machniak <alec@alec.pl>2014-10-29 10:34:58 +0100
commit080f560e0fc2f910e410c0ca8cc68a88e0363a08 (patch)
treeb8ae9ea2eecada90c48cc1620c205528620a96e3 /program/steps
parentb5fd858eb21da1a17dd4b3dd76c84f7b4eb805e3 (diff)
Fix reply scrolling issue with text mode and start message below the quote (#1490114)
Conflicts: program/js/app.js
Diffstat (limited to 'program/steps')
-rw-r--r--program/steps/mail/compose.inc11
1 files changed, 8 insertions, 3 deletions
diff --git a/program/steps/mail/compose.inc b/program/steps/mail/compose.inc
index 1414d903e..6a5ce56a4 100644
--- a/program/steps/mail/compose.inc
+++ b/program/steps/mail/compose.inc
@@ -989,6 +989,8 @@ function rcmail_create_reply_body($body, $bodyIsHtml)
)
));
+ $reply_mode = intval($RCMAIL->config->get('reply_mode'));
+
if (!$bodyIsHtml) {
$body = preg_replace('/\r?\n/', "\n", $body);
$body = trim($body, "\n");
@@ -997,10 +999,13 @@ function rcmail_create_reply_body($body, $bodyIsHtml)
$body = rcmail_wrap_and_quote($body, $LINE_LENGTH);
$prefix .= "\n";
- $suffix = '';
- if (intval($RCMAIL->config->get('reply_mode')) > 0) { // top-posting
+ if ($reply_mode > 0) { // top-posting
$prefix = "\n\n\n" . $prefix;
+ $suffix = '';
+ }
+ else {
+ $suffix = "\n";
}
}
else {
@@ -1015,7 +1020,7 @@ function rcmail_create_reply_body($body, $bodyIsHtml)
$prefix = '<p>' . rcube::Q($prefix) . "</p>\n";
$prefix .= '<blockquote>';
- if (intval($RCMAIL->config->get('reply_mode')) > 0) { // top-posting
+ if ($reply_mode > 0) { // top-posting
$prefix = '<br>' . $prefix;
$suffix = '</blockquote>';
}