[gtkmm] Re: Glib::RefPtr also for Widgets?



Christof Petig wrote:
1- Gtk::Foo *w = new Foo();  .... destroy w;
sorry, of course I meant "delete w;"
2- { Gtk::Foo w = Foo();  ... }
3- { Glib::RefPtr<Foo> w = manage(new Foo()); ... }

I found a fourth way:

4- { Gtk::Foo *w = manage(new Foo());  .... w->destroy(); }

but got the impression that destroy is disregarded as of gtkmm2.

    Christof




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