On 11/28/05, Kevin Puetz <[EMAIL PROTECTED]> wrote: > Colin Pitrat wrote: > > > Well it's strange, but if I put the class def in separate files (say > > cannon.h and cannon.cc) than the main function, it works. > > Usually, this sort of error appears when a class as virtual methods, but > > none is defined in the .cc file, but that doesn't seem to be the case > > here. > > (Way too late, but just in case anyone still cares...) > > This is related to Qt's "MOC" preprocessor, which generates the > implementation of the signal/slot mechanism (the stuff declared in the > Q_OBJECT macro). Headers are scanned by qmake and the rules to generate, > compile, and link the moc implementation are automatically included if any > Q_OBJECT classes exist. cpp files aren't. You can get around this by doing > a #include "foo.moc" in foo.cpp (typically at the end) for a cpp file that > contains class declarations, which will get make to force a moc run on that > file and incorporate the result.
Thank you for explaining that. In the mean time, I've had to learn wxWidgets for Tech Source, so I've been learning that and will probably focus on that for the time being. _______________________________________________ Open-graphics mailing list [email protected] http://lists.duskglow.com/mailman/listinfo/open-graphics List service provided by Duskglow Consulting, LLC (www.duskglow.com)
