[evolution/wip/webkit-composer: 915/966] EEditorWidget: Avoid infinite loop in spellchecking and remove unnecessary saving of caret position
- From: Tomas Popela <tpopela src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/wip/webkit-composer: 915/966] EEditorWidget: Avoid infinite loop in spellchecking and remove unnecessary saving of caret position
- Date: Wed, 23 Apr 2014 11:10:21 +0000 (UTC)
commit 9c4c43638bbe2f0ce5dcf1ae211e0152f1feeb03
Author: Tomas Popela <tpopela redhat com>
Date: Wed Mar 19 10:14:03 2014 +0100
EEditorWidget: Avoid infinite loop in spellchecking and remove unnecessary saving of caret position
e-util/e-editor-widget.c | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
---
diff --git a/e-util/e-editor-widget.c b/e-util/e-editor-widget.c
index be23657..0ba44f4 100644
--- a/e-util/e-editor-widget.c
+++ b/e-util/e-editor-widget.c
@@ -232,12 +232,10 @@ e_editor_widget_force_spell_check_for_current_paragraph (EEditorWidget *widget)
widget, editor_widget_selection_changed_cb, NULL);
e_editor_selection_block_selection_changed (selection);
- caret = e_editor_selection_save_caret_position (selection);
-
parent = webkit_dom_node_get_parent_element (WEBKIT_DOM_NODE (caret));
element = caret;
- while (!WEBKIT_DOM_IS_HTML_BODY_ELEMENT (parent)) {
+ while (parent && !WEBKIT_DOM_IS_HTML_BODY_ELEMENT (parent)) {
element = parent;
parent = webkit_dom_node_get_parent_element (
WEBKIT_DOM_NODE (parent));
@@ -308,7 +306,6 @@ move_caret_into_element (WebKitDOMDocument *document,
webkit_dom_dom_selection_add_range (window_selection, new_range);
}
-
static void
refresh_spell_check (EEditorWidget *widget,
gboolean enable_spell_check)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]