Re: where is error?



> I've been following this thread a bit and I did some checking. I may be
> way off base here but after doing some checking I think that RadioGroup
> wasn't meant to be overridden.
>
> RadioAction::RadioAction(Group& group, const Glib::ustring& name, const
> Gtk::StockID& stock_id, const Glib::ustring& label, const Glib::ustring&
> tooltip)
> :
>   Glib::ObjectBase(0), //Mark this class as gtkmmproc-generated, rather
> than a custom class, to allow vfunc optimisations.
>
> I found this bit in the constructor in radioaction.cc line 35 of version
> 2.6.something
>
> I have very little experience with the gtk/gnome underpinnings but this
> was a red flag so I thought I'd mention it.

All of the gtkmm classes have this. It's just an optimisation. Due to the
(necessary) eccentricities of virtual inheritance, that ObjectBase(0) will
not be called while instantiating a derived constructor.

> It is quite weird.
>
> ...
>
> A thought occurred to me. I dunno why or how but this works:
>
> The important part seems to be theL
>
> Glib::ObjectBase(0)

It shouldn't be necessary and it doesn't belong in application code. If
nobody figures the problem out, I might get around to looking at it, if I
find it later in bugzilla.

[snip]


Murray Cumming
murrayc murrayc com
www.murrayc.com
www.openismus.com




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]