diff options
author | Alan Alpert <alan.alpert@nokia.com> | 2009-11-11 07:46:20 (GMT) |
---|---|---|
committer | Alan Alpert <alan.alpert@nokia.com> | 2009-11-11 07:46:20 (GMT) |
commit | 8e5166aba8c8d79e47d4c4fccd5acf52f9cffec6 (patch) | |
tree | f9b91b73e52ec389107cc8791ac76e87f962944b /src | |
parent | 6ac7ce79b6041a7c35d08cb28f775dead9701c4b (diff) | |
parent | 0faef2ba318b7df095d5c20fdddd0933ae4912c3 (diff) | |
download | Qt-8e5166aba8c8d79e47d4c4fccd5acf52f9cffec6.zip Qt-8e5166aba8c8d79e47d4c4fccd5acf52f9cffec6.tar.gz Qt-8e5166aba8c8d79e47d4c4fccd5acf52f9cffec6.tar.bz2 |
Merge branch 'kinetic-declarativeui' of git@scm.dev.nokia.troll.no:qt/kinetic into kinetic-declarativeui
Conflicts:
src/declarative/util/util.pri
Diffstat (limited to 'src')
26 files changed, 94 insertions, 124 deletions
diff --git a/src/declarative/declarative.pro b/src/declarative/declarative.pro index 41fee96..e5e604b 100644 --- a/src/declarative/declarative.pro +++ b/src/declarative/declarative.pro @@ -19,7 +19,6 @@ include(3rdparty/3rdparty.pri) include(util/util.pri) include(graphicsitems/graphicsitems.pri) include(qml/qml.pri) -include(extra/extra.pri) include(widgets/widgets.pri) include(debugger/debugger.pri) diff --git a/src/declarative/extra/extra.pri b/src/declarative/extra/extra.pri deleted file mode 100644 index 85ff6ea..0000000 --- a/src/declarative/extra/extra.pri +++ /dev/null @@ -1,20 +0,0 @@ -SOURCES += \ - extra/qnumberformat.cpp \ - extra/qmlnumberformatter.cpp \ - extra/qmldatetimeformatter.cpp \ - extra/qmlbehavior.cpp \ - extra/qmlfontloader.cpp - -HEADERS += \ - extra/qnumberformat_p.h \ - extra/qmlnumberformatter_p.h \ - extra/qmldatetimeformatter_p.h \ - extra/qmlbehavior_p.h \ - extra/qmlfontloader_p.h - -contains(QT_CONFIG, xmlpatterns) { - QT+=xmlpatterns - SOURCES += extra/qmlxmllistmodel.cpp - HEADERS += extra/qmlxmllistmodel_p.h -} - diff --git a/src/declarative/graphicsitems/qmlgraphicsanimatedimage.cpp b/src/declarative/graphicsitems/qmlgraphicsanimatedimage.cpp index db28134..8c91056 100644 --- a/src/declarative/graphicsitems/qmlgraphicsanimatedimage.cpp +++ b/src/declarative/graphicsitems/qmlgraphicsanimatedimage.cpp @@ -62,7 +62,7 @@ QT_BEGIN_NAMESPACE QMovie::supportedFormats(). \table - \row + \row \o \image animatedimageitem.gif \o \qml diff --git a/src/declarative/graphicsitems/qmlgraphicsitem.cpp b/src/declarative/graphicsitems/qmlgraphicsitem.cpp index 572aa98..aa5c4cb 100644 --- a/src/declarative/graphicsitems/qmlgraphicsitem.cpp +++ b/src/declarative/graphicsitems/qmlgraphicsitem.cpp @@ -1329,9 +1329,9 @@ QmlGraphicsKeysAttached *QmlGraphicsKeysAttached::qmlAttachedProperties(QObject Key handling is available to all Item-based visual elements via the \l {Keys}{Keys} attached property. The \e Keys attached property provides basic handlers such - as \l {Keys::onPressed(event)}{onPressed} and \l {Keys::onReleased(event)}{onReleased}, + as \l {Keys::onPressed}{onPressed} and \l {Keys::onReleased}{onReleased}, as well as handlers for specific keys, such as - \l {Keys::onCancelPressed(event)}{onCancelPressed}. The example below + \l {Keys::onCancelPressed}{onCancelPressed}. The example below assigns \l {qmlfocus}{focus} to the item and handles the Left key via the general \e onPressed handler and the Select key via the onSelectPressed handler: diff --git a/src/declarative/graphicsitems/qmlgraphicslistview.cpp b/src/declarative/graphicsitems/qmlgraphicslistview.cpp index 12bf0d8..edcd094 100644 --- a/src/declarative/graphicsitems/qmlgraphicslistview.cpp +++ b/src/declarative/graphicsitems/qmlgraphicslistview.cpp @@ -1663,7 +1663,7 @@ void QmlGraphicsListView::keyPressEvent(QKeyEvent *event) } /*! - \qmlmethod ListView::incrementCurrentIndex + \qmlmethod ListView::incrementCurrentIndex() Increments the current index. The current index will wrap if keyNavigationWraps is true and it is currently at the end. @@ -1680,7 +1680,7 @@ void QmlGraphicsListView::incrementCurrentIndex() } /*! - \qmlmethod ListView::decrementCurrentIndex + \qmlmethod ListView::decrementCurrentIndex() Decrements the current index. The current index will wrap if keyNavigationWraps is true and it is currently at the beginning. diff --git a/src/declarative/graphicsitems/qmlgraphicsparticles.cpp b/src/declarative/graphicsitems/qmlgraphicsparticles.cpp index 399e1a5..a0b41e8 100644 --- a/src/declarative/graphicsitems/qmlgraphicsparticles.cpp +++ b/src/declarative/graphicsitems/qmlgraphicsparticles.cpp @@ -1169,7 +1169,7 @@ void QmlGraphicsParticles::setMotion(QmlGraphicsParticleMotion *motion) } /*! - \qmlmethod Particles::burst + \qmlmethod Particles::burst(int count, int emissionRate) Initiates a burst of particles. diff --git a/src/declarative/qml/qmldom.cpp b/src/declarative/qml/qmldom.cpp index 39d6730..f4a137c 100644 --- a/src/declarative/qml/qmldom.cpp +++ b/src/declarative/qml/qmldom.cpp @@ -57,13 +57,6 @@ QmlDomDocumentPrivate::QmlDomDocumentPrivate() { } -QmlDomDocumentPrivate::QmlDomDocumentPrivate(const QmlDomDocumentPrivate &other) -: QSharedData(other), root(0) -{ - root = other.root; - if (root) root->addref(); -} - QmlDomDocumentPrivate::~QmlDomDocumentPrivate() { if (root) root->release(); @@ -141,7 +134,7 @@ QList<QmlDomImport> QmlDomDocument::imports() const /*! Loads a QmlDomDocument from \a data. \a data should be valid QML data. On success, true is returned. If the \a data is malformed, false - is returned and QmlDomDocument::loadError() contains an error description. + is returned and QmlDomDocument::errors() contains an error description. \sa QmlDomDocument::loadError() */ @@ -160,7 +153,8 @@ bool QmlDomDocument::load(QmlEngine *engine, const QByteArray &data, const QUrl td->release(); component->release(); return false; - } else if(td->status == QmlCompositeTypeData::Waiting) { + } else if(td->status == QmlCompositeTypeData::Waiting || + td->status == QmlCompositeTypeData::WaitingResources) { QmlError error; error.setDescription(QLatin1String("QmlDomDocument supports local types only")); d->errors << error; @@ -234,13 +228,6 @@ QmlDomPropertyPrivate::QmlDomPropertyPrivate() { } -QmlDomPropertyPrivate::QmlDomPropertyPrivate(const QmlDomPropertyPrivate &other) -: QSharedData(other), property(0) -{ - property = other.property; - if (property) property->addref(); -} - QmlDomPropertyPrivate::~QmlDomPropertyPrivate() { if (property) property->release(); @@ -251,13 +238,6 @@ QmlDomDynamicPropertyPrivate::QmlDomDynamicPropertyPrivate(): { } -QmlDomDynamicPropertyPrivate::QmlDomDynamicPropertyPrivate(const QmlDomDynamicPropertyPrivate &other) -: QSharedData(other), valid(other.valid) -{ - property = other.property; - if (valid && property.defaultValue) property.defaultValue->addref(); -} - QmlDomDynamicPropertyPrivate::~QmlDomDynamicPropertyPrivate() { if (valid && property.defaultValue) property.defaultValue->release(); @@ -307,6 +287,15 @@ QmlDomProperty &QmlDomProperty::operator=(const QmlDomProperty &other) } /*! + Returns true if this is a valid QmlDomProperty, false otherwise. +*/ +bool QmlDomProperty::isValid() const +{ + return d->property != 0; +} + + +/*! Return the name of this property. \qml @@ -482,7 +471,7 @@ int QmlDomDynamicProperty::propertyType() const return QMetaType::type("QColor"); case QmlParser::Object::DynamicProperty::Date: - return QMetaType::type("QDateTime"); + return QMetaType::type("QDate"); case QmlParser::Object::DynamicProperty::Int: return QMetaType::type("int"); @@ -507,6 +496,14 @@ int QmlDomDynamicProperty::propertyType() const return -1; } +QByteArray QmlDomDynamicProperty::propertyTypeName() const +{ + if (isValid()) + return d->property.customType; + + return QByteArray(); +} + /*! Return true if this property is used as a default property in the QML document. @@ -539,6 +536,7 @@ QmlDomProperty QmlDomDynamicProperty::defaultValue() const if (isValid() && d->property.defaultValue) { rp.d->property = d->property.defaultValue; + rp.d->propertyName = propertyName(); rp.d->property->addref(); } @@ -570,18 +568,10 @@ int QmlDomDynamicProperty::length() const } QmlDomObjectPrivate::QmlDomObjectPrivate() -: object(0), isVirtualComponent(false) +: object(0) { } -QmlDomObjectPrivate::QmlDomObjectPrivate(const QmlDomObjectPrivate &other) -: QSharedData(other), object(0), isVirtualComponent(false) -{ - object = other.object; - if (object) object->addref(); - isVirtualComponent = other.isVirtualComponent; -} - QmlDomObjectPrivate::~QmlDomObjectPrivate() { if (object) object->release(); @@ -665,16 +655,6 @@ QmlDomObject::QmlDomObject() } /*! - Construct a new QmlDomObject with the specified \a objectType. -*/ -QmlDomObject::QmlDomObject(const QByteArray &objectType) -: d(new QmlDomObjectPrivate) -{ - Q_UNUSED(objectType); - qWarning("QmlDomObject::QmlDomObject(const QByteArray &): Not implemented"); -} - -/*! Create a copy of \a other QmlDomObject. */ QmlDomObject::QmlDomObject(const QmlDomObject &other) @@ -785,7 +765,7 @@ QList<QmlDomProperty> QmlDomObject::properties() const { QList<QmlDomProperty> rv; - if (!d->object) + if (!d->object || isComponent()) return rv; QmlDomObjectPrivate::Properties properties = d->properties(); @@ -853,6 +833,9 @@ QmlDomDynamicProperty QmlDomObject::dynamicProperty(const QByteArray &name) cons { QmlDomDynamicProperty p; + if (!isValid()) + return p; + for (int i = 0; i < d->object->dynamicProperties.size(); ++i) { if (d->object->dynamicProperties.at(i).name == name) { p.d = new QmlDomDynamicPropertyPrivate; @@ -900,8 +883,7 @@ QByteArray QmlDomObject::customTypeData() const */ bool QmlDomObject::isComponent() const { - return d->isVirtualComponent || - (d->object && d->object->typeName == "Qt/Component"); + return (d->object && d->object->typeName == "Qt/Component"); } /*! @@ -958,13 +940,6 @@ QmlDomBasicValuePrivate::QmlDomBasicValuePrivate() { } -QmlDomBasicValuePrivate::QmlDomBasicValuePrivate(const QmlDomBasicValuePrivate &other) -: QSharedData(other), value(0) -{ - value = other.value; - if (value) value->addref(); -} - QmlDomBasicValuePrivate::~QmlDomBasicValuePrivate() { if (value) value->release(); @@ -1250,15 +1225,6 @@ QmlDomValuePrivate::QmlDomValuePrivate() { } -QmlDomValuePrivate::QmlDomValuePrivate(const QmlDomValuePrivate &other) -: QSharedData(other), property(0), value(0) -{ - property = other.property; - value = other.value; - if (property) property->addref(); - if (value) value->addref(); -} - QmlDomValuePrivate::~QmlDomValuePrivate() { if (property) property->release(); @@ -1754,10 +1720,7 @@ Item { QmlDomObject QmlDomComponent::componentRoot() const { QmlDomObject rv; - if (d->isVirtualComponent) { - rv.d->object = d->object; - rv.d->object->addref(); - } else if (d->object) { + if (d->object) { QmlParser::Object *obj = 0; if (d->object->defaultProperty && d->object->defaultProperty->values.count() == 1 && @@ -1778,11 +1741,6 @@ QmlDomImportPrivate::QmlDomImportPrivate() { } -QmlDomImportPrivate::QmlDomImportPrivate(const QmlDomImportPrivate &other) -: QSharedData(other) -{ -} - QmlDomImportPrivate::~QmlDomImportPrivate() { } diff --git a/src/declarative/qml/qmldom.h b/src/declarative/qml/qmldom.h index 8c43c4a..250307f 100644 --- a/src/declarative/qml/qmldom.h +++ b/src/declarative/qml/qmldom.h @@ -92,6 +92,8 @@ public: ~QmlDomProperty(); QmlDomProperty &operator=(const QmlDomProperty &); + bool isValid() const; + QByteArray propertyName() const; QList<QByteArray> propertyNameParts() const; @@ -121,6 +123,7 @@ public: QByteArray propertyName() const; int propertyType() const; + QByteArray propertyTypeName() const; bool isDefaultProperty() const; @@ -139,7 +142,6 @@ class Q_DECLARATIVE_EXPORT QmlDomObject { public: QmlDomObject(); - QmlDomObject(const QByteArray &); QmlDomObject(const QmlDomObject &); ~QmlDomObject(); QmlDomObject &operator=(const QmlDomObject &); diff --git a/src/declarative/qml/qmldom_p.h b/src/declarative/qml/qmldom_p.h index 4b4de80..cb0d884 100644 --- a/src/declarative/qml/qmldom_p.h +++ b/src/declarative/qml/qmldom_p.h @@ -62,7 +62,8 @@ class QmlDomDocumentPrivate : public QSharedData { public: QmlDomDocumentPrivate(); - QmlDomDocumentPrivate(const QmlDomDocumentPrivate &); + QmlDomDocumentPrivate(const QmlDomDocumentPrivate &o) + : QSharedData(o) { qFatal("Not impl"); } ~QmlDomDocumentPrivate(); QList<QmlError> errors; @@ -75,7 +76,8 @@ class QmlDomObjectPrivate : public QSharedData { public: QmlDomObjectPrivate(); - QmlDomObjectPrivate(const QmlDomObjectPrivate &); + QmlDomObjectPrivate(const QmlDomObjectPrivate &o) + : QSharedData(o) { qFatal("Not impl"); } ~QmlDomObjectPrivate(); typedef QList<QPair<QmlParser::Property *, QByteArray> > Properties; @@ -83,14 +85,14 @@ public: Properties properties(QmlParser::Property *) const; QmlParser::Object *object; - bool isVirtualComponent; }; class QmlDomPropertyPrivate : public QSharedData { public: QmlDomPropertyPrivate(); - QmlDomPropertyPrivate(const QmlDomPropertyPrivate &); + QmlDomPropertyPrivate(const QmlDomPropertyPrivate &o) + : QSharedData(o) { qFatal("Not impl"); } ~QmlDomPropertyPrivate(); QByteArray propertyName; @@ -101,7 +103,8 @@ class QmlDomDynamicPropertyPrivate : public QSharedData { public: QmlDomDynamicPropertyPrivate(); - QmlDomDynamicPropertyPrivate(const QmlDomDynamicPropertyPrivate &); + QmlDomDynamicPropertyPrivate(const QmlDomDynamicPropertyPrivate &o) + : QSharedData(o) { qFatal("Not impl"); } ~QmlDomDynamicPropertyPrivate(); bool valid; @@ -112,7 +115,8 @@ class QmlDomValuePrivate : public QSharedData { public: QmlDomValuePrivate(); - QmlDomValuePrivate(const QmlDomValuePrivate &); + QmlDomValuePrivate(const QmlDomValuePrivate &o) + : QSharedData(o) { qFatal("Not impl"); } ~QmlDomValuePrivate(); QmlParser::Property *property; @@ -123,7 +127,8 @@ class QmlDomBasicValuePrivate : public QSharedData { public: QmlDomBasicValuePrivate(); - QmlDomBasicValuePrivate(const QmlDomBasicValuePrivate &); + QmlDomBasicValuePrivate(const QmlDomBasicValuePrivate &o) + : QSharedData(o) { qFatal("Not impl"); } ~QmlDomBasicValuePrivate(); QmlParser::Value *value; @@ -133,7 +138,8 @@ class QmlDomImportPrivate : public QSharedData { public: QmlDomImportPrivate(); - QmlDomImportPrivate(const QmlDomImportPrivate &); + QmlDomImportPrivate(const QmlDomImportPrivate &o) + : QSharedData(o) { qFatal("Not impl"); } ~QmlDomImportPrivate(); enum Type { Library, File }; diff --git a/src/declarative/qml/qmlscriptparser.cpp b/src/declarative/qml/qmlscriptparser.cpp index 526894e..b622c24 100644 --- a/src/declarative/qml/qmlscriptparser.cpp +++ b/src/declarative/qml/qmlscriptparser.cpp @@ -342,10 +342,17 @@ ProcessAST::defineObjectBinding_helper(AST::UiQualifiedId *propertyName, Value *v = new Value; v->object = obj; v->location = obj->location; - if (state.property) + if (state.property) { state.property->addValue(v); - else - state.object->getDefaultProperty()->addValue(v); + } else { + Property *defaultProp = state.object->getDefaultProperty(); + if (defaultProp->location.start.line == -1) { + defaultProp->location = v->location; + defaultProp->location.end = defaultProp->location.start; + defaultProp->location.range.length = 0; + } + defaultProp->addValue(v); + } } } @@ -583,8 +590,8 @@ bool ProcessAST::visit(AST::UiPublicMember *node) QmlScriptParser::TypeReference *typeRef = _parser->findOrCreateType(memberType); typeRef->refObjects.append(_stateStack.top().object); - property.customType = memberType.toUtf8(); } + property.customType = memberType.toUtf8(); property.name = name.toUtf8(); property.location = location(node->firstSourceLocation(), node->lastSourceLocation()); diff --git a/src/declarative/extra/qmlbehavior.cpp b/src/declarative/util/qmlbehavior.cpp index 8364d8c..8364d8c 100644 --- a/src/declarative/extra/qmlbehavior.cpp +++ b/src/declarative/util/qmlbehavior.cpp diff --git a/src/declarative/extra/qmlbehavior_p.h b/src/declarative/util/qmlbehavior_p.h index 9f85f84..9f85f84 100644 --- a/src/declarative/extra/qmlbehavior_p.h +++ b/src/declarative/util/qmlbehavior_p.h diff --git a/src/declarative/extra/qmldatetimeformatter.cpp b/src/declarative/util/qmldatetimeformatter.cpp index 983287e..983287e 100644 --- a/src/declarative/extra/qmldatetimeformatter.cpp +++ b/src/declarative/util/qmldatetimeformatter.cpp diff --git a/src/declarative/extra/qmldatetimeformatter_p.h b/src/declarative/util/qmldatetimeformatter_p.h index e350f96..e350f96 100644 --- a/src/declarative/extra/qmldatetimeformatter_p.h +++ b/src/declarative/util/qmldatetimeformatter_p.h diff --git a/src/declarative/extra/qmlfontloader.cpp b/src/declarative/util/qmlfontloader.cpp index 36ee1bb..36ee1bb 100644 --- a/src/declarative/extra/qmlfontloader.cpp +++ b/src/declarative/util/qmlfontloader.cpp diff --git a/src/declarative/extra/qmlfontloader_p.h b/src/declarative/util/qmlfontloader_p.h index d02a181..d02a181 100644 --- a/src/declarative/extra/qmlfontloader_p.h +++ b/src/declarative/util/qmlfontloader_p.h diff --git a/src/declarative/util/qmllistmodel.cpp b/src/declarative/util/qmllistmodel.cpp index 19282eb..9e91147 100644 --- a/src/declarative/util/qmllistmodel.cpp +++ b/src/declarative/util/qmllistmodel.cpp @@ -467,7 +467,7 @@ void QmlListModel::remove(int index) } /*! - \qmlmethod ListModel::insert(index,dict) + \qmlmethod ListModel::insert(int index, jsobject dict) Adds a new item to the list model at position \a index, with the values in \a dict. @@ -500,7 +500,7 @@ void QmlListModel::insert(int index, const QScriptValue& valuemap) } /*! - \qmlmethod ListModel::move(from,to,n) + \qmlmethod ListModel::move(int from, int to, int n) Moves \a n items \a from one position \a to another. @@ -551,7 +551,7 @@ void QmlListModel::move(int from, int to, int n) } /*! - \qmlmethod ListModel::append(dict) + \qmlmethod ListModel::append(jsobject dict) Adds a new item to the end of the list model, with the values in \a dict. @@ -578,7 +578,7 @@ void QmlListModel::append(const QScriptValue& valuemap) } /*! - \qmlmethod object ListModel::get(index) + \qmlmethod object ListModel::get(int index) Returns the item at \a index in the list model. @@ -620,7 +620,7 @@ QScriptValue QmlListModel::get(int index) const } /*! - \qmlmethod ListModel::set(index,dict) + \qmlmethod ListModel::set(int index, jsobject dict) Changes the item at \a index in the list model with the values in \a dict. Properties not appearing in \a valuemap @@ -663,7 +663,7 @@ void QmlListModel::set(int index, const QScriptValue& valuemap) } /*! - \qmlmethod ListModel::set(index,property,value) + \qmlmethod ListModel::set(int index, string property, variant value) Changes the \a property of the item at \a index in the list model to \a value. diff --git a/src/declarative/extra/qmlnumberformatter.cpp b/src/declarative/util/qmlnumberformatter.cpp index 4007d95..b09be5b 100644 --- a/src/declarative/extra/qmlnumberformatter.cpp +++ b/src/declarative/util/qmlnumberformatter.cpp @@ -108,7 +108,7 @@ QString QmlNumberFormatter::text() const } /*! - \qmlproperty qreal NumberFormatter::number + \qmlproperty real NumberFormatter::number A single point precision number. (Doubles are not yet supported) diff --git a/src/declarative/extra/qmlnumberformatter_p.h b/src/declarative/util/qmlnumberformatter_p.h index 0036cb9..0036cb9 100644 --- a/src/declarative/extra/qmlnumberformatter_p.h +++ b/src/declarative/util/qmlnumberformatter_p.h diff --git a/src/declarative/util/qmlopenmetaobject_p.h b/src/declarative/util/qmlopenmetaobject_p.h index 1cf12f8..7a5b4ce 100644 --- a/src/declarative/util/qmlopenmetaobject_p.h +++ b/src/declarative/util/qmlopenmetaobject_p.h @@ -43,7 +43,7 @@ #define QMLOPENMETAOBJECT_H #include <QtCore/QMetaObject> -#include <QtCore/private/qobject_p.h> +#include <private/qobject_p.h> #include <QtCore/QObject> QT_BEGIN_HEADER diff --git a/src/declarative/extra/qmlxmllistmodel.cpp b/src/declarative/util/qmlxmllistmodel.cpp index 4f213a8..3d90b44 100644 --- a/src/declarative/extra/qmlxmllistmodel.cpp +++ b/src/declarative/util/qmlxmllistmodel.cpp @@ -463,7 +463,7 @@ QHash<int,QVariant> QmlXmlListModel::data(int index, const QList<int> &roles) co for (int i = 0; i < roles.size(); ++i) { int role = roles.at(i); int roleIndex = d->roles.indexOf(role); - rv.insert(role, d->data.at(roleIndex).at(index)); + rv.insert(role, roleIndex == -1 ? QVariant() : d->data.at(roleIndex).at(index)); } return rv; } diff --git a/src/declarative/extra/qmlxmllistmodel_p.h b/src/declarative/util/qmlxmllistmodel_p.h index 18bf9d2..18bf9d2 100644 --- a/src/declarative/extra/qmlxmllistmodel_p.h +++ b/src/declarative/util/qmlxmllistmodel_p.h diff --git a/src/declarative/extra/qnumberformat.cpp b/src/declarative/util/qnumberformat.cpp index c6a03e9..c6a03e9 100644 --- a/src/declarative/extra/qnumberformat.cpp +++ b/src/declarative/util/qnumberformat.cpp diff --git a/src/declarative/extra/qnumberformat_p.h b/src/declarative/util/qnumberformat_p.h index 1a7b8e4..1a7b8e4 100644 --- a/src/declarative/extra/qnumberformat_p.h +++ b/src/declarative/util/qnumberformat_p.h diff --git a/src/declarative/util/util.pri b/src/declarative/util/util.pri index e043cca..d2faec9 100644 --- a/src/declarative/util/util.pri +++ b/src/declarative/util/util.pri @@ -21,7 +21,12 @@ SOURCES += \ util/qmltimer.cpp \ util/qmlbind.cpp \ util/qmlpropertymap.cpp \ - util/qmlpixmapcache.cpp + util/qmlpixmapcache.cpp \ + util/qnumberformat.cpp \ + util/qmlnumberformatter.cpp \ + util/qmldatetimeformatter.cpp \ + util/qmlbehavior.cpp \ + util/qmlfontloader.cpp HEADERS += \ util/qmlview.h \ @@ -49,4 +54,15 @@ HEADERS += \ util/qmltimer_p.h \ util/qmlbind_p.h \ util/qmlpropertymap.h \ - util/qmlpixmapcache_p.h + util/qmlpixmapcache_p.h \ + util/qnumberformat_p.h \ + util/qmlnumberformatter_p.h \ + util/qmldatetimeformatter_p.h \ + util/qmlbehavior_p.h \ + util/qmlfontloader_p.h + +contains(QT_CONFIG, xmlpatterns) { + QT+=xmlpatterns + SOURCES += util/qmlxmllistmodel.cpp + HEADERS += util/qmlxmllistmodel_p.h +} diff --git a/src/network/kernel/qhostinfo_p.h b/src/network/kernel/qhostinfo_p.h index 64c5152..afd3570 100644 --- a/src/network/kernel/qhostinfo_p.h +++ b/src/network/kernel/qhostinfo_p.h @@ -161,9 +161,11 @@ public Q_SLOTS: cond.wakeOne(); } #ifndef QT_NO_THREAD - if (!wait(QHOSTINFO_THREAD_WAIT)) + if (!wait(QHOSTINFO_THREAD_WAIT)) { terminate(); - wait(); + // Don't wait forever; see QTBUG-5296. + wait(QHOSTINFO_THREAD_WAIT); + } #endif } |