[evolution] EHTMLEditorView - Critical warning could be seen in console after pasting the content



commit 52a958b69a34bc680d4017e7c0958dc4d75002bc
Author: Tomas Popela <tpopela redhat com>
Date:   Wed Jun 29 12:11:05 2016 +0200

    EHTMLEditorView - Critical warning could be seen in console after pasting the content

 e-util/e-html-editor-view.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/e-util/e-html-editor-view.c b/e-util/e-html-editor-view.c
index 3375b71..6baa0da 100644
--- a/e-util/e-html-editor-view.c
+++ b/e-util/e-html-editor-view.c
@@ -737,7 +737,8 @@ e_html_editor_view_force_spell_check_in_viewport (EHTMLEditorView *view)
        /* We have to add 10 px offset as otherwise just the HTML element will be returned */
        viewport_height = webkit_dom_dom_window_get_inner_height (dom_window);
        last_element = webkit_dom_document_element_from_point (document, 10, viewport_height - 10);
-       if (last_element && !WEBKIT_DOM_IS_HTML_HTML_ELEMENT (last_element)) {
+       if (last_element && !WEBKIT_DOM_IS_HTML_HTML_ELEMENT (last_element) &&
+           !WEBKIT_DOM_IS_HTML_BODY_ELEMENT (last_element)) {
                WebKitDOMElement *parent;
 
                parent = get_parent_block_element (WEBKIT_DOM_NODE (last_element));


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