struct tank info, where to put it?
Tomaz Canabrava
tcanabrava at kde.org
Mon Apr 15 09:27:28 PDT 2013
Heya,
Continuing my port of the Cylinders, there`s a struct defined in
equipment.c, named tank_info ( plus related functions ).
Since I need a tank info on the Qt part too, I`m putting t the tank_info
struct in the equipment.h ( and as usual, correct me if I`m wrong )
There`s also an array of 100 tank_infos, that are filled manually on
equipment.c too,
1 - what about porting this to a flat csv, json, xml style file?
This is good for maintenability, since we can add more types without
compiling the code.
2 - I don`t want to put the initialization of the tank_info in the cpp
files, since the logic code should not be in c++ , where can I put it? The
code in equipment.c is full of GTK.
Tomaz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.hohndel.org/pipermail/subsurface/attachments/20130415/543eab3d/attachment.html>
More information about the subsurface
mailing list