[Sugar-devel] [PATCH Read] Use Box, ButtonBox, Scrollbar instead of his deprecated form

James Cameron quozl at laptop.org
Tue Jun 26 22:20:25 EDT 2012


Thanks for the patch.  I have review comments for one change:

On Tue, Jun 26, 2012 at 10:53:57PM -0300, Agustin Zubiaga wrote:
> [...]
> diff --git a/readtopbar.py b/readtopbar.py
> index d0da3d0..b6fe196 100644
> --- a/readtopbar.py
> +++ b/readtopbar.py
> @@ -33,15 +33,16 @@ _UP_DEVICE_IFACE = 'org.freedesktop.UPower.Device'
>  _UP_TYPE_BATTERY = 2
>  
>  
> -class _TopBar(Gtk.HBox):
> +class _TopBar(Gtk.Box):
>      __gproperties__ = {
>          'completion-level': (float, None, None, 0.0, 100.0, 0.0,
>                               GObject.ParamFlags.WRITABLE),
>      }
>  
>      def __init__(self):
> -        Gtk.HBox.__init__(self)
> +        Gtk.Box.__init__(self)
>  
> +        self.set_orientation(Gtk.Orientation.VERTICAL)
>          self.set_border_width(int(style.DEFAULT_SPACING / 2.0))
>          self.set_spacing(style.DEFAULT_SPACING * 4)
>  

In this change you move from an Horizontal Box to a Box, but set the
orientation to vertical.  I could not tell if this was desired.  If
this is a desired change, perhaps it should be mentioned in the patch
comment.

The other changes looked fine.

-- 
James Cameron
http://quozl.linux.org.au/


More information about the Sugar-devel mailing list