[evolution] EHTMLEditorView - Minor refactoring



commit cfc3859bbfe999fa0b773cc9e8b79f895db586f5
Author: Tomas Popela <tpopela redhat com>
Date:   Thu Oct 23 16:00:02 2014 +0200

    EHTMLEditorView - Minor refactoring

 e-util/e-html-editor-view.c |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/e-util/e-html-editor-view.c b/e-util/e-html-editor-view.c
index 130e8cc..923c238 100644
--- a/e-util/e-html-editor-view.c
+++ b/e-util/e-html-editor-view.c
@@ -276,16 +276,17 @@ e_html_editor_view_force_spell_check_for_current_paragraph (EHTMLEditorView *vie
                view, html_editor_view_selection_changed_cb, NULL);
        e_html_editor_selection_block_selection_changed (selection);
 
-       parent = get_parent_block_element (WEBKIT_DOM_NODE (selection_start_marker));
+       parent = get_parent_block_element (WEBKIT_DOM_NODE (selection_end_marker));
 
        /* Append some text on the end of the element */
        text = webkit_dom_document_create_text_node (document, "-x-evo-end");
        webkit_dom_node_append_child (
-               WEBKIT_DOM_NODE (get_parent_block_element (
-                       WEBKIT_DOM_NODE (selection_end_marker))),
+               WEBKIT_DOM_NODE (parent),
                WEBKIT_DOM_NODE (text),
                NULL);
 
+       parent = get_parent_block_element (WEBKIT_DOM_NODE (selection_start_marker));
+
        /* Create range that's pointing on the end of this text */
        end_range = webkit_dom_document_create_range (document);
        webkit_dom_range_select_node_contents (


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