From: Jan Arne Petersen <[email protected]>

When text is deleted adjust selection anchor.
---
 clients/editor.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/clients/editor.c b/clients/editor.c
index 5c75ac1..af1623f 100644
--- a/clients/editor.c
+++ b/clients/editor.c
@@ -591,6 +591,8 @@ text_entry_delete_text(struct text_entry *entry,
        if (entry->cursor > index)
                entry->cursor -= length;
 
+       entry->anchor = entry->cursor;
+
        entry->text[index] = '\0';
        strcat(entry->text, entry->text + index + length);
 
-- 
1.7.11.4

_______________________________________________
wayland-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/wayland-devel

Reply via email to