Excerpts from godiard's message of Fri Jun 17 16:20:03 +0200 2011:

[src/jarabe/journal/listview.py]
> @@ -118,7 +118,8 @@ class BaseListView(gtk.Bin):
>          model.deleted.connect(self.__model_deleted_cb)
>  
>      def __model_created_cb(self, sender, **kwargs):
> -        self._set_dirty()
> +        if self._is_new_item_visible(kwargs):
> +            self._set_dirty()

If we use the additional keyword arguments, we should explicitly list
them in the parameter list. I.e.:


     def __model_created_cb(self, sender, object_id):
         if self._is_item_visible(object_id):
             self._set_dirty()

As Martin mentioned, we should do the same for the updated and deleted
callbacks. In the long run we should probably update the model instead
of doing a complete rescan on every change.

Sascha

-- 
http://sascha.silbe.org/
http://www.infra-silbe.de/

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel

Reply via email to