Thanks guys. Is this worth mentioning in the documentation?
________________________________________ From: Development <[email protected]> on behalf of Giuseppe D'Angelo <[email protected]> Sent: Monday, 7 March 2016 21:19 To: [email protected] Subject: Re: [Development] Usage of Q_OBJECT macro in QObject subclasses that don't use signals, slots, or properties Il 07/03/2016 20:55, Curtis Mitch ha scritto: > Why is this the case? What strange behaviour could result from not doing so? qobject_cast breaks; the meta object system reports and uses the wrong class name (so things like "inherits", "className" etc. don't work); tr() uses the wrong context; and so on. qobject_cast breakage may be serious enough to justify an automatic -1 to all public QObjects-without-Q_OBJECT classes. Cheers, -- Giuseppe D'Angelo | [email protected] | Senior Software Engineer KDAB (UK) Ltd., a KDAB Group company | Tel: UK +44-1625-809908 KDAB - The Qt Experts _______________________________________________ Development mailing list [email protected] http://lists.qt-project.org/mailman/listinfo/development
