[evolution] Bug 775397 - Freeze / lockup trying to delete a hyperlink in a cited html mail



commit 4e573eb92310e642ff892bb253b14758aab430ec
Author: Tomas Popela <tpopela redhat com>
Date:   Wed Nov 30 16:40:29 2016 +0100

    Bug 775397 - Freeze / lockup trying to delete a hyperlink in a cited html mail
    
    Switch to the safer check whether we are after the ending range when
    refreshing the spell check - compare the ranges start positions and
    quit the loop after we move after the start position of the ending
    range. Previously we needed to get to the exact ending position and that
    was sometimes not possible (it could happen that it was skipped - it
    depends on the DOM structure) and we continued to move the selection
    over and over.

 .../web-extension/e-editor-dom-functions.c         |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/modules/webkit-editor/web-extension/e-editor-dom-functions.c 
b/src/modules/webkit-editor/web-extension/e-editor-dom-functions.c
index 1d1e4c1..7ccbb4e 100644
--- a/src/modules/webkit-editor/web-extension/e-editor-dom-functions.c
+++ b/src/modules/webkit-editor/web-extension/e-editor-dom-functions.c
@@ -640,7 +640,7 @@ perform_spell_check (WebKitDOMDOMSelection *dom_selection,
        /* Go through all words to spellcheck them. To avoid this we have to wait for
         * http://www.w3.org/html/wg/drafts/html/master/editing.html#dom-forcespellcheck */
        /* We are moving forward word by word until we hit the text on the end. */
-       while (actual && webkit_dom_range_compare_boundary_points (end_range, WEBKIT_DOM_RANGE_END_TO_END, 
actual, NULL) != 0) {
+       while (actual && webkit_dom_range_compare_boundary_points (actual, WEBKIT_DOM_RANGE_START_TO_START, 
end_range, NULL) < 0) {
                if (actual != start_range)
                        g_object_unref (actual);
                webkit_dom_dom_selection_modify (


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