[evolution/wip/webkit2] EHTMLEditorView - Undoing and redoing Return press in the beginning of citation is wrong (Tomas
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution/wip/webkit2] EHTMLEditorView - Undoing and redoing Return press in the beginning of citation is wrong (Tomas
- Date: Thu, 3 Mar 2016 12:00:26 +0000 (UTC)
commit 418ba2f3c2d113aad15f8cdab2c1f859e839255e
Author: Tomas Popela <tpopela redhat com>
Date: Thu Mar 3 12:52:19 2016 +0100
EHTMLEditorView - Undoing and redoing Return press in the beginning of citation is wrong (Tomas
.../composer/e-html-editor-undo-redo-manager.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
---
diff --git a/web-extensions/composer/e-html-editor-undo-redo-manager.c
b/web-extensions/composer/e-html-editor-undo-redo-manager.c
index db2ec0b..8cd35d8 100644
--- a/web-extensions/composer/e-html-editor-undo-redo-manager.c
+++ b/web-extensions/composer/e-html-editor-undo-redo-manager.c
@@ -1928,7 +1928,7 @@ undo_redo_citation_split (WebKitDOMDocument *document,
parent = get_parent_block_element (WEBKIT_DOM_NODE (selection_start));
- if (event->data.fragment &&
+ if (!event->data.fragment ||
!webkit_dom_node_get_first_child (WEBKIT_DOM_NODE (event->data.fragment))) {
remove_node (WEBKIT_DOM_NODE (parent));
dom_merge_siblings_if_necessary (document, NULL);
@@ -2007,6 +2007,8 @@ undo_redo_citation_split (WebKitDOMDocument *document,
dom_force_spell_check_in_viewport (document, extension);
} else {
+ restore_selection_to_history_event_state (document, event->before);
+
if (in_situ) {
WebKitDOMElement *selection_start_marker;
WebKitDOMNode *block;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]