Re: the proper way to do inheritance



Chas Owens said:
A savings of 7 lines[1] and it is more efficient than have tons of idle
functions being called.

the true question is whether it is better to trigger your dirty signal every
time the document goes dirty, or to ping constantly with an idle that checks a
flag.  the idle is the MFC's approach, the signal is the GTK+ approach, the
answer lies with what you are actually going to do.

you have a save button for each document, so the signal trick makes the most
sense.

if you had a global save that worked on the "active" document, then the idle
would be simpler to live with, because you wouldn't have so much stuff to
update when you switch documents.



you know, i was surprised when i learned that GnomeMDI was deprecated in Gnome
2.x, but then when i tried to write a program with it i figured out why. 
blech.  anyway...

-- 
muppet <scott at asofyet dot org>



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