[evolution/gnome-3-16] Bug 751194 - Bulleted lists indentation jumps levels



commit b20f86a50a0e56e882eaf1e3541feeac48b6d063
Author: Tomas Popela <tpopela redhat com>
Date:   Thu Jun 25 08:29:10 2015 +0200

    Bug 751194 - Bulleted lists indentation jumps levels
    
    If we already indented the block, skip it and don't try to indent it again.

 e-util/e-html-editor-selection.c |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/e-util/e-html-editor-selection.c b/e-util/e-html-editor-selection.c
index 632a6b5..c0b15ad 100644
--- a/e-util/e-html-editor-selection.c
+++ b/e-util/e-html-editor-selection.c
@@ -3417,7 +3417,7 @@ get_list_level (WebKitDOMNode *node)
        return level;
 }
 
-static void
+static gboolean
 indent_list (EHTMLEditorSelection *selection,
              WebKitDOMDocument *document)
 {
@@ -3464,6 +3464,8 @@ indent_list (EHTMLEditorSelection *selection,
 
                merge_lists_if_possible (WEBKIT_DOM_NODE (list));
        }
+
+       return after_selection_end;
 }
 
 static void
@@ -3578,7 +3580,7 @@ e_html_editor_selection_indent (EHTMLEditorSelection *selection)
 
                length = webkit_dom_node_list_get_length (list);
                if (length == 0 && node_is_list_or_item (block)) {
-                       indent_list (selection, document);
+                       after_selection_end = indent_list (selection, document);
                        goto next;
                }
 


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