diff options
author | Glenn Watson <glenn.watson@nokia.com> | 2012-02-07 12:25:07 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-03-11 23:58:39 +0100 |
commit | 15c13b91e66b0bd0d179f0303bb17c7793f80a07 (patch) | |
tree | 4fef509b602582190351653abd718bee396bd8cc /src/corelib/global/global.pri | |
parent | e3429f764b37c3d58faf06c6e1856e66fb8d64b9 (diff) |
Add Q_IS_ENUM(), and provide as flag in QMetaType::typeFlags()
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>
Diffstat (limited to 'src/corelib/global/global.pri')
-rw-r--r-- | src/corelib/global/global.pri | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/corelib/global/global.pri b/src/corelib/global/global.pri index 49128374e0..58cff6b81c 100644 --- a/src/corelib/global/global.pri +++ b/src/corelib/global/global.pri @@ -11,7 +11,9 @@ HEADERS += \ global/qnumeric.h \ global/qlogging.h \ global/qtypeinfo.h \ - global/qsysinfo.h + global/qsysinfo.h \ + global/qisenum.h \ + global/qtypetraits.h SOURCES += \ global/qglobal.cpp \ |