[gnote] Fix delete key behaviour in bulleted list



commit 501b360789ed1300f9c147164b419838f8b1152d
Author: Aurimas Äernius <aurisc4 gmail com>
Date:   Sat Sep 3 13:43:29 2011 +0300

    Fix delete key behaviour in bulleted list
    
    Pressing delete key in empty line between two bulleted list should just
    remove the line, not the bullet from the next one.
    Related Tomboy bug 447245.

 src/notebuffer.cpp |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)
---
diff --git a/src/notebuffer.cpp b/src/notebuffer.cpp
index d5f43a3..48bca2d 100644
--- a/src/notebuffer.cpp
+++ b/src/notebuffer.cpp
@@ -545,7 +545,12 @@ namespace gnote {
     else if (start.ends_line() && start.get_line() < get_line_count()) {
       Gtk::TextIter next = get_iter_at_line (start.get_line() + 1);
       end_iter = start;
-      end_iter.forward_chars(3);
+      if(is_bulleted_list_active()) {
+        end_iter.forward_chars(3);
+      }
+      else {
+        end_iter.forward_chars(1);
+      }
 
       DepthNoteTag::Ptr depth = find_depth_tag(next);
 



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