[evolution/wip/webkit-composer: 245/262] Swap the directions of caret movement on restoring the caret position.



commit c61bf3fd4a649482102fe5993850b413a875adce
Author: Tomas Popela <tpopela redhat com>
Date:   Wed Sep 25 14:11:14 2013 +0200

    Swap the directions of caret movement on restoring the caret position.
    
    When writing some text into composer this was causing that the caret was
    not on a position where was expected.

 e-util/e-editor-selection.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/e-util/e-editor-selection.c b/e-util/e-editor-selection.c
index 89ff327..5342bf9 100644
--- a/e-util/e-editor-selection.c
+++ b/e-util/e-editor-selection.c
@@ -3048,8 +3048,8 @@ e_editor_selection_restore_caret_position (EEditorSelection *selection)
                                /* FIXME If caret position is restored and afterwards the position is saved
                                 * it is not on the place where it supposed to be (it is in the beginning of
                                 * parent's element. It can be avoided by moving with the caret. */
-                               webkit_dom_dom_selection_modify (window_selection, "move", "right", 
"character");
                                webkit_dom_dom_selection_modify (window_selection, "move", "left", 
"character");
+                               webkit_dom_dom_selection_modify (window_selection, "move", "right", 
"character");
 
                                return;
                        }
@@ -3064,8 +3064,8 @@ e_editor_selection_restore_caret_position (EEditorSelection *selection)
                /* FIXME If caret position is restored and afterwards the position is saved
                 * it is not on the place where it supposed to be (it is in the beginning of
                 * parent's element. It can be avoided by moving with the caret. */
-               webkit_dom_dom_selection_modify (window_selection, "move", "right", "character");
                webkit_dom_dom_selection_modify (window_selection, "move", "left", "character");
+               webkit_dom_dom_selection_modify (window_selection, "move", "right", "character");
        }
 }
 


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