[Xcb] release of util package

Barton C Massey bart at cs.pdx.edu
Sat Mar 8 08:09:09 PST 2008


I'm not understanding the need for this patch.  What's wrong
with just checking hints->flags == 0 inline?  (Of course I'm
not sure I'd ever use *any* of those accessors anyhow, so
maybe I'm the wrong one to comment here. :-)

    Bart

In message <sa5wsodz73r.fsf at Orfeo.duckcorp.org> you wrote:
> Could you please also take a look at the patch I submitted in
> a previous mail? [0] (I have attached again the patch to this mail)
> 
> Regards,
> Arnaud Fontaine
> 
> [0] http://lists.freedesktop.org/archives/xcb/2008-January/003215.html
> 
> 
> --=-=-=
> Content-Type: text/x-diff
> Content-Disposition: attachment; filename=xcb_util_add_is_flag_none.diff
> 
> diff --git a/icccm/icccm.c b/icccm/icccm.c
> index cf22a25..e7b0d5a 100644
> --- a/icccm/icccm.c
> +++ b/icccm/icccm.c
> @@ -280,6 +280,12 @@ xcb_size_hints_get_win_gravity (xcb_size_hints_t *hints)
>  }
>  
>  uint8_t
> +xcb_size_hints_is_flag_none (xcb_size_hints_t *hints)
> +{
> +	return (hints->flags == 0);
> +}
> +
> +uint8_t
>  xcb_size_hints_is_us_position (xcb_size_hints_t *hints)
>  {
>          return (hints->flags & USPosition);
> diff --git a/icccm/xcb_icccm.h b/icccm/xcb_icccm.h
> index eafc71b..ca41610 100644
> --- a/icccm/xcb_icccm.h
> +++ b/icccm/xcb_icccm.h
> @@ -122,6 +122,7 @@ void       xcb_size_hints_get_base_size  (xcb_size_hints_t *hints,
>                                            int32_t          *base_height);
>  uint32_t   xcb_size_hints_get_win_gravity (xcb_size_hints_t *hints);
>  
> +uint8_t    xcb_size_hints_is_flag_none     (xcb_size_hints_t *hints);
>  uint8_t    xcb_size_hints_is_us_position   (xcb_size_hints_t *hints);
>  uint8_t    xcb_size_hints_is_us_size       (xcb_size_hints_t *hints);
>  uint8_t    xcb_size_hints_is_p_position    (xcb_size_hints_t *hints);


More information about the Xcb mailing list