Ignore:
Timestamp:
Feb 11, 2010, 11:19:06 PM (15 years ago)
Author:
Dmitry A. Kuminov
Message:

trunk: Merged in qt 4.6.1 sources.

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/tools/shared/qtpropertybrowser/qtvariantproperty.cpp

    r2 r561  
    22**
    33** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies).
    4 ** Contact: Qt Software Information (qt-info@nokia.com)
     4** All rights reserved.
     5** Contact: Nokia Corporation (qt-info@nokia.com)
    56**
    67** This file is part of the tools applications of the Qt Toolkit.
     
    2122** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
    2223**
    23 ** In addition, as a special exception, Nokia gives you certain
    24 ** additional rights. These rights are described in the Nokia Qt LGPL
    25 ** Exception version 1.0, included in the file LGPL_EXCEPTION.txt in this
    26 ** package.
     24** In addition, as a special exception, Nokia gives you certain additional
     25** rights.  These rights are described in the Nokia Qt LGPL Exception
     26** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
    2727**
    2828** GNU General Public License Usage
     
    3434** met: http://www.gnu.org/copyleft/gpl.html.
    3535**
    36 ** If you are unsure which license is appropriate for your use, please
    37 ** contact the sales department at qt-sales@nokia.com.
     36** If you have questions regarding the use of this file, please contact
     37** Nokia at qt-info@nokia.com.
    3838** $QT_END_LICENSE$
    3939**
     
    5252#endif
    5353
    54 #if QT_VERSION >= 0x040400
    5554QT_BEGIN_NAMESPACE
    56 #endif
    5755
    5856class QtEnumPropertyType
     
    7068};
    7169
    72 #if QT_VERSION >= 0x040400
    7370QT_END_NAMESPACE
    74 #endif
    7571
    7672Q_DECLARE_METATYPE(QtEnumPropertyType)
     
    7874Q_DECLARE_METATYPE(QtGroupPropertyType)
    7975
    80 #if QT_VERSION >= 0x040400
    8176QT_BEGIN_NAMESPACE
    82 #endif
    8377
    8478/*!
     
    195189*/
    196190QtVariantProperty::QtVariantProperty(QtVariantPropertyManager *manager)
    197     : QtProperty(manager),  d_ptr(new QtVariantPropertyPrivate(manager))
    198 {
    199 
     191    : QtProperty(manager), d_ptr(new QtVariantPropertyPrivate(manager))
     192{
    200193}
    201194
     
    207200QtVariantProperty::~QtVariantProperty()
    208201{
    209     delete d_ptr;
    210202}
    211203
     
    919911*/
    920912QtVariantPropertyManager::QtVariantPropertyManager(QObject *parent)
    921     : QtAbstractPropertyManager(parent)
    922 {
    923     d_ptr = new QtVariantPropertyManagerPrivate;
     913    : QtAbstractPropertyManager(parent), d_ptr(new QtVariantPropertyManagerPrivate)
     914{
    924915    d_ptr->q_ptr = this;
    925916
     
    936927    d_ptr->m_typeToAttributeToAttributeType[QVariant::Int][d_ptr->m_singleStepAttribute] = QVariant::Int;
    937928    d_ptr->m_typeToValueType[QVariant::Int] = QVariant::Int;
    938     connect(intPropertyManager, SIGNAL(valueChanged(QtProperty *, int)),
    939                 this, SLOT(slotValueChanged(QtProperty *, int)));
    940     connect(intPropertyManager, SIGNAL(rangeChanged(QtProperty *, int, int)),
    941                 this, SLOT(slotRangeChanged(QtProperty *, int, int)));
    942     connect(intPropertyManager, SIGNAL(singleStepChanged(QtProperty *, int)),
    943                 this, SLOT(slotSingleStepChanged(QtProperty *, int)));
     929    connect(intPropertyManager, SIGNAL(valueChanged(QtProperty*,int)),
     930                this, SLOT(slotValueChanged(QtProperty*,int)));
     931    connect(intPropertyManager, SIGNAL(rangeChanged(QtProperty*,int,int)),
     932                this, SLOT(slotRangeChanged(QtProperty*,int,int)));
     933    connect(intPropertyManager, SIGNAL(singleStepChanged(QtProperty*,int)),
     934                this, SLOT(slotSingleStepChanged(QtProperty*,int)));
    944935    // DoublePropertyManager
    945936    QtDoublePropertyManager *doublePropertyManager = new QtDoublePropertyManager(this);
     
    954945            QVariant::Int;
    955946    d_ptr->m_typeToValueType[QVariant::Double] = QVariant::Double;
    956     connect(doublePropertyManager, SIGNAL(valueChanged(QtProperty *, double)),
    957                 this, SLOT(slotValueChanged(QtProperty *, double)));
    958     connect(doublePropertyManager, SIGNAL(rangeChanged(QtProperty *, double, double)),
    959                 this, SLOT(slotRangeChanged(QtProperty *, double, double)));
    960     connect(doublePropertyManager, SIGNAL(singleStepChanged(QtProperty *, double)),
    961                 this, SLOT(slotSingleStepChanged(QtProperty *, double)));
    962     connect(doublePropertyManager, SIGNAL(decimalsChanged(QtProperty *, int)),
    963                 this, SLOT(slotDecimalsChanged(QtProperty *, int)));
     947    connect(doublePropertyManager, SIGNAL(valueChanged(QtProperty*,double)),
     948                this, SLOT(slotValueChanged(QtProperty*,double)));
     949    connect(doublePropertyManager, SIGNAL(rangeChanged(QtProperty*,double,double)),
     950                this, SLOT(slotRangeChanged(QtProperty*,double,double)));
     951    connect(doublePropertyManager, SIGNAL(singleStepChanged(QtProperty*,double)),
     952                this, SLOT(slotSingleStepChanged(QtProperty*,double)));
     953    connect(doublePropertyManager, SIGNAL(decimalsChanged(QtProperty*,int)),
     954                this, SLOT(slotDecimalsChanged(QtProperty*,int)));
    964955    // BoolPropertyManager
    965956    QtBoolPropertyManager *boolPropertyManager = new QtBoolPropertyManager(this);
    966957    d_ptr->m_typeToPropertyManager[QVariant::Bool] = boolPropertyManager;
    967958    d_ptr->m_typeToValueType[QVariant::Bool] = QVariant::Bool;
    968     connect(boolPropertyManager, SIGNAL(valueChanged(QtProperty *, bool)),
    969                 this, SLOT(slotValueChanged(QtProperty *, bool)));
     959    connect(boolPropertyManager, SIGNAL(valueChanged(QtProperty*,bool)),
     960                this, SLOT(slotValueChanged(QtProperty*,bool)));
    970961    // StringPropertyManager
    971962    QtStringPropertyManager *stringPropertyManager = new QtStringPropertyManager(this);
     
    974965    d_ptr->m_typeToAttributeToAttributeType[QVariant::String][d_ptr->m_regExpAttribute] =
    975966            QVariant::RegExp;
    976     connect(stringPropertyManager, SIGNAL(valueChanged(QtProperty *, const QString &)),
    977                 this, SLOT(slotValueChanged(QtProperty *, const QString &)));
    978     connect(stringPropertyManager, SIGNAL(regExpChanged(QtProperty *, const QRegExp &)),
    979                 this, SLOT(slotRegExpChanged(QtProperty *, const QRegExp &)));
     967    connect(stringPropertyManager, SIGNAL(valueChanged(QtProperty*,QString)),
     968                this, SLOT(slotValueChanged(QtProperty*,QString)));
     969    connect(stringPropertyManager, SIGNAL(regExpChanged(QtProperty*,QRegExp)),
     970                this, SLOT(slotRegExpChanged(QtProperty*,QRegExp)));
    980971    // DatePropertyManager
    981972    QtDatePropertyManager *datePropertyManager = new QtDatePropertyManager(this);
     
    986977    d_ptr->m_typeToAttributeToAttributeType[QVariant::Date][d_ptr->m_maximumAttribute] =
    987978            QVariant::Date;
    988     connect(datePropertyManager, SIGNAL(valueChanged(QtProperty *, const QDate &)),
    989                 this, SLOT(slotValueChanged(QtProperty *, const QDate &)));
    990     connect(datePropertyManager, SIGNAL(rangeChanged(QtProperty *, const QDate &, const QDate &)),
    991                 this, SLOT(slotRangeChanged(QtProperty *, const QDate &, const QDate &)));
     979    connect(datePropertyManager, SIGNAL(valueChanged(QtProperty*,QDate)),
     980                this, SLOT(slotValueChanged(QtProperty*,QDate)));
     981    connect(datePropertyManager, SIGNAL(rangeChanged(QtProperty*,QDate,QDate)),
     982                this, SLOT(slotRangeChanged(QtProperty*,QDate,QDate)));
    992983    // TimePropertyManager
    993984    QtTimePropertyManager *timePropertyManager = new QtTimePropertyManager(this);
    994985    d_ptr->m_typeToPropertyManager[QVariant::Time] = timePropertyManager;
    995986    d_ptr->m_typeToValueType[QVariant::Time] = QVariant::Time;
    996     connect(timePropertyManager, SIGNAL(valueChanged(QtProperty *, const QTime &)),
    997                 this, SLOT(slotValueChanged(QtProperty *, const QTime &)));
     987    connect(timePropertyManager, SIGNAL(valueChanged(QtProperty*,QTime)),
     988                this, SLOT(slotValueChanged(QtProperty*,QTime)));
    998989    // DateTimePropertyManager
    999990    QtDateTimePropertyManager *dateTimePropertyManager = new QtDateTimePropertyManager(this);
    1000991    d_ptr->m_typeToPropertyManager[QVariant::DateTime] = dateTimePropertyManager;
    1001992    d_ptr->m_typeToValueType[QVariant::DateTime] = QVariant::DateTime;
    1002     connect(dateTimePropertyManager, SIGNAL(valueChanged(QtProperty *, const QDateTime &)),
    1003                 this, SLOT(slotValueChanged(QtProperty *, const QDateTime &)));
     993    connect(dateTimePropertyManager, SIGNAL(valueChanged(QtProperty*,QDateTime)),
     994                this, SLOT(slotValueChanged(QtProperty*,QDateTime)));
    1004995    // KeySequencePropertyManager
    1005996    QtKeySequencePropertyManager *keySequencePropertyManager = new QtKeySequencePropertyManager(this);
    1006997    d_ptr->m_typeToPropertyManager[QVariant::KeySequence] = keySequencePropertyManager;
    1007998    d_ptr->m_typeToValueType[QVariant::KeySequence] = QVariant::KeySequence;
    1008     connect(keySequencePropertyManager, SIGNAL(valueChanged(QtProperty *, const QKeySequence &)),
    1009                 this, SLOT(slotValueChanged(QtProperty *, const QKeySequence &)));
     999    connect(keySequencePropertyManager, SIGNAL(valueChanged(QtProperty*,QKeySequence)),
     1000                this, SLOT(slotValueChanged(QtProperty*,QKeySequence)));
    10101001    // CharPropertyManager
    10111002    QtCharPropertyManager *charPropertyManager = new QtCharPropertyManager(this);
    10121003    d_ptr->m_typeToPropertyManager[QVariant::Char] = charPropertyManager;
    10131004    d_ptr->m_typeToValueType[QVariant::Char] = QVariant::Char;
    1014     connect(charPropertyManager, SIGNAL(valueChanged(QtProperty *, const QChar &)),
    1015                 this, SLOT(slotValueChanged(QtProperty *, const QChar &)));
     1005    connect(charPropertyManager, SIGNAL(valueChanged(QtProperty*,QChar)),
     1006                this, SLOT(slotValueChanged(QtProperty*,QChar)));
    10161007    // LocalePropertyManager
    10171008    QtLocalePropertyManager *localePropertyManager = new QtLocalePropertyManager(this);
    10181009    d_ptr->m_typeToPropertyManager[QVariant::Locale] = localePropertyManager;
    10191010    d_ptr->m_typeToValueType[QVariant::Locale] = QVariant::Locale;
    1020     connect(localePropertyManager, SIGNAL(valueChanged(QtProperty *, const QLocale &)),
    1021                 this, SLOT(slotValueChanged(QtProperty *, const QLocale &)));
    1022     connect(localePropertyManager->subEnumPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1023                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1024     connect(localePropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1025                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1026     connect(localePropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1027                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1011    connect(localePropertyManager, SIGNAL(valueChanged(QtProperty*,QLocale)),
     1012                this, SLOT(slotValueChanged(QtProperty*,QLocale)));
     1013    connect(localePropertyManager->subEnumPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1014                this, SLOT(slotValueChanged(QtProperty*,int)));
     1015    connect(localePropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1016                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1017    connect(localePropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1018                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    10281019    // PointPropertyManager
    10291020    QtPointPropertyManager *pointPropertyManager = new QtPointPropertyManager(this);
    10301021    d_ptr->m_typeToPropertyManager[QVariant::Point] = pointPropertyManager;
    10311022    d_ptr->m_typeToValueType[QVariant::Point] = QVariant::Point;
    1032     connect(pointPropertyManager, SIGNAL(valueChanged(QtProperty *, const QPoint &)),
    1033                 this, SLOT(slotValueChanged(QtProperty *, const QPoint &)));
    1034     connect(pointPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1035                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1036     connect(pointPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1037                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1038     connect(pointPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1039                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1023    connect(pointPropertyManager, SIGNAL(valueChanged(QtProperty*,QPoint)),
     1024                this, SLOT(slotValueChanged(QtProperty*,QPoint)));
     1025    connect(pointPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1026                this, SLOT(slotValueChanged(QtProperty*,int)));
     1027    connect(pointPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1028                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1029    connect(pointPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1030                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    10401031    // PointFPropertyManager
    10411032    QtPointFPropertyManager *pointFPropertyManager = new QtPointFPropertyManager(this);
     
    10441035    d_ptr->m_typeToAttributeToAttributeType[QVariant::PointF][d_ptr->m_decimalsAttribute] =
    10451036            QVariant::Int;
    1046     connect(pointFPropertyManager, SIGNAL(valueChanged(QtProperty *, const QPointF &)),
    1047                 this, SLOT(slotValueChanged(QtProperty *, const QPointF &)));
    1048     connect(pointFPropertyManager, SIGNAL(decimalsChanged(QtProperty *, int)),
    1049                 this, SLOT(slotDecimalsChanged(QtProperty *, int)));
    1050     connect(pointFPropertyManager->subDoublePropertyManager(), SIGNAL(valueChanged(QtProperty *, double)),
    1051                 this, SLOT(slotValueChanged(QtProperty *, double)));
    1052     connect(pointFPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1053                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1054     connect(pointFPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1055                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1037    connect(pointFPropertyManager, SIGNAL(valueChanged(QtProperty*,QPointF)),
     1038                this, SLOT(slotValueChanged(QtProperty*,QPointF)));
     1039    connect(pointFPropertyManager, SIGNAL(decimalsChanged(QtProperty*,int)),
     1040                this, SLOT(slotDecimalsChanged(QtProperty*,int)));
     1041    connect(pointFPropertyManager->subDoublePropertyManager(), SIGNAL(valueChanged(QtProperty*,double)),
     1042                this, SLOT(slotValueChanged(QtProperty*,double)));
     1043    connect(pointFPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1044                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1045    connect(pointFPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1046                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    10561047    // SizePropertyManager
    10571048    QtSizePropertyManager *sizePropertyManager = new QtSizePropertyManager(this);
     
    10621053    d_ptr->m_typeToAttributeToAttributeType[QVariant::Size][d_ptr->m_maximumAttribute] =
    10631054            QVariant::Size;
    1064     connect(sizePropertyManager, SIGNAL(valueChanged(QtProperty *, const QSize &)),
    1065                 this, SLOT(slotValueChanged(QtProperty *, const QSize &)));
    1066     connect(sizePropertyManager, SIGNAL(rangeChanged(QtProperty *, const QSize &, const QSize &)),
    1067                 this, SLOT(slotRangeChanged(QtProperty *, const QSize &, const QSize &)));
    1068     connect(sizePropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1069                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1070     connect(sizePropertyManager->subIntPropertyManager(), SIGNAL(rangeChanged(QtProperty *, int, int)),
    1071                 this, SLOT(slotRangeChanged(QtProperty *, int, int)));
    1072     connect(sizePropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1073                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1074     connect(sizePropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1075                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1055    connect(sizePropertyManager, SIGNAL(valueChanged(QtProperty*,QSize)),
     1056                this, SLOT(slotValueChanged(QtProperty*,QSize)));
     1057    connect(sizePropertyManager, SIGNAL(rangeChanged(QtProperty*,QSize,QSize)),
     1058                this, SLOT(slotRangeChanged(QtProperty*,QSize,QSize)));
     1059    connect(sizePropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1060                this, SLOT(slotValueChanged(QtProperty*,int)));
     1061    connect(sizePropertyManager->subIntPropertyManager(), SIGNAL(rangeChanged(QtProperty*,int,int)),
     1062                this, SLOT(slotRangeChanged(QtProperty*,int,int)));
     1063    connect(sizePropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1064                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1065    connect(sizePropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1066                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    10761067    // SizeFPropertyManager
    10771068    QtSizeFPropertyManager *sizeFPropertyManager = new QtSizeFPropertyManager(this);
     
    10841075    d_ptr->m_typeToAttributeToAttributeType[QVariant::SizeF][d_ptr->m_decimalsAttribute] =
    10851076            QVariant::Int;
    1086     connect(sizeFPropertyManager, SIGNAL(valueChanged(QtProperty *, const QSizeF &)),
    1087                 this, SLOT(slotValueChanged(QtProperty *, const QSizeF &)));
    1088     connect(sizeFPropertyManager, SIGNAL(rangeChanged(QtProperty *, const QSizeF &, const QSizeF &)),
    1089                 this, SLOT(slotRangeChanged(QtProperty *, const QSizeF &, const QSizeF &)));
    1090     connect(sizeFPropertyManager, SIGNAL(decimalsChanged(QtProperty *, int)),
    1091                 this, SLOT(slotDecimalsChanged(QtProperty *, int)));
    1092     connect(sizeFPropertyManager->subDoublePropertyManager(), SIGNAL(valueChanged(QtProperty *, double)),
    1093                 this, SLOT(slotValueChanged(QtProperty *, double)));
    1094     connect(sizeFPropertyManager->subDoublePropertyManager(), SIGNAL(rangeChanged(QtProperty *, double, double)),
    1095                 this, SLOT(slotRangeChanged(QtProperty *, double, double)));
    1096     connect(sizeFPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1097                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1098     connect(sizeFPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1099                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1077    connect(sizeFPropertyManager, SIGNAL(valueChanged(QtProperty*,QSizeF)),
     1078                this, SLOT(slotValueChanged(QtProperty*,QSizeF)));
     1079    connect(sizeFPropertyManager, SIGNAL(rangeChanged(QtProperty*,QSizeF,QSizeF)),
     1080                this, SLOT(slotRangeChanged(QtProperty*,QSizeF,QSizeF)));
     1081    connect(sizeFPropertyManager, SIGNAL(decimalsChanged(QtProperty*,int)),
     1082                this, SLOT(slotDecimalsChanged(QtProperty*,int)));
     1083    connect(sizeFPropertyManager->subDoublePropertyManager(), SIGNAL(valueChanged(QtProperty*,double)),
     1084                this, SLOT(slotValueChanged(QtProperty*,double)));
     1085    connect(sizeFPropertyManager->subDoublePropertyManager(), SIGNAL(rangeChanged(QtProperty*,double,double)),
     1086                this, SLOT(slotRangeChanged(QtProperty*,double,double)));
     1087    connect(sizeFPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1088                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1089    connect(sizeFPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1090                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    11001091    // RectPropertyManager
    11011092    QtRectPropertyManager *rectPropertyManager = new QtRectPropertyManager(this);
     
    11041095    d_ptr->m_typeToAttributeToAttributeType[QVariant::Rect][d_ptr->m_constraintAttribute] =
    11051096            QVariant::Rect;
    1106     connect(rectPropertyManager, SIGNAL(valueChanged(QtProperty *, const QRect &)),
    1107                 this, SLOT(slotValueChanged(QtProperty *, const QRect &)));
    1108     connect(rectPropertyManager, SIGNAL(constraintChanged(QtProperty *, const QRect &)),
    1109                 this, SLOT(slotConstraintChanged(QtProperty *, const QRect &)));
    1110     connect(rectPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1111                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1112     connect(rectPropertyManager->subIntPropertyManager(), SIGNAL(rangeChanged(QtProperty *, int, int)),
    1113                 this, SLOT(slotRangeChanged(QtProperty *, int, int)));
    1114     connect(rectPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1115                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1116     connect(rectPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1117                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1097    connect(rectPropertyManager, SIGNAL(valueChanged(QtProperty*,QRect)),
     1098                this, SLOT(slotValueChanged(QtProperty*,QRect)));
     1099    connect(rectPropertyManager, SIGNAL(constraintChanged(QtProperty*,QRect)),
     1100                this, SLOT(slotConstraintChanged(QtProperty*,QRect)));
     1101    connect(rectPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1102                this, SLOT(slotValueChanged(QtProperty*,int)));
     1103    connect(rectPropertyManager->subIntPropertyManager(), SIGNAL(rangeChanged(QtProperty*,int,int)),
     1104                this, SLOT(slotRangeChanged(QtProperty*,int,int)));
     1105    connect(rectPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1106                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1107    connect(rectPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1108                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    11181109    // RectFPropertyManager
    11191110    QtRectFPropertyManager *rectFPropertyManager = new QtRectFPropertyManager(this);
     
    11241115    d_ptr->m_typeToAttributeToAttributeType[QVariant::RectF][d_ptr->m_decimalsAttribute] =
    11251116            QVariant::Int;
    1126     connect(rectFPropertyManager, SIGNAL(valueChanged(QtProperty *, const QRectF &)),
    1127                 this, SLOT(slotValueChanged(QtProperty *, const QRectF &)));
    1128     connect(rectFPropertyManager, SIGNAL(constraintChanged(QtProperty *, const QRectF &)),
    1129                 this, SLOT(slotConstraintChanged(QtProperty *, const QRectF &)));
    1130     connect(rectFPropertyManager, SIGNAL(decimalsChanged(QtProperty *, int)),
    1131                 this, SLOT(slotDecimalsChanged(QtProperty *, int)));
    1132     connect(rectFPropertyManager->subDoublePropertyManager(), SIGNAL(valueChanged(QtProperty *, double)),
    1133                 this, SLOT(slotValueChanged(QtProperty *, double)));
    1134     connect(rectFPropertyManager->subDoublePropertyManager(), SIGNAL(rangeChanged(QtProperty *, double, double)),
    1135                 this, SLOT(slotRangeChanged(QtProperty *, double, double)));
    1136     connect(rectFPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1137                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1138     connect(rectFPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1139                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1117    connect(rectFPropertyManager, SIGNAL(valueChanged(QtProperty*,QRectF)),
     1118                this, SLOT(slotValueChanged(QtProperty*,QRectF)));
     1119    connect(rectFPropertyManager, SIGNAL(constraintChanged(QtProperty*,QRectF)),
     1120                this, SLOT(slotConstraintChanged(QtProperty*,QRectF)));
     1121    connect(rectFPropertyManager, SIGNAL(decimalsChanged(QtProperty*,int)),
     1122                this, SLOT(slotDecimalsChanged(QtProperty*,int)));
     1123    connect(rectFPropertyManager->subDoublePropertyManager(), SIGNAL(valueChanged(QtProperty*,double)),
     1124                this, SLOT(slotValueChanged(QtProperty*,double)));
     1125    connect(rectFPropertyManager->subDoublePropertyManager(), SIGNAL(rangeChanged(QtProperty*,double,double)),
     1126                this, SLOT(slotRangeChanged(QtProperty*,double,double)));
     1127    connect(rectFPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1128                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1129    connect(rectFPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1130                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    11401131    // ColorPropertyManager
    11411132    QtColorPropertyManager *colorPropertyManager = new QtColorPropertyManager(this);
    11421133    d_ptr->m_typeToPropertyManager[QVariant::Color] = colorPropertyManager;
    11431134    d_ptr->m_typeToValueType[QVariant::Color] = QVariant::Color;
    1144     connect(colorPropertyManager, SIGNAL(valueChanged(QtProperty *, const QColor &)),
    1145                 this, SLOT(slotValueChanged(QtProperty *, const QColor &)));
    1146     connect(colorPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1147                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1148     connect(colorPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1149                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1150     connect(colorPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1151                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1135    connect(colorPropertyManager, SIGNAL(valueChanged(QtProperty*,QColor)),
     1136                this, SLOT(slotValueChanged(QtProperty*,QColor)));
     1137    connect(colorPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1138                this, SLOT(slotValueChanged(QtProperty*,int)));
     1139    connect(colorPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1140                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1141    connect(colorPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1142                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    11521143    // EnumPropertyManager
    11531144    int enumId = enumTypeId();
     
    11591150    d_ptr->m_typeToAttributeToAttributeType[enumId][d_ptr->m_enumIconsAttribute] =
    11601151            iconMapTypeId();
    1161     connect(enumPropertyManager, SIGNAL(valueChanged(QtProperty *, int)),
    1162                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1163     connect(enumPropertyManager, SIGNAL(enumNamesChanged(QtProperty *, const QStringList &)),
    1164                 this, SLOT(slotEnumNamesChanged(QtProperty *, const QStringList &)));
    1165     connect(enumPropertyManager, SIGNAL(enumIconsChanged(QtProperty *, const QMap<int, QIcon> &)),
    1166                 this, SLOT(slotEnumIconsChanged(QtProperty *, const QMap<int, QIcon> &)));
     1152    connect(enumPropertyManager, SIGNAL(valueChanged(QtProperty*,int)),
     1153                this, SLOT(slotValueChanged(QtProperty*,int)));
     1154    connect(enumPropertyManager, SIGNAL(enumNamesChanged(QtProperty*,QStringList)),
     1155                this, SLOT(slotEnumNamesChanged(QtProperty*,QStringList)));
     1156    connect(enumPropertyManager, SIGNAL(enumIconsChanged(QtProperty*,QMap<int,QIcon>)),
     1157                this, SLOT(slotEnumIconsChanged(QtProperty*,QMap<int,QIcon>)));
    11671158    // SizePolicyPropertyManager
    11681159    QtSizePolicyPropertyManager *sizePolicyPropertyManager = new QtSizePolicyPropertyManager(this);
    11691160    d_ptr->m_typeToPropertyManager[QVariant::SizePolicy] = sizePolicyPropertyManager;
    11701161    d_ptr->m_typeToValueType[QVariant::SizePolicy] = QVariant::SizePolicy;
    1171     connect(sizePolicyPropertyManager, SIGNAL(valueChanged(QtProperty *, const QSizePolicy &)),
    1172                 this, SLOT(slotValueChanged(QtProperty *, const QSizePolicy &)));
    1173     connect(sizePolicyPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1174                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1175     connect(sizePolicyPropertyManager->subIntPropertyManager(), SIGNAL(rangeChanged(QtProperty *, int, int)),
    1176                 this, SLOT(slotRangeChanged(QtProperty *, int, int)));
    1177     connect(sizePolicyPropertyManager->subEnumPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1178                 this, SLOT(slotValueChanged(QtProperty *, int)));
     1162    connect(sizePolicyPropertyManager, SIGNAL(valueChanged(QtProperty*,QSizePolicy)),
     1163                this, SLOT(slotValueChanged(QtProperty*,QSizePolicy)));
     1164    connect(sizePolicyPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1165                this, SLOT(slotValueChanged(QtProperty*,int)));
     1166    connect(sizePolicyPropertyManager->subIntPropertyManager(), SIGNAL(rangeChanged(QtProperty*,int,int)),
     1167                this, SLOT(slotRangeChanged(QtProperty*,int,int)));
     1168    connect(sizePolicyPropertyManager->subEnumPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1169                this, SLOT(slotValueChanged(QtProperty*,int)));
    11791170    connect(sizePolicyPropertyManager->subEnumPropertyManager(),
    1180                 SIGNAL(enumNamesChanged(QtProperty *, const QStringList &)),
    1181                 this, SLOT(slotEnumNamesChanged(QtProperty *, const QStringList &)));
    1182     connect(sizePolicyPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1183                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1184     connect(sizePolicyPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1185                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1171                SIGNAL(enumNamesChanged(QtProperty*,QStringList)),
     1172                this, SLOT(slotEnumNamesChanged(QtProperty*,QStringList)));
     1173    connect(sizePolicyPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1174                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1175    connect(sizePolicyPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1176                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    11861177    // FontPropertyManager
    11871178    QtFontPropertyManager *fontPropertyManager = new QtFontPropertyManager(this);
    11881179    d_ptr->m_typeToPropertyManager[QVariant::Font] = fontPropertyManager;
    11891180    d_ptr->m_typeToValueType[QVariant::Font] = QVariant::Font;
    1190     connect(fontPropertyManager, SIGNAL(valueChanged(QtProperty *, const QFont &)),
    1191                 this, SLOT(slotValueChanged(QtProperty *, const QFont &)));
    1192     connect(fontPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1193                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1194     connect(fontPropertyManager->subIntPropertyManager(), SIGNAL(rangeChanged(QtProperty *, int, int)),
    1195                 this, SLOT(slotRangeChanged(QtProperty *, int, int)));
    1196     connect(fontPropertyManager->subEnumPropertyManager(), SIGNAL(valueChanged(QtProperty *, int)),
    1197                 this, SLOT(slotValueChanged(QtProperty *, int)));
     1181    connect(fontPropertyManager, SIGNAL(valueChanged(QtProperty*,QFont)),
     1182                this, SLOT(slotValueChanged(QtProperty*,QFont)));
     1183    connect(fontPropertyManager->subIntPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1184                this, SLOT(slotValueChanged(QtProperty*,int)));
     1185    connect(fontPropertyManager->subIntPropertyManager(), SIGNAL(rangeChanged(QtProperty*,int,int)),
     1186                this, SLOT(slotRangeChanged(QtProperty*,int,int)));
     1187    connect(fontPropertyManager->subEnumPropertyManager(), SIGNAL(valueChanged(QtProperty*,int)),
     1188                this, SLOT(slotValueChanged(QtProperty*,int)));
    11981189    connect(fontPropertyManager->subEnumPropertyManager(),
    1199                 SIGNAL(enumNamesChanged(QtProperty *, const QStringList &)),
    1200                 this, SLOT(slotEnumNamesChanged(QtProperty *, const QStringList &)));
    1201     connect(fontPropertyManager->subBoolPropertyManager(), SIGNAL(valueChanged(QtProperty *, bool)),
    1202                 this, SLOT(slotValueChanged(QtProperty *, bool)));
    1203     connect(fontPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1204                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1205     connect(fontPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1206                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1190                SIGNAL(enumNamesChanged(QtProperty*,QStringList)),
     1191                this, SLOT(slotEnumNamesChanged(QtProperty*,QStringList)));
     1192    connect(fontPropertyManager->subBoolPropertyManager(), SIGNAL(valueChanged(QtProperty*,bool)),
     1193                this, SLOT(slotValueChanged(QtProperty*,bool)));
     1194    connect(fontPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1195                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1196    connect(fontPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1197                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    12071198    // CursorPropertyManager
    12081199    QtCursorPropertyManager *cursorPropertyManager = new QtCursorPropertyManager(this);
    12091200    d_ptr->m_typeToPropertyManager[QVariant::Cursor] = cursorPropertyManager;
    12101201    d_ptr->m_typeToValueType[QVariant::Cursor] = QVariant::Cursor;
    1211     connect(cursorPropertyManager, SIGNAL(valueChanged(QtProperty *, const QCursor &)),
    1212                 this, SLOT(slotValueChanged(QtProperty *, const QCursor &)));
     1202    connect(cursorPropertyManager, SIGNAL(valueChanged(QtProperty*,QCursor)),
     1203                this, SLOT(slotValueChanged(QtProperty*,QCursor)));
    12131204    // FlagPropertyManager
    12141205    int flagId = flagTypeId();
     
    12181209    d_ptr->m_typeToAttributeToAttributeType[flagId][d_ptr->m_flagNamesAttribute] =
    12191210            QVariant::StringList;
    1220     connect(flagPropertyManager, SIGNAL(valueChanged(QtProperty *, int)),
    1221                 this, SLOT(slotValueChanged(QtProperty *, int)));
    1222     connect(flagPropertyManager, SIGNAL(flagNamesChanged(QtProperty *, const QStringList &)),
    1223                 this, SLOT(slotFlagNamesChanged(QtProperty *, const QStringList &)));
    1224     connect(flagPropertyManager->subBoolPropertyManager(), SIGNAL(valueChanged(QtProperty *, bool)),
    1225                 this, SLOT(slotValueChanged(QtProperty *, bool)));
    1226     connect(flagPropertyManager, SIGNAL(propertyInserted(QtProperty *, QtProperty *, QtProperty *)),
    1227                 this, SLOT(slotPropertyInserted(QtProperty *, QtProperty *, QtProperty *)));
    1228     connect(flagPropertyManager, SIGNAL(propertyRemoved(QtProperty *, QtProperty *)),
    1229                 this, SLOT(slotPropertyRemoved(QtProperty *, QtProperty *)));
     1211    connect(flagPropertyManager, SIGNAL(valueChanged(QtProperty*,int)),
     1212                this, SLOT(slotValueChanged(QtProperty*,int)));
     1213    connect(flagPropertyManager, SIGNAL(flagNamesChanged(QtProperty*,QStringList)),
     1214                this, SLOT(slotFlagNamesChanged(QtProperty*,QStringList)));
     1215    connect(flagPropertyManager->subBoolPropertyManager(), SIGNAL(valueChanged(QtProperty*,bool)),
     1216                this, SLOT(slotValueChanged(QtProperty*,bool)));
     1217    connect(flagPropertyManager, SIGNAL(propertyInserted(QtProperty*,QtProperty*,QtProperty*)),
     1218                this, SLOT(slotPropertyInserted(QtProperty*,QtProperty*,QtProperty*)));
     1219    connect(flagPropertyManager, SIGNAL(propertyRemoved(QtProperty*,QtProperty*)),
     1220                this, SLOT(slotPropertyRemoved(QtProperty*,QtProperty*)));
    12301221    // FlagPropertyManager
    12311222    int groupId = groupTypeId();
     
    12411232{
    12421233    clear();
    1243     delete d_ptr;
    12441234}
    12451235
     
    19361926*/
    19371927QtVariantEditorFactory::QtVariantEditorFactory(QObject *parent)
    1938     : QtAbstractEditorFactory<QtVariantPropertyManager>(parent)
    1939 {
    1940     d_ptr = new QtVariantEditorFactoryPrivate();
     1928    : QtAbstractEditorFactory<QtVariantPropertyManager>(parent), d_ptr(new QtVariantEditorFactoryPrivate())
     1929{
    19411930    d_ptr->q_ptr = this;
    19421931
     
    20001989QtVariantEditorFactory::~QtVariantEditorFactory()
    20011990{
    2002     delete d_ptr;
    20031991}
    20041992
     
    22762264}
    22772265
    2278 #if QT_VERSION >= 0x040400
    22792266QT_END_NAMESPACE
    2280 #endif
    22812267
    22822268#include "moc_qtvariantproperty.cpp"
Note: See TracChangeset for help on using the changeset viewer.