Re: storing buttons in vector -- need to define copy ctor?



On Sat, 2006-06-03 at 00:39 +0200, Pierre THIERRY wrote:
> Scribit Joe Van Dyk dies 02/06/2006 hora 12:58:
> > However, it fails to compile -- something about the copy ctor.
> 
> Try to store pointers (or Glib::Refptr) of widget, they are assignable,
> AFAIK.

Please don't use Glib::RefPtr on widgets. It's not what it's meant for.
A regular pointer is fine.

> The value type of an STL container must be assignable. It must also be
> default constructible when you want to reserve space, I think.

-- 
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]