summaryrefslogtreecommitdiffstats
path: root/src/corelib/global/qtypetraits.h
Commit message (Collapse)AuthorAgeFilesLines
* Add Q_IS_ENUM(), and provide as flag in QMetaType::typeFlags()Glenn Watson2012-03-111-0/+420
Add Q_IS_ENUM() macro to determine if a given type is an enumeration. Use information from that in QMetaType::registerType() to store whether custom registered metatypes are enums or not. This information can then be accessed by calling QMetaType::typeFlags(int type). This is used by the declarative code to determine whether a custom type in a variant can be safely cast to an integer, which is required to allow passing non-local enums as signal/slot params. Change-Id: I9733837f56af201fa3017b4a22b761437a3c0de4 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>