Redefinition of QVariant::Type.

QVariant::Type is redundant, it copies QMetaType::Type enum. In long
term it might be removed completely, but it wouldn't be a source
compatible change.

Change-Id: Ibe79ca0ab43918b4cf767cd7a5040f865abbf03f
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
bb10
Jędrzej Nowacki 2011-11-28 10:33:50 +01:00 committed by Qt by Nokia
parent ae768911ee
commit 79923f5b32
1 changed files with 56 additions and 58 deletions

View File

@ -93,66 +93,64 @@ class Q_CORE_EXPORT QVariant
{
public:
enum Type {
Invalid = 0,
Invalid = QMetaType::Void,
Bool = QMetaType::Bool,
Int = QMetaType::Int,
UInt = QMetaType::UInt,
LongLong = QMetaType::LongLong,
ULongLong = QMetaType::ULongLong,
Double = QMetaType::Double,
Char = QMetaType::QChar,
Map = QMetaType::QVariantMap,
List = QMetaType::QVariantList,
String = QMetaType::QString,
StringList = QMetaType::QStringList,
ByteArray = QMetaType::QByteArray,
BitArray = QMetaType::QBitArray,
Date = QMetaType::QDate,
Time = QMetaType::QTime,
DateTime = QMetaType::QDateTime,
Url = QMetaType::QUrl,
Locale = QMetaType::QLocale,
Rect = QMetaType::QRect,
RectF = QMetaType::QRectF,
Size = QMetaType::QSize,
SizeF = QMetaType::QSizeF,
Line = QMetaType::QLine,
LineF = QMetaType::QLineF,
Point = QMetaType::QPoint,
PointF = QMetaType::QPointF,
RegExp = QMetaType::QRegExp,
Hash = QMetaType::QVariantHash,
EasingCurve = QMetaType::QEasingCurve,
LastCoreType = QMetaType::LastCoreType,
Bool = 1,
Int = 2,
UInt = 3,
LongLong = 4,
ULongLong = 5,
Double = 6,
Char = 7,
Map = 8,
List = 9,
String = 10,
StringList = 11,
ByteArray = 12,
BitArray = 13,
Date = 14,
Time = 15,
DateTime = 16,
Url = 17,
Locale = 18,
Rect = 19,
RectF = 20,
Size = 21,
SizeF = 22,
Line = 23,
LineF = 24,
Point = 25,
PointF = 26,
RegExp = 27,
Hash = 28,
EasingCurve = 29,
LastCoreType = EasingCurve,
Font = QMetaType::QFont,
Pixmap = QMetaType::QPixmap,
Brush = QMetaType::QBrush,
Color = QMetaType::QColor,
Palette = QMetaType::QPalette,
Image = QMetaType::QImage,
Polygon = QMetaType::QPolygon,
Region = QMetaType::QRegion,
Bitmap = QMetaType::QBitmap,
Cursor = QMetaType::QCursor,
KeySequence = QMetaType::QKeySequence,
Pen = QMetaType::QPen,
TextLength = QMetaType::QTextLength,
TextFormat = QMetaType::QTextFormat,
Matrix = QMetaType::QMatrix,
Transform = QMetaType::QTransform,
Matrix4x4 = QMetaType::QMatrix4x4,
Vector2D = QMetaType::QVector2D,
Vector3D = QMetaType::QVector3D,
Vector4D = QMetaType::QVector4D,
Quaternion = QMetaType::QQuaternion,
PolygonF = QMetaType::QPolygonF,
LastGuiType = QMetaType::LastGuiType,
// value 62 is internally reserved
Font = 64,
Pixmap = 65,
Brush = 66,
Color = 67,
Palette = 68,
Image = 69,
Polygon = 70,
Region = 71,
Bitmap = 72,
Cursor = 73,
KeySequence = 74,
Pen = 75,
TextLength = 76,
TextFormat = 77,
Matrix = 78,
Transform = 79,
Matrix4x4 = 80,
Vector2D = 81,
Vector3D = 82,
Vector4D = 83,
Quaternion = 84,
PolygonF = 85,
LastGuiType = PolygonF,
Icon = 120,
SizePolicy = 121,
Icon = QMetaType::QIcon,
SizePolicy = QMetaType::QSizePolicy,
UserType = 127,
LastType = 0xffffffff // need this so that gcc >= 3.4 allocates 32 bits for Type