[evolution/wip/webkit-composer] EEditorWidget: Avoid unneeded whitespaces when generating plain text message
- From: Tomas Popela <tpopela src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/wip/webkit-composer] EEditorWidget: Avoid unneeded whitespaces when generating plain text message
- Date: Thu, 13 Mar 2014 15:55:22 +0000 (UTC)
commit 2d919641765af0876a000e95be5d7b8e2c095239
Author: Tomas Popela <tpopela redhat com>
Date: Thu Mar 13 15:35:14 2014 +0100
EEditorWidget: Avoid unneeded whitespaces when generating plain text message
e-util/e-editor-widget.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/e-util/e-editor-widget.c b/e-util/e-editor-widget.c
index 851ad7b..acedc95 100644
--- a/e-util/e-editor-widget.c
+++ b/e-util/e-editor-widget.c
@@ -4030,10 +4030,11 @@ process_elements (EEditorWidget *widget,
if (to_plain_text || changing_mode)
g_string_append (buffer, content);
-
if (to_plain_text && !changing_mode) {
- if (get_citation_level (node, FALSE) > 0)
+ if (get_citation_level (node, FALSE) > 0 &&
+ webkit_dom_node_get_next_sibling (node)) {
g_string_append (buffer, "\n");
+ }
}
g_free (content);
@@ -4072,7 +4073,7 @@ process_elements (EEditorWidget *widget,
skip_node = TRUE;
} else {
if (!changing_mode && to_plain_text) {
- if (get_citation_level (node, FALSE) == 0) {
+ if (get_citation_level (child, FALSE) == 0) {
gchar *value;
value = webkit_dom_element_get_attribute (
WEBKIT_DOM_ELEMENT (child), "type");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]