← Back to team overview

gtg-user team mailing list archive

[Merge] lp:~gtg-user/gtg/bugfix-493335 into lp:gtg


Alan Gomes Alvino has proposed merging lp:~gtg-user/gtg/bugfix-493335 into lp:gtg.

Requested reviews:
  Gtg developers (gtg)
Related bugs:
  Bug #493335 in Getting Things GNOME!: "delete a subtask with selection on the arrow leaves the arrow"

For more details, see:

The bug is because the delete_range is call after the delete_selection, and the delete_seletcion doesn't remove the arrow. What i do was after the delete_range i remove the arrow.
Your team Gtg users is subscribed to branch lp:~gtg-user/gtg/bugfix-493335.
=== modified file 'GTG/gtk/editor/taskview.py'
--- GTG/gtk/editor/taskview.py	2012-05-20 19:05:20 +0000
+++ GTG/gtk/editor/taskview.py	2012-07-05 07:10:24 +0000
@@ -797,6 +797,11 @@
         #now we really delete the selected stuffs
         selec = self.buff.get_selection_bounds()
+        # Delete what not being deleted by delete_selection, the ideal is run _delete_range before the delete_selection
+        self.buff.disconnect(self.delete_sigid)
+        self.buff.stop_emission("delete-range")
+        self.buff.delete(start, end)
+        self.delete_sigid = self.buff.connect("delete-range", self._delete_range)
 #        if selec:
 #            print "deleted text is ##%s##" %self.buff.get_text(selec[0], selec[1])#(start, end)
 #        self.buff.disconnect(self.delete_sigid)

Follow ups