Re: [glade--]Memory management



José Luiz Bittencourt wrote:
Why glademm uses dynamic memory management with
manage()?
Why it does not use class scope?

Because
- this is the recommended variant (or was since gtkmm 1.2)
- RefPtr is not yet working
- the memory management scheme will change again
- I don't see benefits from changing it.
- it's much easier to (re)order the widget construction according to their dependencies. Embedded members must get constructed by member ctors (between : and {) and in the order the variables were declared.

And the last, how can I get info from the widgets
using manage()?

info ? Mark them as protected, use -> (e.g. label1->get_text() )

   Christof




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