[evolution/gnome-3-16] EHTMLEditorView - Preformated block in quoted content is wrapped when splitted with new line



commit 7156837ccc2ebf92257627828b382cd70e1e4655
Author: Tomas Popela <tpopela redhat com>
Date:   Tue Apr 28 09:38:41 2015 +0200

    EHTMLEditorView - Preformated block in quoted content is wrapped when splitted with new line
    
    Only wrap following block when the block is paragraph.

 e-util/e-html-editor-view.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/e-util/e-html-editor-view.c b/e-util/e-html-editor-view.c
index cdc2953..db03cc3 100644
--- a/e-util/e-html-editor-view.c
+++ b/e-util/e-html-editor-view.c
@@ -1166,8 +1166,10 @@ insert_new_line_into_citation (EHTMLEditorView *view,
                        if (node && WEBKIT_DOM_IS_ELEMENT (node)) {
                                remove_quoting_from_element (WEBKIT_DOM_ELEMENT (node));
                                remove_wrapping_from_element (WEBKIT_DOM_ELEMENT (node));
-                               node = WEBKIT_DOM_NODE (e_html_editor_selection_wrap_paragraph_length (
-                                       selection, WEBKIT_DOM_ELEMENT (node), length));
+
+                               if (element_has_class (WEBKIT_DOM_ELEMENT (node), "-x-evo-paragraph"))
+                                       node = WEBKIT_DOM_NODE (e_html_editor_selection_wrap_paragraph_length 
(
+                                               selection, WEBKIT_DOM_ELEMENT (node), length));
                                e_html_editor_view_quote_plain_text_element_after_wrapping (
                                        document, WEBKIT_DOM_ELEMENT (node), citation_level);
                        }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]