[gtkmm] Design Question



I am curious as to how I could set up my Address Book program as far as
designing the classes, etc.  I use gtkmm and libglademm to load the .glade file.

One way that I could do it is to have 1 class called GUI, which contains all the
GUI functions, signals, etc.  This class would take my AddressBook object as an
argument to the constructor, passing in the AddressBook class by reference. 
Then I was thinking about doing all the GUI signal connections in the
constructor of this GUI class.

The other way I was thinking would be to create a difference class for each
Dialog window that I have in my program.  Then I would pass in the libglademm
RefPtr by reference to the constructor of each dialog object.

If someone could please explain a common way of connecting the GUI pieces and
the backend AddressBook class code together, I would greatly appreciate it.  I
like the idea of keeping each part of the GUI in separate headers so that I can
easily edit each part of the GUI code.

Thank you very much, and I hope to be able to come up with a nice, clean set of
code.

-- 
Craig Slusher
ouslush columbus rr com



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