Re: [Vala] Bug in gtk+-2.0.vapi
- From: Frederik <scumm_fredo gmx net>
- To: vala-list <vala-list gnome org>
- Subject: Re: [Vala] Bug in gtk+-2.0.vapi
- Date: Fri, 29 May 2009 18:51:13 +0200
Uwe Strempel wrote:
Hi,
I've found another one in gtk+-2.0.vapi.
class Container
following is wrong
public virtual void forall (Gtk.Callback callback, void* callback_data);
should be
public virtual void forall (bool include_internals, Gtk.Callback
callback);
Hi Uwe,
there was a bug regarding this issue:
http://bugzilla.gnome.org/show_bug.cgi?id=543872
You can use now:
forall_internal (bool include_internals, Gtk.Callback callback);
In class Widget.
I' think
size_allocate is wrong
before:
public virtual signal void size_allocate (Gtk.Allocation allocation);
after change:
public virtual signal void size_allocate (ref Gtk.Allocation
allocation);
I don't know if signal works with ref, but the vala compiler creates
const GtkAllocation * instead GtkAllocation.
The type is Gdk.Rectangle, not Gtk.Allocation - I'm not sure why.
I don't think that 'allocation' should be a 'ref' argument. In contrast
to 'requisition' in 'size_request()' it is not meant to be changed by
the method. GTK+ doesn't consequently use const struct pointers for
arguments where it actually should do. The Vala way is better but it
produces a "discards qualifiers from pointer target type" gcc warning
when overriding this method.
Best Regards,
Frederik
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]