[Glade-users] globals vs locals... again
Alexandre BERAUD
a_beraud@voila.fr
Wed, 4 Oct 2000 09:58:52 +0200 (MET DST)
>Nothing should be global. Making widget pointers global prevents you
>from having multiple instances of a widget realised. It also suggests
a
>design that violates the principles of modular isolation. It causes
>interdependencies that increase the maintenance cost.
(...)
It's the same problem as initializing the lists. I have
a 'void init ()' function that I could launch at start
and if my clist widget was global, I could access it
in the init() function. It's a pain if you have to
sent the clist pointer to the function because some-
times you need to send many different widgets.
Alex
"Rather than love, than money, than
fame, give me Truth"