summaryrefslogtreecommitdiffstats
path: root/src/declarative
diff options
context:
space:
mode:
Diffstat (limited to 'src/declarative')
-rw-r--r--src/declarative/QmlChanges.txt2
-rw-r--r--src/declarative/debugger/qdeclarativedebugclient.cpp2
-rw-r--r--src/declarative/debugger/qdeclarativedebugservice.cpp12
-rw-r--r--src/declarative/debugger/qdeclarativedebugtrace.cpp8
-rw-r--r--src/declarative/debugger/qdeclarativeenginedebug.cpp20
-rw-r--r--src/declarative/debugger/qdeclarativeenginedebug_p.h6
-rw-r--r--src/declarative/debugger/qdeclarativeenginedebugservice.cpp22
-rw-r--r--src/declarative/debugger/qpacketprotocol.cpp12
-rw-r--r--src/declarative/graphicsitems/qdeclarativeevents.cpp2
-rw-r--r--src/declarative/graphicsitems/qdeclarativefocuspanel.cpp2
-rw-r--r--src/declarative/graphicsitems/qdeclarativegridview.cpp20
-rw-r--r--src/declarative/graphicsitems/qdeclarativeimage.cpp12
-rw-r--r--src/declarative/graphicsitems/qdeclarativeitem.cpp2
-rw-r--r--src/declarative/graphicsitems/qdeclarativelistview.cpp30
-rw-r--r--src/declarative/graphicsitems/qdeclarativeloader.cpp28
-rw-r--r--src/declarative/graphicsitems/qdeclarativemousearea.cpp4
-rw-r--r--src/declarative/graphicsitems/qdeclarativepathview.cpp2
-rw-r--r--src/declarative/graphicsitems/qdeclarativepositioners.cpp4
-rw-r--r--src/declarative/graphicsitems/qdeclarativetext.cpp30
-rw-r--r--src/declarative/graphicsitems/qdeclarativetextedit.cpp2
-rw-r--r--src/declarative/graphicsitems/qdeclarativetextedit_p.h2
-rw-r--r--src/declarative/graphicsitems/qdeclarativetextinput.cpp4
-rw-r--r--src/declarative/graphicsitems/qdeclarativetextlayout.cpp12
-rw-r--r--src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp12
-rw-r--r--src/declarative/qml/qbitfield_p.h8
-rw-r--r--src/declarative/qml/qdeclarative.h30
-rw-r--r--src/declarative/qml/qdeclarativebinding.cpp26
-rw-r--r--src/declarative/qml/qdeclarativebinding_p.h2
-rw-r--r--src/declarative/qml/qdeclarativebinding_p_p.h2
-rw-r--r--src/declarative/qml/qdeclarativeboundsignal.cpp14
-rw-r--r--src/declarative/qml/qdeclarativeboundsignal_p.h2
-rw-r--r--src/declarative/qml/qdeclarativecleanup.cpp4
-rw-r--r--src/declarative/qml/qdeclarativecleanup_p.h2
-rw-r--r--src/declarative/qml/qdeclarativecompiledbindings.cpp152
-rw-r--r--src/declarative/qml/qdeclarativecompileddata.cpp4
-rw-r--r--src/declarative/qml/qdeclarativecompiler.cpp122
-rw-r--r--src/declarative/qml/qdeclarativecompiler_p.h32
-rw-r--r--src/declarative/qml/qdeclarativecomponent.cpp42
-rw-r--r--src/declarative/qml/qdeclarativecomponent_p.h10
-rw-r--r--src/declarative/qml/qdeclarativecontext_p.h6
-rw-r--r--src/declarative/qml/qdeclarativecontextscriptclass.cpp42
-rw-r--r--src/declarative/qml/qdeclarativecontextscriptclass_p.h4
-rw-r--r--src/declarative/qml/qdeclarativecustomparser.cpp4
-rw-r--r--src/declarative/qml/qdeclarativecustomparser_p.h2
-rw-r--r--src/declarative/qml/qdeclarativedata_p.h10
-rw-r--r--src/declarative/qml/qdeclarativedirparser.cpp2
-rw-r--r--src/declarative/qml/qdeclarativedom_p.h8
-rw-r--r--src/declarative/qml/qdeclarativedom_p_p.h4
-rw-r--r--src/declarative/qml/qdeclarativeengine.cpp2
-rw-r--r--src/declarative/qml/qdeclarativeerror.cpp6
-rw-r--r--src/declarative/qml/qdeclarativeexpression.cpp64
-rw-r--r--src/declarative/qml/qdeclarativeexpression.h2
-rw-r--r--src/declarative/qml/qdeclarativeexpression_p.h20
-rw-r--r--src/declarative/qml/qdeclarativeextensionplugin.cpp20
-rw-r--r--src/declarative/qml/qdeclarativefastproperties.cpp12
-rw-r--r--src/declarative/qml/qdeclarativeglobal_p.h10
-rw-r--r--src/declarative/qml/qdeclarativeglobalscriptclass.cpp6
-rw-r--r--src/declarative/qml/qdeclarativeguard_p.h14
-rw-r--r--src/declarative/qml/qdeclarativeimageprovider.cpp24
-rw-r--r--src/declarative/qml/qdeclarativeimport.cpp66
-rw-r--r--src/declarative/qml/qdeclarativeimport_p.h12
-rw-r--r--src/declarative/qml/qdeclarativeinclude.cpp14
-rw-r--r--src/declarative/qml/qdeclarativeinfo.cpp4
-rw-r--r--src/declarative/qml/qdeclarativeinstruction_p.h12
-rw-r--r--src/declarative/qml/qdeclarativeintegercache_p.h4
-rw-r--r--src/declarative/qml/qdeclarativelist.cpp30
-rw-r--r--src/declarative/qml/qdeclarativelistscriptclass.cpp6
-rw-r--r--src/declarative/qml/qdeclarativelistscriptclass_p.h2
-rw-r--r--src/declarative/qml/qdeclarativemetatype.cpp26
-rw-r--r--src/declarative/qml/qdeclarativemetatype_p.h2
-rw-r--r--src/declarative/qml/qdeclarativenotifier.cpp8
-rw-r--r--src/declarative/qml/qdeclarativenotifier_p.h20
-rw-r--r--src/declarative/qml/qdeclarativeobjectscriptclass.cpp50
-rw-r--r--src/declarative/qml/qdeclarativeobjectscriptclass_p.h8
-rw-r--r--src/declarative/qml/qdeclarativeparser.cpp22
-rw-r--r--src/declarative/qml/qdeclarativeparser_p.h24
-rw-r--r--src/declarative/qml/qdeclarativeparserstatus.cpp2
-rw-r--r--src/declarative/qml/qdeclarativeprivate.h10
-rw-r--r--src/declarative/qml/qdeclarativeproperty.cpp144
-rw-r--r--src/declarative/qml/qdeclarativeproperty.h2
-rw-r--r--src/declarative/qml/qdeclarativeproperty_p.h10
-rw-r--r--src/declarative/qml/qdeclarativepropertycache.cpp30
-rw-r--r--src/declarative/qml/qdeclarativepropertycache_p.h22
-rw-r--r--src/declarative/qml/qdeclarativeproxymetaobject.cpp4
-rw-r--r--src/declarative/qml/qdeclarativerewrite.cpp2
-rw-r--r--src/declarative/qml/qdeclarativerewrite_p.h2
-rw-r--r--src/declarative/qml/qdeclarativescriptparser.cpp80
-rw-r--r--src/declarative/qml/qdeclarativescriptparser_p.h2
-rw-r--r--src/declarative/qml/qdeclarativetypeloader.cpp62
-rw-r--r--src/declarative/qml/qdeclarativetypeloader_p.h6
-rw-r--r--src/declarative/qml/qdeclarativetypenamecache_p.h2
-rw-r--r--src/declarative/qml/qdeclarativetypenamescriptclass.cpp8
-rw-r--r--src/declarative/qml/qdeclarativetypenamescriptclass_p.h2
-rw-r--r--src/declarative/qml/qdeclarativevaluetype_p.h6
-rw-r--r--src/declarative/qml/qdeclarativevaluetypescriptclass.cpp14
-rw-r--r--src/declarative/qml/qdeclarativevaluetypescriptclass_p.h2
-rw-r--r--src/declarative/qml/qdeclarativevme.cpp178
-rw-r--r--src/declarative/qml/qdeclarativevme_p.h10
-rw-r--r--src/declarative/qml/qdeclarativevmemetaobject.cpp64
-rw-r--r--src/declarative/qml/qdeclarativevmemetaobject_p.h2
-rw-r--r--src/declarative/qml/qdeclarativeworkerscript.cpp2
-rw-r--r--src/declarative/qml/qdeclarativexmlhttprequest.cpp88
-rw-r--r--src/declarative/qml/qpodvector_p.h10
-rw-r--r--src/declarative/qml/rewriter/textwriter_p.h48
-rw-r--r--src/declarative/util/qdeclarativeanimation_p_p.h2
-rw-r--r--src/declarative/util/qdeclarativeconnections.cpp2
-rw-r--r--src/declarative/util/qdeclarativefontloader.cpp8
-rw-r--r--src/declarative/util/qdeclarativelistmodel.cpp20
-rw-r--r--src/declarative/util/qdeclarativelistmodel_p_p.h2
-rw-r--r--src/declarative/util/qdeclarativelistmodelworkeragent.cpp16
-rw-r--r--src/declarative/util/qdeclarativelistmodelworkeragent_p.h8
-rw-r--r--src/declarative/util/qdeclarativenullablevalue_p_p.h2
-rw-r--r--src/declarative/util/qdeclarativeopenmetaobject.cpp2
-rw-r--r--src/declarative/util/qdeclarativepackage.cpp18
-rw-r--r--src/declarative/util/qdeclarativepixmapcache.cpp64
-rw-r--r--src/declarative/util/qdeclarativepropertychanges.cpp18
-rw-r--r--src/declarative/util/qdeclarativepropertychanges_p.h2
-rw-r--r--src/declarative/util/qdeclarativestate.cpp6
-rw-r--r--src/declarative/util/qdeclarativestate_p_p.h2
-rw-r--r--src/declarative/util/qdeclarativestategroup.cpp10
-rw-r--r--src/declarative/util/qdeclarativestateoperations.cpp4
-rw-r--r--src/declarative/util/qdeclarativestateoperations_p.h2
-rw-r--r--src/declarative/util/qdeclarativesystempalette.cpp2
-rw-r--r--src/declarative/util/qdeclarativetimeline.cpp24
-rw-r--r--src/declarative/util/qdeclarativetransitionmanager.cpp12
-rw-r--r--src/declarative/util/qdeclarativetransitionmanager_p_p.h2
-rw-r--r--src/declarative/util/qdeclarativexmllistmodel.cpp28
-rw-r--r--src/declarative/util/qlistmodelinterface_p.h2
128 files changed, 1174 insertions, 1174 deletions
diff --git a/src/declarative/QmlChanges.txt b/src/declarative/QmlChanges.txt
index 6e073305..cdb81360 100644
--- a/src/declarative/QmlChanges.txt
+++ b/src/declarative/QmlChanges.txt
@@ -18,7 +18,7 @@ The changes below are pre Qt 4.7.0 beta 2
QDeclarativeView
- initialSize() function added
-TextInput and TextEdit:
+TextInput and TextEdit:
- openSoftwareInputPanel() and closeSoftwareInputPanel() functions added
Flickable:
- overShoot is replaced by boundsBehavior enumeration
diff --git a/src/declarative/debugger/qdeclarativedebugclient.cpp b/src/declarative/debugger/qdeclarativedebugclient.cpp
index 9a5bdea2..21c138dd 100644
--- a/src/declarative/debugger/qdeclarativedebugclient.cpp
+++ b/src/declarative/debugger/qdeclarativedebugclient.cpp
@@ -217,7 +217,7 @@ QDeclarativeDebugClientPrivate::QDeclarativeDebugClientPrivate()
{
}
-QDeclarativeDebugClient::QDeclarativeDebugClient(const QString &name,
+QDeclarativeDebugClient::QDeclarativeDebugClient(const QString &name,
QDeclarativeDebugConnection *parent)
: QObject(*(new QDeclarativeDebugClientPrivate), parent)
{
diff --git a/src/declarative/debugger/qdeclarativedebugservice.cpp b/src/declarative/debugger/qdeclarativedebugservice.cpp
index bf400f72..80dd2332 100644
--- a/src/declarative/debugger/qdeclarativedebugservice.cpp
+++ b/src/declarative/debugger/qdeclarativedebugservice.cpp
@@ -94,13 +94,13 @@ QDeclarativeDebugService::Status QDeclarativeDebugService::status() const
namespace {
- struct ObjectReference
+ struct ObjectReference
{
QPointer<QObject> object;
int id;
};
- struct ObjectReferenceHash
+ struct ObjectReferenceHash
{
ObjectReferenceHash() : nextId(0) {}
@@ -124,7 +124,7 @@ int QDeclarativeDebugService::idForObject(QObject *object)
return -1;
ObjectReferenceHash *hash = objectReferenceHash();
- QHash<QObject *, ObjectReference>::Iterator iter =
+ QHash<QObject *, ObjectReference>::Iterator iter =
hash->objects.find(object);
if (iter == hash->objects.end()) {
@@ -142,7 +142,7 @@ int QDeclarativeDebugService::idForObject(QObject *object)
hash->ids.insert(id, object);
iter->object = object;
iter->id = id;
- }
+ }
return iter->id;
}
@@ -160,7 +160,7 @@ QObject *QDeclarativeDebugService::objectForId(int id)
return 0;
- QHash<QObject *, ObjectReference>::Iterator objIter =
+ QHash<QObject *, ObjectReference>::Iterator objIter =
hash->objects.find(*iter);
Q_ASSERT(objIter != hash->objects.end());
@@ -193,7 +193,7 @@ QString QDeclarativeDebugService::objectToString(QObject *obj)
if(objectName.isEmpty())
objectName = QLatin1String("<unnamed>");
- QString rv = QString::fromUtf8(obj->metaObject()->className()) +
+ QString rv = QString::fromUtf8(obj->metaObject()->className()) +
QLatin1String(": ") + objectName;
return rv;
diff --git a/src/declarative/debugger/qdeclarativedebugtrace.cpp b/src/declarative/debugger/qdeclarativedebugtrace.cpp
index 6ca660b5..9bba4a4d 100644
--- a/src/declarative/debugger/qdeclarativedebugtrace.cpp
+++ b/src/declarative/debugger/qdeclarativedebugtrace.cpp
@@ -137,19 +137,19 @@ QDeclarativeDebugTrace::QDeclarativeDebugTrace()
void QDeclarativeDebugTrace::addEvent(EventType t)
{
- if (QDeclarativeDebugService::isDebuggingEnabled())
+ if (QDeclarativeDebugService::isDebuggingEnabled())
traceInstance()->addEventImpl(t);
}
void QDeclarativeDebugTrace::startRange(RangeType t)
{
- if (QDeclarativeDebugService::isDebuggingEnabled())
+ if (QDeclarativeDebugService::isDebuggingEnabled())
traceInstance()->startRangeImpl(t);
}
void QDeclarativeDebugTrace::rangeData(RangeType t, const QString &data)
{
- if (QDeclarativeDebugService::isDebuggingEnabled())
+ if (QDeclarativeDebugService::isDebuggingEnabled())
traceInstance()->rangeDataImpl(t, data);
}
@@ -173,7 +173,7 @@ void QDeclarativeDebugTrace::rangeLocation(RangeType t, const QUrl &fileName, in
void QDeclarativeDebugTrace::endRange(RangeType t)
{
- if (QDeclarativeDebugService::isDebuggingEnabled())
+ if (QDeclarativeDebugService::isDebuggingEnabled())
traceInstance()->endRangeImpl(t);
}
diff --git a/src/declarative/debugger/qdeclarativeenginedebug.cpp b/src/declarative/debugger/qdeclarativeenginedebug.cpp
index 083fca1a..b6510945 100644
--- a/src/declarative/debugger/qdeclarativeenginedebug.cpp
+++ b/src/declarative/debugger/qdeclarativeenginedebug.cpp
@@ -172,7 +172,7 @@ void QDeclarativeEngineDebugPrivate::remove(QDeclarativeEngineDebug *c, QDeclara
}
}
-void QDeclarativeEngineDebugPrivate::remove(QDeclarativeEngineDebug *c,
+void QDeclarativeEngineDebugPrivate::remove(QDeclarativeEngineDebug *c,
QDeclarativeDebugRootContextQuery *q)
{
if (c && q) {
@@ -336,7 +336,7 @@ void QDeclarativeEngineDebugPrivate::message(const QByteArray &data)
return;
rootContextQuery.remove(queryId);
- if (!ds.atEnd())
+ if (!ds.atEnd())
decode(ds, query->m_context);
query->m_client = 0;
@@ -516,7 +516,7 @@ void QDeclarativeEngineDebug::removeWatch(QDeclarativeDebugWatch *watch)
watch->m_client = 0;
watch->setState(QDeclarativeDebugWatch::Inactive);
-
+
d->watched.remove(watch->queryId());
if (d->client && d->client->status() == QDeclarativeDebugClient::Enabled) {
@@ -584,7 +584,7 @@ QDeclarativeDebugObjectQuery *QDeclarativeEngineDebug::queryObject(const QDeclar
QByteArray message;
QDataStream ds(&message, QIODevice::WriteOnly);
- ds << QByteArray("FETCH_OBJECT") << queryId << object.debugId()
+ ds << QByteArray("FETCH_OBJECT") << queryId << object.debugId()
<< false << true;
d->client->sendMessage(message);
} else {
@@ -607,7 +607,7 @@ QDeclarativeDebugObjectQuery *QDeclarativeEngineDebug::queryObjectRecursive(cons
QByteArray message;
QDataStream ds(&message, QIODevice::WriteOnly);
- ds << QByteArray("FETCH_OBJECT") << queryId << object.debugId()
+ ds << QByteArray("FETCH_OBJECT") << queryId << object.debugId()
<< true << true;
d->client->sendMessage(message);
} else {
@@ -777,7 +777,7 @@ QDeclarativeDebugEnginesQuery::QDeclarativeDebugEnginesQuery(QObject *parent)
QDeclarativeDebugEnginesQuery::~QDeclarativeDebugEnginesQuery()
{
- if (m_client && m_queryId != -1)
+ if (m_client && m_queryId != -1)
QDeclarativeEngineDebugPrivate::remove(m_client, this);
}
@@ -793,7 +793,7 @@ QDeclarativeDebugRootContextQuery::QDeclarativeDebugRootContextQuery(QObject *pa
QDeclarativeDebugRootContextQuery::~QDeclarativeDebugRootContextQuery()
{
- if (m_client && m_queryId != -1)
+ if (m_client && m_queryId != -1)
QDeclarativeEngineDebugPrivate::remove(m_client, this);
}
@@ -809,7 +809,7 @@ QDeclarativeDebugObjectQuery::QDeclarativeDebugObjectQuery(QObject *parent)
QDeclarativeDebugObjectQuery::~QDeclarativeDebugObjectQuery()
{
- if (m_client && m_queryId != -1)
+ if (m_client && m_queryId != -1)
QDeclarativeEngineDebugPrivate::remove(m_client, this);
}
@@ -825,7 +825,7 @@ QDeclarativeDebugExpressionQuery::QDeclarativeDebugExpressionQuery(QObject *pare
QDeclarativeDebugExpressionQuery::~QDeclarativeDebugExpressionQuery()
{
- if (m_client && m_queryId != -1)
+ if (m_client && m_queryId != -1)
QDeclarativeEngineDebugPrivate::remove(m_client, this);
}
@@ -974,7 +974,7 @@ QDeclarativeDebugContextReference::QDeclarativeDebugContextReference(const QDecl
QDeclarativeDebugContextReference &QDeclarativeDebugContextReference::operator=(const QDeclarativeDebugContextReference &o)
{
- m_debugId = o.m_debugId; m_name = o.m_name; m_objects = o.m_objects;
+ m_debugId = o.m_debugId; m_name = o.m_name; m_objects = o.m_objects;
m_contexts = o.m_contexts;
return *this;
}
diff --git a/src/declarative/debugger/qdeclarativeenginedebug_p.h b/src/declarative/debugger/qdeclarativeenginedebug_p.h
index c16dddf5..ac7e63d3 100644
--- a/src/declarative/debugger/qdeclarativeenginedebug_p.h
+++ b/src/declarative/debugger/qdeclarativeenginedebug_p.h
@@ -91,11 +91,11 @@ public:
QDeclarativeDebugEnginesQuery *queryAvailableEngines(QObject *parent = 0);
QDeclarativeDebugRootContextQuery *queryRootContexts(const QDeclarativeDebugEngineReference &,
QObject *parent = 0);
- QDeclarativeDebugObjectQuery *queryObject(const QDeclarativeDebugObjectReference &,
+ QDeclarativeDebugObjectQuery *queryObject(const QDeclarativeDebugObjectReference &,
QObject *parent = 0);
- QDeclarativeDebugObjectQuery *queryObjectRecursive(const QDeclarativeDebugObjectReference &,
+ QDeclarativeDebugObjectQuery *queryObjectRecursive(const QDeclarativeDebugObjectReference &,
QObject *parent = 0);
- QDeclarativeDebugExpressionQuery *queryExpressionResult(int objectDebugId,
+ QDeclarativeDebugExpressionQuery *queryExpressionResult(int objectDebugId,
const QString &expr,
QObject *parent = 0);
bool setBindingForObject(int objectDebugId, const QString &propertyName,
diff --git a/src/declarative/debugger/qdeclarativeenginedebugservice.cpp b/src/declarative/debugger/qdeclarativeenginedebugservice.cpp
index 5ee064a2..f4b66dc3 100644
--- a/src/declarative/debugger/qdeclarativeenginedebugservice.cpp
+++ b/src/declarative/debugger/qdeclarativeenginedebugservice.cpp
@@ -74,7 +74,7 @@ QDeclarativeEngineDebugService::QDeclarativeEngineDebugService(QObject *parent)
this, SLOT(propertyChanged(int,int,QMetaProperty,QVariant)));
}
-QDataStream &operator<<(QDataStream &ds,
+QDataStream &operator<<(QDataStream &ds,
const QDeclarativeEngineDebugService::QDeclarativeObjectData &data)
{
ds << data.url << data.lineNumber << data.columnNumber << data.idString
@@ -83,7 +83,7 @@ QDataStream &operator<<(QDataStream &ds,
return ds;
}
-QDataStream &operator>>(QDataStream &ds,
+QDataStream &operator>>(QDataStream &ds,
QDeclarativeEngineDebugService::QDeclarativeObjectData &data)
{
ds >> data.url >> data.lineNumber >> data.columnNumber >> data.idString
@@ -92,7 +92,7 @@ QDataStream &operator>>(QDataStream &ds,
return ds;
}
-QDataStream &operator<<(QDataStream &ds,
+QDataStream &operator<<(QDataStream &ds,
const QDeclarativeEngineDebugService::QDeclarativeObjectProperty &data)
{
ds << (int)data.type << data.name << data.value << data.valueTypeName
@@ -100,7 +100,7 @@ QDataStream &operator<<(QDataStream &ds,
return ds;
}
-QDataStream &operator>>(QDataStream &ds,
+QDataStream &operator>>(QDataStream &ds,
QDeclarativeEngineDebugService::QDeclarativeObjectProperty &data)
{
int type;
@@ -144,7 +144,7 @@ QDeclarativeEngineDebugService::propertyData(QObject *obj, int propIdx)
rv.valueTypeName = QString::fromUtf8(prop.typeName());
rv.name = QString::fromUtf8(prop.name());
rv.hasNotifySignal = prop.hasNotifySignal();
- QDeclarativeAbstractBinding *binding =
+ QDeclarativeAbstractBinding *binding =
QDeclarativePropertyPrivate::binding(QDeclarativeProperty(obj, rv.name));
if (binding)
rv.binding = binding->expression();
@@ -213,7 +213,7 @@ void QDeclarativeEngineDebugService::buildObjectDump(QDataStream &message,
message << objectData(object);
QObjectList children = object->children();
-
+
int childrenCount = children.count();
for (int ii = 0; ii < children.count(); ++ii) {
if (qobject_cast<QDeclarativeContext*>(children[ii]) || QDeclarativeBoundSignal::cast(children[ii]))
@@ -302,7 +302,7 @@ void QDeclarativeEngineDebugService::buildObjectList(QDataStream &message, QDecl
QString ctxtName = ctxt->objectName();
int ctxtId = QDeclarativeDebugService::idForObject(ctxt);
- message << ctxtName << ctxtId;
+ message << ctxtName << ctxtId;
int count = 0;
@@ -433,7 +433,7 @@ void QDeclarativeEngineDebugService::messageReceived(const QByteArray &message)
int engineId = -1;
ds >> engineId;
- QDeclarativeEngine *engine =
+ QDeclarativeEngine *engine =
qobject_cast<QDeclarativeEngine *>(QDeclarativeDebugService::objectForId(engineId));
rs << QByteArray("LIST_OBJECTS_R") << queryId;
@@ -678,7 +678,7 @@ void QDeclarativeEngineDebugService::setMethodBody(int objectId, const QString &
return;
QDeclarativePropertyCache::Data dummy;
- QDeclarativePropertyCache::Data *prop =
+ QDeclarativePropertyCache::Data *prop =
QDeclarativePropertyCache::property(context->engine(), object, method, dummy);
if (!prop || !(prop->flags & QDeclarativePropertyCache::Data::IsVMEFunction))
@@ -693,12 +693,12 @@ void QDeclarativeEngineDebugService::setMethodBody(int objectId, const QString &
paramStr.append(QString::fromUtf8(paramNames.at(ii)));
}
- QString jsfunction = QLatin1String("(function ") + method + QLatin1String("(") + paramStr +
+ QString jsfunction = QLatin1String("(function ") + method + QLatin1String("(") + paramStr +
QLatin1String(") {");
jsfunction += body;
jsfunction += QLatin1String("\n})");
- QDeclarativeVMEMetaObject *vmeMetaObject =
+ QDeclarativeVMEMetaObject *vmeMetaObject =
static_cast<QDeclarativeVMEMetaObject*>(QObjectPrivate::get(object)->metaObject);
Q_ASSERT(vmeMetaObject); // the fact we found the property above should guarentee this
diff --git a/src/declarative/debugger/qpacketprotocol.cpp b/src/declarative/debugger/qpacketprotocol.cpp
index 369f0610..8bb2a129 100644
--- a/src/declarative/debugger/qpacketprotocol.cpp
+++ b/src/declarative/debugger/qpacketprotocol.cpp
@@ -55,7 +55,7 @@ QT_BEGIN_NAMESPACE
\brief The QPacketProtocol class encapsulates communicating discrete packets
across fragmented IO channels, such as TCP sockets.
- QPacketProtocol makes it simple to send arbitrary sized data "packets" across
+ QPacketProtocol makes it simple to send arbitrary sized data "packets" across
fragmented transports such as TCP and UDP.
As transmission boundaries are not respected, sending packets over protocols
@@ -243,8 +243,8 @@ QPacketProtocol::~QPacketProtocol()
/*!
Returns the maximum packet size allowed. By default this is
- 2,147,483,647 bytes.
-
+ 2,147,483,647 bytes.
+
If a packet claiming to be larger than the maximum packet size is received,
the QPacketProtocol::invalidPacket() signal is emitted.
@@ -274,7 +274,7 @@ qint32 QPacketProtocol::setMaximumPacketSize(qint32 max)
protocol.send() << "Hello world" << 123;
\endcode
- will send a packet containing "Hello world" and 123. To construct more
+ will send a packet containing "Hello world" and 123. To construct more
complex packets, explicitly construct a QPacket instance.
*/
QPacketAutoSend QPacketProtocol::send()
@@ -441,8 +441,8 @@ QIODevice * QPacketProtocol::device()
\endcode
Only packets returned from QPacketProtocol::read() may be read from. QPacket
- instances constructed by directly by applications are for transmission only
- and are considered "write only". Attempting to read data from them will
+ instances constructed by directly by applications are for transmission only
+ and are considered "write only". Attempting to read data from them will
result in undefined behavior.
\ingroup io
diff --git a/src/declarative/graphicsitems/qdeclarativeevents.cpp b/src/declarative/graphicsitems/qdeclarativeevents.cpp
index d4542e41..b9ccb676 100644
--- a/src/declarative/graphicsitems/qdeclarativeevents.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeevents.cpp
@@ -47,7 +47,7 @@ QT_BEGIN_NAMESPACE
\instantiates QDeclarativeKeyEvent
\since 4.7
\ingroup qml-event-elements
-
+
\brief The KeyEvent object provides information about a key event.
For example, the following changes the Item's state property when the Enter
diff --git a/src/declarative/graphicsitems/qdeclarativefocuspanel.cpp b/src/declarative/graphicsitems/qdeclarativefocuspanel.cpp
index 8787b508..dd40fec0 100644
--- a/src/declarative/graphicsitems/qdeclarativefocuspanel.cpp
+++ b/src/declarative/graphicsitems/qdeclarativefocuspanel.cpp
@@ -58,7 +58,7 @@ QT_BEGIN_NAMESPACE
\inherits Item
Focus panels assist in keyboard focus handling when building QML
- applications. All the details are covered in the
+ applications. All the details are covered in the
\l {qmlfocus}{keyboard focus documentation}.
*/
diff --git a/src/declarative/graphicsitems/qdeclarativegridview.cpp b/src/declarative/graphicsitems/qdeclarativegridview.cpp
index 1285c877..aca5828b 100644
--- a/src/declarative/graphicsitems/qdeclarativegridview.cpp
+++ b/src/declarative/graphicsitems/qdeclarativegridview.cpp
@@ -1283,7 +1283,7 @@ void QDeclarativeGridViewPrivate::flick(AxisData &data, qreal minExtent, qreal m
QAbstractListModel.
A GridView has a \l model, which defines the data to be displayed, and
- a \l delegate, which defines how the data should be displayed. Items in a
+ a \l delegate, which defines how the data should be displayed. Items in a
GridView are laid out horizontally or vertically. Grid views are inherently flickable
as GridView inherits from \l Flickable.
@@ -1317,7 +1317,7 @@ void QDeclarativeGridViewPrivate::flick(AxisData &data, qreal minExtent, qreal m
The view will create a new delegate for each item in the model. Note that the delegate
is able to access the model's \c name and \c portrait data directly.
- An improved grid view is shown below. The delegate is visually improved and is moved
+ An improved grid view is shown below. The delegate is visually improved and is moved
into a separate \c contactDelegate component.
\clearfloat
@@ -1558,10 +1558,10 @@ void QDeclarativeGridView::setDelegate(QDeclarativeComponent *delegate)
\c currentItem holds the current item. Setting the currentIndex to -1
will clear the highlight and set currentItem to null.
- If highlightFollowsCurrentItem is \c true, setting either of these
- properties will smoothly scroll the GridView so that the current
+ If highlightFollowsCurrentItem is \c true, setting either of these
+ properties will smoothly scroll the GridView so that the current
item becomes visible.
-
+
Note that the position of the current item
may only be approximate until it becomes visible in the view.
*/
@@ -1661,8 +1661,8 @@ void QDeclarativeGridView::setHighlight(QDeclarativeComponent *highlight)
If this property is true (the default value), the highlight is moved smoothly
to follow the current item. Otherwise, the
highlight is not moved by the view, and any movement must be implemented
- by the highlight.
-
+ by the highlight.
+
Here is a highlight with its motion defined by a \l {SpringAnimation} item:
\snippet doc/src/snippets/declarative/gridview/gridview.qml highlightFollowsCurrentItem
@@ -1725,12 +1725,12 @@ void QDeclarativeGridView::setHighlightMoveDuration(int duration)
These properties define the preferred range of the highlight (for the current item)
within the view. The \c preferredHighlightBegin value must be less than the
- \c preferredHighlightEnd value.
+ \c preferredHighlightEnd value.
These properties affect the position of the current item when the view is scrolled.
For example, if the currently selected item should stay in the middle of the
- view when it is scrolled, set the \c preferredHighlightBegin and
- \c preferredHighlightEnd values to the top and bottom coordinates of where the middle
+ view when it is scrolled, set the \c preferredHighlightBegin and
+ \c preferredHighlightEnd values to the top and bottom coordinates of where the middle
item would be. If the \c currentItem is changed programmatically, the view will
automatically scroll so that the current item is in the middle of the view.
Furthermore, the behavior of the current item index will occur whether or not a
diff --git a/src/declarative/graphicsitems/qdeclarativeimage.cpp b/src/declarative/graphicsitems/qdeclarativeimage.cpp
index 4e372abf..f3d0b226 100644
--- a/src/declarative/graphicsitems/qdeclarativeimage.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeimage.cpp
@@ -159,7 +159,7 @@ void QDeclarativeImagePrivate::setPixmap(const QPixmap &pixmap)
\endlist
\table
-
+
\row
\li \image declarative-qtlogo-stretch.png
\li Stretch (default)
@@ -261,9 +261,9 @@ void QDeclarativeImage::setFillMode(FillMode mode)
\qmlproperty real Image::paintedHeight
These properties hold the size of the image that is actually painted.
- In most cases it is the same as \c width and \c height, but when using a
- \c fillMode \c PreserveAspectFit or \c fillMode \c PreserveAspectCrop
- \c paintedWidth or \c paintedHeight can be smaller or larger than
+ In most cases it is the same as \c width and \c height, but when using a
+ \c fillMode \c PreserveAspectFit or \c fillMode \c PreserveAspectCrop
+ \c paintedWidth or \c paintedHeight can be smaller or larger than
\c width and \c height of the Image element.
*/
qreal QDeclarativeImage::paintedWidth() const
@@ -346,7 +346,7 @@ qreal QDeclarativeImage::paintedHeight() const
the painting of the image, this property sets the actual number of pixels
stored for the loaded image so that large images do not use more
memory than necessary. For example, this ensures the image in memory is no
- larger than 1024x1024 pixels, regardless of the Image's \l {Item::}{width} and
+ larger than 1024x1024 pixels, regardless of the Image's \l {Item::}{width} and
\l {Item::}{height} values:
\code
@@ -379,7 +379,7 @@ qreal QDeclarativeImage::paintedHeight() const
Since QtQuick 1.1 the sourceSize can be cleared to the natural size of the image
by setting sourceSize to \c undefined.
-
+
\note \e {Changing this property dynamically causes the image source to be reloaded,
potentially even from the network, if it is not in the disk cache.}
*/
diff --git a/src/declarative/graphicsitems/qdeclarativeitem.cpp b/src/declarative/graphicsitems/qdeclarativeitem.cpp
index 0589ffdf..32e6e0fa 100644
--- a/src/declarative/graphicsitems/qdeclarativeitem.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeitem.cpp
@@ -2870,7 +2870,7 @@ QDeclarativeListProperty<QDeclarativeTransition> QDeclarativeItemPrivate::transi
If clipping is enabled, an item will clip its own painting, as well
as the painting of its children, to its bounding rectangle. If you set
- clipping during an item's paint operation, remember to re-set it to
+ clipping during an item's paint operation, remember to re-set it to
prevent clipping the rest of your scene.
Non-rectangular clipping regions are not supported for performance reasons.
diff --git a/src/declarative/graphicsitems/qdeclarativelistview.cpp b/src/declarative/graphicsitems/qdeclarativelistview.cpp
index 08e76363..54894239 100644
--- a/src/declarative/graphicsitems/qdeclarativelistview.cpp
+++ b/src/declarative/graphicsitems/qdeclarativelistview.cpp
@@ -1597,7 +1597,7 @@ void QDeclarativeListViewPrivate::flick(AxisData &data, qreal minExtent, qreal m
for its delegate. The view will create a new \l Text component for each item in the model. Notice
the delegate is able to access the model's \c name and \c number data directly.
- An improved list view is shown below. The delegate is visually improved and is moved
+ An improved list view is shown below. The delegate is visually improved and is moved
into a separate \c contactDelegate component.
\snippet doc/src/snippets/declarative/listview/listview.qml classdocs advanced
@@ -1871,10 +1871,10 @@ void QDeclarativeListView::setDelegate(QDeclarativeComponent *delegate)
\c currentItem holds the current item. Setting the currentIndex to -1
will clear the highlight and set currentItem to null.
- If highlightFollowsCurrentItem is \c true, setting either of these
- properties will smoothly scroll the ListView so that the current
+ If highlightFollowsCurrentItem is \c true, setting either of these
+ properties will smoothly scroll the ListView so that the current
item becomes visible.
-
+
Note that the position of the current item
may only be approximate until it becomes visible in the view.
*/
@@ -1977,8 +1977,8 @@ void QDeclarativeListView::setHighlight(QDeclarativeComponent *highlight)
If this property is true (the default value), the highlight is moved smoothly
to follow the current item. Otherwise, the
highlight is not moved by the view, and any movement must be implemented
- by the highlight.
-
+ by the highlight.
+
Here is a highlight with its motion defined by a \l {SpringAnimation} item:
\snippet doc/src/snippets/declarative/listview/listview.qml highlightFollowsCurrentItem
@@ -2020,12 +2020,12 @@ void QDeclarativeListView::setHighlightFollowsCurrentItem(bool autoHighlight)
These properties define the preferred range of the highlight (for the current item)
within the view. The \c preferredHighlightBegin value must be less than the
- \c preferredHighlightEnd value.
+ \c preferredHighlightEnd value.
These properties affect the position of the current item when the list is scrolled.
For example, if the currently selected item should stay in the middle of the
- list when the view is scrolled, set the \c preferredHighlightBegin and
- \c preferredHighlightEnd values to the top and bottom coordinates of where the middle
+ list when the view is scrolled, set the \c preferredHighlightBegin and
+ \c preferredHighlightEnd values to the top and bottom coordinates of where the middle
item would be. If the \c currentItem is changed programmatically, the list will
automatically scroll so that the current item is in the middle of the view.
Furthermore, the behavior of the current item index will occur whether or not a
@@ -2228,7 +2228,7 @@ Qt::LayoutDirection QDeclarativeListView::effectiveLayoutDirection() const
/*!
\qmlproperty bool ListView::keyNavigationWraps
- This property holds whether the list wraps key navigation.
+ This property holds whether the list wraps key navigation.
If this is true, key navigation that would move the current item selection
past the end of the list instead wraps around and moves the selection to
@@ -2299,7 +2299,7 @@ void QDeclarativeListView::setCacheBuffer(int b)
The \l section attached property enables a ListView to be visually
separated into different parts. These properties determine how sections
are created.
-
+
\c section.property holds the name of the property that is the basis
of each section.
@@ -2310,7 +2310,7 @@ void QDeclarativeListView::setCacheBuffer(int b)
\li ViewSection.FullString (default) - sections are created based on the
\c section.property value.
\li ViewSection.FirstCharacter - sections are created based on the first
- character of the \c section.property value (for example, 'A', 'B', 'C'
+ character of the \c section.property value (for example, 'A', 'B', 'C'
sections, etc. for an address book)
\endlist
@@ -2320,13 +2320,13 @@ void QDeclarativeListView::setCacheBuffer(int b)
\c ListView.previousSection and \c ListView.nextSection. These may be
used to place a section header for related items.
- For example, here is a ListView that displays a list of animals, separated
- into sections. Each item in the ListView is placed in a different section
+ For example, here is a ListView that displays a list of animals, separated
+ into sections. Each item in the ListView is placed in a different section
depending on the "size" property of the model item. The \c sectionHeading
delegate component provides the light blue bar that marks the beginning of
each section.
-
+
\snippet examples/declarative/modelviews/listview/sections.qml 0
\image qml-listview-sections-example.png
diff --git a/src/declarative/graphicsitems/qdeclarativeloader.cpp b/src/declarative/graphicsitems/qdeclarativeloader.cpp
index d934f6a3..f0d26170 100644
--- a/src/declarative/graphicsitems/qdeclarativeloader.cpp
+++ b/src/declarative/graphicsitems/qdeclarativeloader.cpp
@@ -127,13 +127,13 @@ void QDeclarativeLoaderPrivate::initResize()
subtree from a URL or Component.
Loader is used to dynamically load visual QML components. It can load a
- QML file (using the \l source property) or a \l Component object (using
- the \l sourceComponent property). It is useful for delaying the creation
- of a component until it is required: for example, when a component should
- be created on demand, or when a component should not be created
+ QML file (using the \l source property) or a \l Component object (using
+ the \l sourceComponent property). It is useful for delaying the creation
+ of a component until it is required: for example, when a component should
+ be created on demand, or when a component should not be created
unnecessarily for performance reasons.
- Here is a Loader that loads "Page1.qml" as a component when the
+ Here is a Loader that loads "Page1.qml" as a component when the
\l MouseArea is clicked:
\snippet doc/src/snippets/declarative/loader/simple.qml 0
@@ -178,13 +178,13 @@ void QDeclarativeLoaderPrivate::initResize()
\section2 Receiving signals from loaded items
- Any signals emitted from the loaded item can be received using the
+ Any signals emitted from the loaded item can be received using the
\l Connections element. For example, the following \c application.qml
loads \c MyItem.qml, and is able to receive the \c message signal from
the loaded item through a \l Connections object:
\table
- \row
+ \row
\li application.qml
\li MyItem.qml
\row
@@ -199,19 +199,19 @@ void QDeclarativeLoaderPrivate::initResize()
\section2 Focus and key events
- Loader is a focus scope. Its \l {Item::}{focus} property must be set to
- \c true for any of its children to get the \e {active focus}. (See
- \l{qmlfocus#Acquiring Focus and Focus Scopes}{the focus documentation page}
+ Loader is a focus scope. Its \l {Item::}{focus} property must be set to
+ \c true for any of its children to get the \e {active focus}. (See
+ \l{qmlfocus#Acquiring Focus and Focus Scopes}{the focus documentation page}
for more details.) Any key events received in the loaded item should likely
also be \l {KeyEvent::}{accepted} so they are not propagated to the Loader.
For example, the following \c application.qml loads \c KeyReader.qml when
- the \l MouseArea is clicked. Notice the \l {Item::}{focus} property is
- set to \c true for the Loader as well as the \l Item in the dynamically
+ the \l MouseArea is clicked. Notice the \l {Item::}{focus} property is
+ set to \c true for the Loader as well as the \l Item in the dynamically
loaded object:
\table
- \row
+ \row
\li application.qml
\li KeyReader.qml
\row
@@ -219,7 +219,7 @@ void QDeclarativeLoaderPrivate::initResize()
\li \snippet doc/src/snippets/declarative/loader/KeyReader.qml 0
\endtable
- Once \c KeyReader.qml is loaded, it accepts key events and sets
+ Once \c KeyReader.qml is loaded, it accepts key events and sets
\c event.accepted to \c true so that the event is not propagated to the
parent \l Rectangle.
diff --git a/src/declarative/graphicsitems/qdeclarativemousearea.cpp b/src/declarative/graphicsitems/qdeclarativemousearea.cpp
index 4752ec32..4534090f 100644
--- a/src/declarative/graphicsitems/qdeclarativemousearea.cpp
+++ b/src/declarative/graphicsitems/qdeclarativemousearea.cpp
@@ -965,10 +965,10 @@ QDeclarativeDrag *QDeclarativeMouseArea::drag()
\snippet doc/src/snippets/declarative/mousearea/mousearea.qml drag
- \note Items cannot be dragged if they are anchored for the requested
+ \note Items cannot be dragged if they are anchored for the requested
\c drag.axis. For example, if \c anchors.left or \c anchors.right was set
for \c rect in the above example, it cannot be dragged along the X-axis.
- This can be avoided by settng the anchor value to \c undefined in
+ This can be avoided by settng the anchor value to \c undefined in
an \l onPressed handler.
If \c drag.filterChildren is set to true, a drag can override descendant MouseAreas. This
diff --git a/src/declarative/graphicsitems/qdeclarativepathview.cpp b/src/declarative/graphicsitems/qdeclarativepathview.cpp
index 9dec9e25..91becae7 100644
--- a/src/declarative/graphicsitems/qdeclarativepathview.cpp
+++ b/src/declarative/graphicsitems/qdeclarativepathview.cpp
@@ -360,7 +360,7 @@ void QDeclarativePathViewPrivate::regenerate()
QAbstractListModel.
The view has a \l model, which defines the data to be displayed, and
- a \l delegate, which defines how the data should be displayed.
+ a \l delegate, which defines how the data should be displayed.
The \l delegate is instantiated for each item on the \l path.
The items may be flicked to move them along the path.
diff --git a/src/declarative/graphicsitems/qdeclarativepositioners.cpp b/src/declarative/graphicsitems/qdeclarativepositioners.cpp
index bca94ebd..8854fa02 100644
--- a/src/declarative/graphicsitems/qdeclarativepositioners.cpp
+++ b/src/declarative/graphicsitems/qdeclarativepositioners.cpp
@@ -497,7 +497,7 @@ void QDeclarativeColumn::reportConflictingAnchors()
\inherits Item
The Row item positions its child items so that they are horizontally
- aligned and not overlapping.
+ aligned and not overlapping.
Use \l spacing to set the spacing between items in a Row, and use the
\l add and \l move properties to set the transitions that should be applied
@@ -712,7 +712,7 @@ void QDeclarativeRow::reportConflictingAnchors()
\inherits Item
The Grid item positions its child items so that they are
- aligned in a grid and are not overlapping.
+ aligned in a grid and are not overlapping.
The grid positioner calculates a grid of rectangular cells of sufficient
size to hold all items, placing the items in the cells, from left to right
diff --git a/src/declarative/graphicsitems/qdeclarativetext.cpp b/src/declarative/graphicsitems/qdeclarativetext.cpp
index 8d01e773..64d03c36 100644
--- a/src/declarative/graphicsitems/qdeclarativetext.cpp
+++ b/src/declarative/graphicsitems/qdeclarativetext.cpp
@@ -100,14 +100,14 @@ QDeclarativeTextPrivate::QDeclarativeTextPrivate()
QGraphicsItemPrivate::flags = QGraphicsItemPrivate::flags & ~QGraphicsItem::ItemHasNoContents;
}
-QTextDocumentWithImageResources::QTextDocumentWithImageResources(QDeclarativeText *parent)
+QTextDocumentWithImageResources::QTextDocumentWithImageResources(QDeclarativeText *parent)
: QTextDocument(parent), outstanding(0)
{
}
QTextDocumentWithImageResources::~QTextDocumentWithImageResources()
{
- if (!m_resources.isEmpty())
+ if (!m_resources.isEmpty())
qDeleteAll(m_resources);
}
@@ -489,7 +489,7 @@ QPixmap QDeclarativeTextPrivate::textLayoutImage(bool drawStyle)
}
/*!
- Paints the QDeclarativeTextPrivate::layout QTextLayout into \a painter at \a pos. If
+ Paints the QDeclarativeTextPrivate::layout QTextLayout into \a painter at \a pos. If
\a drawStyle is true, the style color overrides all colors in the document.
*/
void QDeclarativeTextPrivate::drawTextLayout(QPainter *painter, const QPointF &pos, bool drawStyle)
@@ -544,7 +544,7 @@ QPixmap QDeclarativeTextPrivate::textDocumentImage(bool drawStyle)
/*!
Mark the image cache as dirty.
*/
-void QDeclarativeTextPrivate::invalidateImageCache()
+void QDeclarativeTextPrivate::invalidateImageCache()
{
Q_Q(QDeclarativeText);
@@ -601,13 +601,13 @@ void QDeclarativeTextPrivate::checkImageCache()
break;
}
- }
+ }
imageCacheDirty = false;
}
-/*!
- Ensures the QDeclarativeTextPrivate::doc variable is set to a valid text document
+/*!
+ Ensures the QDeclarativeTextPrivate::doc variable is set to a valid text document
*/
void QDeclarativeTextPrivate::ensureDoc()
{
@@ -743,15 +743,15 @@ QDeclarativeText::~QDeclarativeText()
\qmlsignal Text::onLinkActivated(string link)
This handler is called when the user clicks on a link embedded in the text.
- The link must be in rich text or HTML format and the
- \a link string provides access to the particular link.
+ The link must be in rich text or HTML format and the
+ \a link string provides access to the particular link.
\snippet doc/src/snippets/declarative/text/onLinkActivated.qml 0
- The example code will display the text
+ The example code will display the text
"The main website is at \l{http://qt.nokia.com}{Nokia Qt DF}."
- Clicking on the highlighted link will output
+ Clicking on the highlighted link will output
\tt{http://qt.nokia.com link activated} to the console.
*/
@@ -1053,7 +1053,7 @@ void QDeclarativeText::setStyleColor(const QColor &color)
Note that for a single line of text, the size of the text is the area of the text. In this common case,
all alignments are equivalent. If you want the text to be, say, centered in its parent, then you will
- need to either modify the Item::anchors, or set horizontalAlignment to Text.AlignHCenter and bind the width to
+ need to either modify the Item::anchors, or set horizontalAlignment to Text.AlignHCenter and bind the width to
that of the parent.
When using the attached property \l {LayoutMirroring::enabled} to mirror application
@@ -1185,7 +1185,7 @@ void QDeclarativeText::setWrapMode(WrapMode mode)
d->wrapMode = mode;
d->updateLayout();
-
+
emit wrapModeChanged();
}
@@ -1269,7 +1269,7 @@ void QDeclarativeText::resetMaximumLineCount()
The way the text property should be displayed.
Supported text formats are:
-
+
\list
\li Text.AutoText (default)
\li Text.PlainText
@@ -1382,7 +1382,7 @@ void QDeclarativeText::setElideMode(QDeclarativeText::TextElideMode mode)
d->elideMode = mode;
d->updateLayout();
-
+
emit elideModeChanged(d->elideMode);
}
diff --git a/src/declarative/graphicsitems/qdeclarativetextedit.cpp b/src/declarative/graphicsitems/qdeclarativetextedit.cpp
index bdcc66ba..ce079288 100644
--- a/src/declarative/graphicsitems/qdeclarativetextedit.cpp
+++ b/src/declarative/graphicsitems/qdeclarativetextedit.cpp
@@ -473,7 +473,7 @@ void QDeclarativeTextEdit::setSelectedTextColor(const QColor &color)
\li TextEdit.AlignHCenter
\li TextEdit.AlignJustify
\endlist
-
+
Valid values for \c verticalAlignment are:
\list
\li TextEdit.AlignTop (default)
diff --git a/src/declarative/graphicsitems/qdeclarativetextedit_p.h b/src/declarative/graphicsitems/qdeclarativetextedit_p.h
index 4ce11e01..8421da8a 100644
--- a/src/declarative/graphicsitems/qdeclarativetextedit_p.h
+++ b/src/declarative/graphicsitems/qdeclarativetextedit_p.h
@@ -273,7 +273,7 @@ private:
void updateTotalLines();
protected:
- virtual void geometryChanged(const QRectF &newGeometry,
+ virtual void geometryChanged(const QRectF &newGeometry,
const QRectF &oldGeometry);
bool event(QEvent *);
diff --git a/src/declarative/graphicsitems/qdeclarativetextinput.cpp b/src/declarative/graphicsitems/qdeclarativetextinput.cpp
index 787424e4..0369c051 100644
--- a/src/declarative/graphicsitems/qdeclarativetextinput.cpp
+++ b/src/declarative/graphicsitems/qdeclarativetextinput.cpp
@@ -78,7 +78,7 @@ QT_BEGIN_NAMESPACE
On Mac OS X, the Up/Down key bindings for Home/End are explicitly disabled.
If you want such bindings (on any platform), you will need to construct them in QML.
-
+
\sa TextEdit, Text, {declarative/text/textselection}{Text Selection example}
*/
QDeclarativeTextInput::QDeclarativeTextInput(QDeclarativeItem* parent)
@@ -740,7 +740,7 @@ void QDeclarativeTextInput::setAutoScroll(bool b)
This property holds the notation of how a string can describe a number.
The possible values for this property are:
-
+
\list
\li DoubleValidator.StandardNotation
\li DoubleValidator.ScientificNotation (default)
diff --git a/src/declarative/graphicsitems/qdeclarativetextlayout.cpp b/src/declarative/graphicsitems/qdeclarativetextlayout.cpp
index 9e03bfe3..895f1107 100644
--- a/src/declarative/graphicsitems/qdeclarativetextlayout.cpp
+++ b/src/declarative/graphicsitems/qdeclarativetextlayout.cpp
@@ -53,7 +53,7 @@ QT_BEGIN_NAMESPACE
class QDeclarativeTextLayoutPrivate
{
public:
- QDeclarativeTextLayoutPrivate()
+ QDeclarativeTextLayoutPrivate()
: cached(false) {}
QPointF position;
@@ -103,7 +103,7 @@ class DrawTextItemRecorder: public QPaintEngine
last.numChars += ti.num_chars;
}
- }
+ }
if (needFreshCurrentItem) {
QStaticTextItem currentItem;
@@ -257,10 +257,10 @@ Q_GLOBAL_STATIC(InertTextPainter, inertTextPainter);
This class is basically a copy of the QStaticText code, but it is adapted to source its text from
QTextLayout.
-It is also considerably faster to create a QDeclarativeTextLayout than a QStaticText because it uses
+It is also considerably faster to create a QDeclarativeTextLayout than a QStaticText because it uses
a single, shared QPainter instance. QStaticText by comparison creates a new QPainter per instance.
-As a consequence this means that QDeclarativeTextLayout is not re-enterant. Adding a lock around
-the shared painter solves this, and only introduces a minor performance penalty, but is unnecessary
+As a consequence this means that QDeclarativeTextLayout is not re-enterant. Adding a lock around
+the shared painter solves this, and only introduces a minor performance penalty, but is unnecessary
for QDeclarativeTextLayout's current use (QDeclarativeText is already tied to the GUI thread).
*/
@@ -309,7 +309,7 @@ void QDeclarativeTextLayout::prepare()
{
if (!d || !d->cached) {
- if (!d)
+ if (!d)
d = new QDeclarativeTextLayoutPrivate;
InertTextPainter *itp = inertTextPainter();
diff --git a/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp b/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp
index caa79f16..3df13a6b 100644
--- a/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp
+++ b/src/declarative/graphicsitems/qdeclarativevisualitemmodel.cpp
@@ -651,9 +651,9 @@ QDeclarativeVisualDataModelData *QDeclarativeVisualDataModelPrivate::data(QObjec
be instantiated for items in the model.
It is usually not necessary to create VisualDataModel elements.
- However, it can be useful for manipulating and accessing the \l modelIndex
- when a QAbstractItemModel subclass is used as the
- model. Also, VisualDataModel is used together with \l Package to
+ However, it can be useful for manipulating and accessing the \l modelIndex
+ when a QAbstractItemModel subclass is used as the
+ model. Also, VisualDataModel is used together with \l Package to
provide delegates to multiple views.
The example below illustrates using a VisualDataModel with a ListView.
@@ -843,7 +843,7 @@ void QDeclarativeVisualDataModel::setDelegate(QDeclarativeComponent *delegate)
any node in a QAbstractItemModel to be provided by this model.
This property only affects models of type QAbstractItemModel that
- are hierarchical (e.g, a tree model).
+ are hierarchical (e.g, a tree model).
For example, here is a simple interactive file system browser.
When a directory name is clicked, the view's \c rootIndex is set to the
@@ -852,13 +852,13 @@ void QDeclarativeVisualDataModel::setDelegate(QDeclarativeComponent *delegate)
\c main.cpp:
\snippet doc/src/snippets/declarative/visualdatamodel_rootindex/main.cpp 0
-
+
\c view.qml:
\snippet doc/src/snippets/declarative/visualdatamodel_rootindex/view.qml 0
If the \l model is a QAbstractItemModel subclass, the delegate can also
reference a \c hasModelChildren property (optionally qualified by a
- \e model. prefix) that indicates whether the delegate's model item has
+ \e model. prefix) that indicates whether the delegate's model item has
any child nodes.
diff --git a/src/declarative/qml/qbitfield_p.h b/src/declarative/qml/qbitfield_p.h
index 6050080f..e6402908 100644
--- a/src/declarative/qml/qbitfield_p.h
+++ b/src/declarative/qml/qbitfield_p.h
@@ -90,13 +90,13 @@ QBitField::QBitField(const quint32 *bitData, int bitCount)
QBitField::QBitField(const QBitField &other)
: bits(other.bits), ownData(other.ownData), data(other.data)
{
- if (ownData)
+ if (ownData)
++(*ownData);
}
QBitField::~QBitField()
{
- if (ownData)
+ if (ownData)
if(0 == --(*ownData)) delete [] ownData;
}
@@ -105,14 +105,14 @@ QBitField &QBitField::operator=(const QBitField &other)
if (other.data == data)
return *this;
- if (ownData)
+ if (ownData)
if(0 == --(*ownData)) delete [] ownData;
bits = other.bits;
ownData = other.ownData;
data = other.data;
- if (ownData)
+ if (ownData)
++(*ownData);
return *this;
diff --git a/src/declarative/qml/qdeclarative.h b/src/declarative/qml/qdeclarative.h
index 95cef935..2b4aae47 100644
--- a/src/declarative/qml/qdeclarative.h
+++ b/src/declarative/qml/qdeclarative.h
@@ -54,10 +54,10 @@
#define QML_DECLARE_TYPE(TYPE) \
Q_DECLARE_METATYPE(TYPE *) \
- Q_DECLARE_METATYPE(QDeclarativeListProperty<TYPE>)
+ Q_DECLARE_METATYPE(QDeclarativeListProperty<TYPE>)
#define QML_DECLARE_TYPE_HASMETATYPE(TYPE) \
- Q_DECLARE_METATYPE(QDeclarativeListProperty<TYPE>)
+ Q_DECLARE_METATYPE(QDeclarativeListProperty<TYPE>)
#define QML_DECLARE_INTERFACE(INTERFACE) \
QML_DECLARE_TYPE(INTERFACE)
@@ -94,7 +94,7 @@ int qmlRegisterType()
QByteArray listName("QDeclarativeListProperty<" + name + ">");
QDeclarativePrivate::RegisterType type = {
- 0,
+ 0,
qRegisterMetaType<T *>(pointerName.constData()),
qRegisterMetaType<QDeclarativeListProperty<T> >(listName.constData()),
@@ -106,7 +106,7 @@ int qmlRegisterType()
QDeclarativePrivate::attachedPropertiesFunc<T>(),
QDeclarativePrivate::attachedPropertiesMetaObject<T>(),
- QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
+ QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueSource>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueInterceptor>::cast(),
@@ -164,7 +164,7 @@ int qmlRegisterType(const char *uri, int versionMajor, int versionMinor, const c
QByteArray listName("QDeclarativeListProperty<" + name + ">");
QDeclarativePrivate::RegisterType type = {
- 0,
+ 0,
qRegisterMetaType<T *>(pointerName.constData()),
qRegisterMetaType<QDeclarativeListProperty<T> >(listName.constData()),
@@ -176,7 +176,7 @@ int qmlRegisterType(const char *uri, int versionMajor, int versionMinor, const c
QDeclarativePrivate::attachedPropertiesFunc<T>(),
QDeclarativePrivate::attachedPropertiesMetaObject<T>(),
- QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
+ QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueSource>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueInterceptor>::cast(),
@@ -267,7 +267,7 @@ int qmlRegisterExtendedType()
QByteArray listName("QDeclarativeListProperty<" + name + ">");
QDeclarativePrivate::RegisterType type = {
- 0,
+ 0,
qRegisterMetaType<T *>(pointerName.constData()),
qRegisterMetaType<QDeclarativeListProperty<T> >(listName.constData()),
@@ -279,7 +279,7 @@ int qmlRegisterExtendedType()
QDeclarativePrivate::attachedPropertiesFunc<T>(),
QDeclarativePrivate::attachedPropertiesMetaObject<T>(),
- QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
+ QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueSource>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueInterceptor>::cast(),
@@ -293,7 +293,7 @@ int qmlRegisterExtendedType()
}
template<typename T, typename E>
-int qmlRegisterExtendedType(const char *uri, int versionMajor, int versionMinor,
+int qmlRegisterExtendedType(const char *uri, int versionMajor, int versionMinor,
const char *qmlName)
{
QByteArray name(T::staticMetaObject.className());
@@ -302,14 +302,14 @@ int qmlRegisterExtendedType(const char *uri, int versionMajor, int versionMinor,
QByteArray listName("QDeclarativeListProperty<" + name + ">");
QDeclarativeAttachedPropertiesFunc attached = QDeclarativePrivate::attachedPropertiesFunc<E>();
- const QMetaObject * attachedMetaObject = QDeclarativePrivate::attachedPropertiesMetaObject<E>();
+ const QMetaObject * attachedMetaObject = QDeclarativePrivate::attachedPropertiesMetaObject<E>();
if (!attached) {
attached = QDeclarativePrivate::attachedPropertiesFunc<T>();
attachedMetaObject = QDeclarativePrivate::attachedPropertiesMetaObject<T>();
}
QDeclarativePrivate::RegisterType type = {
- 0,
+ 0,
qRegisterMetaType<T *>(pointerName.constData()),
qRegisterMetaType<QDeclarativeListProperty<T> >(listName.constData()),
@@ -321,7 +321,7 @@ int qmlRegisterExtendedType(const char *uri, int versionMajor, int versionMinor,
attached,
attachedMetaObject,
- QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
+ QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueSource>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueInterceptor>::cast(),
@@ -355,7 +355,7 @@ int qmlRegisterInterface(const char *typeName)
}
template<typename T>
-int qmlRegisterCustomType(const char *uri, int versionMajor, int versionMinor,
+int qmlRegisterCustomType(const char *uri, int versionMajor, int versionMinor,
const char *qmlName, QDeclarativeCustomParser *parser)
{
QByteArray name(T::staticMetaObject.className());
@@ -364,7 +364,7 @@ int qmlRegisterCustomType(const char *uri, int versionMajor, int versionMinor,
QByteArray listName("QDeclarativeListProperty<" + name + ">");
QDeclarativePrivate::RegisterType type = {
- 0,
+ 0,
qRegisterMetaType<T *>(pointerName.constData()),
qRegisterMetaType<QDeclarativeListProperty<T> >(listName.constData()),
@@ -376,7 +376,7 @@ int qmlRegisterCustomType(const char *uri, int versionMajor, int versionMinor,
QDeclarativePrivate::attachedPropertiesFunc<T>(),
QDeclarativePrivate::attachedPropertiesMetaObject<T>(),
- QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
+ QDeclarativePrivate::StaticCastSelector<T,QDeclarativeParserStatus>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueSource>::cast(),
QDeclarativePrivate::StaticCastSelector<T,QDeclarativePropertyValueInterceptor>::cast(),
diff --git a/src/declarative/qml/qdeclarativebinding.cpp b/src/declarative/qml/qdeclarativebinding.cpp
index cdfb5ce4..00953800 100644
--- a/src/declarative/qml/qdeclarativebinding.cpp
+++ b/src/declarative/qml/qdeclarativebinding.cpp
@@ -71,7 +71,7 @@ QDeclarativeAbstractBinding::~QDeclarativeAbstractBinding()
/*!
Destroy the binding. Use this instead of calling delete.
-Bindings are free to implement their own memory management, so the delete operator is not
+Bindings are free to implement their own memory management, so the delete operator is not
necessarily safe. The default implementation clears the binding, removes it from the object
and calls delete.
*/
@@ -87,7 +87,7 @@ void QDeclarativeAbstractBinding::destroy()
Add this binding to \a object.
This transfers ownership of the binding to the object, marks the object's property as
-being bound.
+being bound.
However, it does not enable the binding itself or call update() on it.
*/
@@ -227,8 +227,8 @@ QDeclarativeBindingPrivate::~QDeclarativeBindingPrivate()
if (deleted) *deleted = true;
}
-QDeclarativeBinding::QDeclarativeBinding(void *data, QDeclarativeRefCount *rc, QObject *obj,
- QDeclarativeContextData *ctxt, const QString &url, int lineNumber,
+QDeclarativeBinding::QDeclarativeBinding(void *data, QDeclarativeRefCount *rc, QObject *obj,
+ QDeclarativeContextData *ctxt, const QString &url, int lineNumber,
QObject *parent)
: QDeclarativeExpression(ctxt, data, rc, obj, url, lineNumber, *new QDeclarativeBindingPrivate)
{
@@ -261,7 +261,7 @@ QDeclarativeBinding::createBinding(Identifier id, QObject *obj, QDeclarativeCont
return rv;
}
-QDeclarativeBinding::QDeclarativeBinding(const QString &str, QObject *obj, QDeclarativeContext *ctxt,
+QDeclarativeBinding::QDeclarativeBinding(const QString &str, QObject *obj, QDeclarativeContext *ctxt,
QObject *parent)
: QDeclarativeExpression(QDeclarativeContextData::get(ctxt), obj, str, *new QDeclarativeBindingPrivate)
{
@@ -269,7 +269,7 @@ QDeclarativeBinding::QDeclarativeBinding(const QString &str, QObject *obj, QDecl
setNotifyOnValueChanged(true);
}
-QDeclarativeBinding::QDeclarativeBinding(const QString &str, QObject *obj, QDeclarativeContextData *ctxt,
+QDeclarativeBinding::QDeclarativeBinding(const QString &str, QObject *obj, QDeclarativeContextData *ctxt,
QObject *parent)
: QDeclarativeExpression(ctxt, obj, str, *new QDeclarativeBindingPrivate)
{
@@ -296,10 +296,10 @@ void QDeclarativeBinding::setTarget(const QDeclarativeProperty &prop)
update();
}
-QDeclarativeProperty QDeclarativeBinding::property() const
+QDeclarativeProperty QDeclarativeBinding::property() const
{
Q_D(const QDeclarativeBinding);
- return d->property;
+ return d->property;
}
void QDeclarativeBinding::setEvaluateFlags(EvaluateFlags flags)
@@ -334,7 +334,7 @@ void QDeclarativeBinding::update(QDeclarativePropertyPrivate::WriteFlags flags)
{
Q_D(QDeclarativeBinding);
- if (!d->enabled || !d->context() || !d->context()->isValid())
+ if (!d->enabled || !d->context() || !d->context()->isValid())
return;
if (!d->updating) {
@@ -370,7 +370,7 @@ void QDeclarativeBinding::update(QDeclarativePropertyPrivate::WriteFlags flags)
if (d->property.propertyTypeCategory() == QDeclarativeProperty::List) {
value = ep->scriptValueToVariant(scriptValue, qMetaTypeId<QList<QObject *> >());
- } else if (scriptValue.isNull() &&
+ } else if (scriptValue.isNull() &&
d->property.propertyTypeCategory() == QDeclarativeProperty::Object) {
value = QVariant::fromValue((QObject *)0);
} else {
@@ -469,7 +469,7 @@ void QDeclarativeBinding::setEnabled(bool e, QDeclarativePropertyPrivate::WriteF
d->enabled = e;
setNotifyOnValueChanged(e);
- if (e)
+ if (e)
update(flags);
}
@@ -541,8 +541,8 @@ void QDeclarativeValueTypeProxyBinding::update(QDeclarativePropertyPrivate::Writ
QDeclarativeAbstractBinding *QDeclarativeValueTypeProxyBinding::binding(int propertyIndex)
{
QDeclarativeAbstractBinding *binding = m_bindings;
-
- while (binding && binding->propertyIndex() != propertyIndex)
+
+ while (binding && binding->propertyIndex() != propertyIndex)
binding = binding->m_nextBinding;
return binding;
diff --git a/src/declarative/qml/qdeclarativebinding_p.h b/src/declarative/qml/qdeclarativebinding_p.h
index bb92e2b9..296cc506 100644
--- a/src/declarative/qml/qdeclarativebinding_p.h
+++ b/src/declarative/qml/qdeclarativebinding_p.h
@@ -150,7 +150,7 @@ public:
QDeclarativeBinding(const QString &, QObject *, QDeclarativeContext *, QObject *parent=0);
QDeclarativeBinding(const QString &, QObject *, QDeclarativeContextData *, QObject *parent=0);
- QDeclarativeBinding(void *, QDeclarativeRefCount *, QObject *, QDeclarativeContextData *,
+ QDeclarativeBinding(void *, QDeclarativeRefCount *, QObject *, QDeclarativeContextData *,
const QString &, int, QObject *parent);
QDeclarativeBinding(const QScriptValue &, QObject *, QDeclarativeContextData *, QObject *parent=0);
diff --git a/src/declarative/qml/qdeclarativebinding_p_p.h b/src/declarative/qml/qdeclarativebinding_p_p.h
index f59e78d3..1789ec62 100644
--- a/src/declarative/qml/qdeclarativebinding_p_p.h
+++ b/src/declarative/qml/qdeclarativebinding_p_p.h
@@ -75,7 +75,7 @@ protected:
private:
bool updating:1;
bool enabled:1;
- QDeclarativeProperty property;
+ QDeclarativeProperty property;
bool *deleted;
};
diff --git a/src/declarative/qml/qdeclarativeboundsignal.cpp b/src/declarative/qml/qdeclarativeboundsignal.cpp
index 3e6022ff..7b689c8e 100644
--- a/src/declarative/qml/qdeclarativeboundsignal.cpp
+++ b/src/declarative/qml/qdeclarativeboundsignal.cpp
@@ -75,7 +75,7 @@ private:
MetaObject(QDeclarativeBoundSignalParameters *b)
: parent(b) {}
- int metaCall(QMetaObject::Call c, int id, void **a) {
+ int metaCall(QMetaObject::Call c, int id, void **a) {
return parent->metaCall(c, id, a);
}
QDeclarativeBoundSignalParameters *parent;
@@ -97,7 +97,7 @@ QDeclarativeAbstractBoundSignal::~QDeclarativeAbstractBoundSignal()
{
}
-QDeclarativeBoundSignal::QDeclarativeBoundSignal(QObject *scope, const QMetaMethod &signal,
+QDeclarativeBoundSignal::QDeclarativeBoundSignal(QObject *scope, const QMetaMethod &signal,
QObject *parent)
: m_expression(0), m_signal(signal), m_paramsValid(false), m_isEvaluating(false), m_params(0)
{
@@ -110,7 +110,7 @@ QDeclarativeBoundSignal::QDeclarativeBoundSignal(QObject *scope, const QMetaMeth
QDeclarativePropertyPrivate::connect(scope, m_signal.methodIndex(), this, evaluateIdx);
}
-QDeclarativeBoundSignal::QDeclarativeBoundSignal(QDeclarativeContext *ctxt, const QString &val,
+QDeclarativeBoundSignal::QDeclarativeBoundSignal(QDeclarativeContext *ctxt, const QString &val,
QObject *scope, const QMetaMethod &signal,
QObject *parent)
: m_expression(0), m_signal(signal), m_paramsValid(false), m_isEvaluating(false), m_params(0)
@@ -132,8 +132,8 @@ QDeclarativeBoundSignal::~QDeclarativeBoundSignal()
m_expression = 0;
}
-int QDeclarativeBoundSignal::index() const
-{
+int QDeclarativeBoundSignal::index() const
+{
return m_signal.methodIndex();
}
@@ -149,7 +149,7 @@ QDeclarativeExpression *QDeclarativeBoundSignal::expression() const
Sets the signal expression to \a e. Returns the current signal expression,
or null if there is no signal expression.
- The QDeclarativeBoundSignal instance takes ownership of \a e. The caller is
+ The QDeclarativeBoundSignal instance takes ownership of \a e. The caller is
assumes ownership of the returned QDeclarativeExpression.
*/
QDeclarativeExpression *QDeclarativeBoundSignal::setExpression(QDeclarativeExpression *e)
@@ -198,7 +198,7 @@ int QDeclarativeBoundSignal::qt_metacall(QMetaObject::Call c, int id, void **a)
}
}
-QDeclarativeBoundSignalParameters::QDeclarativeBoundSignalParameters(const QMetaMethod &method,
+QDeclarativeBoundSignalParameters::QDeclarativeBoundSignalParameters(const QMetaMethod &method,
QObject *parent)
: QObject(parent), types(0), values(0)
{
diff --git a/src/declarative/qml/qdeclarativeboundsignal_p.h b/src/declarative/qml/qdeclarativeboundsignal_p.h
index d38970e0..cf5a3678 100644
--- a/src/declarative/qml/qdeclarativeboundsignal_p.h
+++ b/src/declarative/qml/qdeclarativeboundsignal_p.h
@@ -74,7 +74,7 @@ class QDeclarativeBoundSignal : public QDeclarativeAbstractBoundSignal
{
public:
QDeclarativeBoundSignal(QObject *scope, const QMetaMethod &signal, QObject *parent);
- QDeclarativeBoundSignal(QDeclarativeContext *ctxt, const QString &val, QObject *scope,
+ QDeclarativeBoundSignal(QDeclarativeContext *ctxt, const QString &val, QObject *scope,
const QMetaMethod &signal, QObject *parent);
virtual ~QDeclarativeBoundSignal();
diff --git a/src/declarative/qml/qdeclarativecleanup.cpp b/src/declarative/qml/qdeclarativecleanup.cpp
index e91d5eb6..1ef07dc7 100644
--- a/src/declarative/qml/qdeclarativecleanup.cpp
+++ b/src/declarative/qml/qdeclarativecleanup.cpp
@@ -48,7 +48,7 @@ QT_BEGIN_NAMESPACE
/*!
\internal
\class QDeclarativeCleanup
-\brief The QDeclarativeCleanup provides a callback when a QDeclarativeEngine is deleted.
+\brief The QDeclarativeCleanup provides a callback when a QDeclarativeEngine is deleted.
Any object that needs cleanup to occur before the QDeclarativeEngine's QScriptEngine is
destroyed should inherit from QDeclarativeCleanup. The clear() virtual method will be
@@ -81,7 +81,7 @@ QDeclarativeCleanup::~QDeclarativeCleanup()
{
if (prev) *prev = next;
if (next) next->prev = prev;
- prev = 0;
+ prev = 0;
next = 0;
}
QT_END_NAMESPACE
diff --git a/src/declarative/qml/qdeclarativecleanup_p.h b/src/declarative/qml/qdeclarativecleanup_p.h
index 140ca39a..b6aa9961 100644
--- a/src/declarative/qml/qdeclarativecleanup_p.h
+++ b/src/declarative/qml/qdeclarativecleanup_p.h
@@ -44,7 +44,7 @@
#include <QtCore/qglobal.h>
-//
+//
// W A R N I N G
// -------------
//
diff --git a/src/declarative/qml/qdeclarativecompiledbindings.cpp b/src/declarative/qml/qdeclarativecompiledbindings.cpp
index 5546a5e6..19a9b4c7 100644
--- a/src/declarative/qml/qdeclarativecompiledbindings.cpp
+++ b/src/declarative/qml/qdeclarativecompiledbindings.cpp
@@ -242,7 +242,7 @@ public:
static int methodCount;
void init();
- void run(int instr, QDeclarativeContextData *context,
+ void run(int instr, QDeclarativeContextData *context,
QDeclarativeDelayedError *error, QObject *scope, QObject *output, QDeclarativePropertyPrivate::WriteFlags storeFlags);
@@ -250,20 +250,20 @@ public:
inline void subscribeId(QDeclarativeContextData *p, int idIndex, int subIndex);
inline void subscribe(QObject *o, int notifyIndex, int subIndex);
- QDeclarativePropertyCache::Data *findproperty(QObject *obj,
+ QDeclarativePropertyCache::Data *findproperty(QObject *obj,
const QScriptDeclarativeClass::Identifier &name,
- QDeclarativeEnginePrivate *enginePriv,
+ QDeclarativeEnginePrivate *enginePriv,
QDeclarativePropertyCache::Data &local);
- bool findproperty(QObject *obj,
- Register *output,
+ bool findproperty(QObject *obj,
+ Register *output,
QDeclarativeEnginePrivate *enginePriv,
- int subIdx,
+ int subIdx,
const QScriptDeclarativeClass::Identifier &name,
bool isTerminal);
void findgeneric(Register *output, // value output
int subIdx, // Subscription index in config
QDeclarativeContextData *context, // Context to search in
- const QScriptDeclarativeClass::Identifier &name,
+ const QScriptDeclarativeClass::Identifier &name,
bool isTerminal);
};
@@ -276,15 +276,15 @@ QDeclarativeCompiledBindingsPrivate::~QDeclarativeCompiledBindingsPrivate()
{
delete [] subscriptions; subscriptions = 0;
delete [] identifiers; identifiers = 0;
- if (dataRef) {
- dataRef->release();
- dataRef = 0;
+ if (dataRef) {
+ dataRef->release();
+ dataRef = 0;
}
}
int QDeclarativeCompiledBindingsPrivate::methodCount = -1;
-QDeclarativeCompiledBindings::QDeclarativeCompiledBindings(const char *program, QDeclarativeContextData *context,
+QDeclarativeCompiledBindings::QDeclarativeCompiledBindings(const char *program, QDeclarativeContextData *context,
QDeclarativeRefCount *dataRef)
: QObject(*(new QDeclarativeCompiledBindingsPrivate))
{
@@ -309,7 +309,7 @@ QDeclarativeCompiledBindings::~QDeclarativeCompiledBindings()
delete [] d->m_bindings;
}
-QDeclarativeAbstractBinding *QDeclarativeCompiledBindings::configBinding(int index, QObject *target,
+QDeclarativeAbstractBinding *QDeclarativeCompiledBindings::configBinding(int index, QObject *target,
QObject *scope, int property)
{
Q_D(QDeclarativeCompiledBindings);
@@ -376,7 +376,7 @@ void QDeclarativeCompiledBindingsPrivate::run(Binding *binding, QDeclarativeProp
return;
QDeclarativeContextData *context = q->QDeclarativeAbstractExpression::context();
- if (!context || !context->isValid())
+ if (!context || !context->isValid())
return;
if (binding->updating) {
@@ -558,7 +558,7 @@ struct Instr {
qint8 reg;
qint8 src;
quint8 exceptionId;
- quint16 name;
+ quint16 name;
quint16 subscribeIndex;
} find;
struct {
@@ -596,13 +596,13 @@ struct QDeclarativeBindingCompilerPrivate
{
struct Result {
Result() : unknownType(false), metaObject(0), type(-1), reg(-1) {}
- bool operator==(const Result &o) const {
+ bool operator==(const Result &o) const {
return unknownType == o.unknownType &&
- metaObject == o.metaObject &&
+ metaObject == o.metaObject &&
type == o.type &&
- reg == o.reg;
+ reg == o.reg;
}
- bool operator!=(const Result &o) const {
+ bool operator!=(const Result &o) const {
return !(*this == o);
}
bool unknownType;
@@ -715,14 +715,14 @@ void QDeclarativeCompiledBindingsPrivate::subscribeId(QDeclarativeContextData *p
sub->connect(&p->idValues[idIndex].bindings);
}
}
-
+
void QDeclarativeCompiledBindingsPrivate::subscribe(QObject *o, int notifyIndex, int subIndex)
{
Q_Q(QDeclarativeCompiledBindings);
QDeclarativeCompiledBindingsPrivate::Subscription *sub = (subscriptions + subIndex);
sub->target = q;
- sub->targetMethod = methodCount + subIndex;
+ sub->targetMethod = methodCount + subIndex;
if (o)
sub->connect(o, notifyIndex);
else
@@ -819,7 +819,7 @@ static QObject *variantToQObject(const QVariant &value, bool *ok)
}
}
-bool QDeclarativeCompiledBindingsPrivate::findproperty(QObject *obj, Register *output,
+bool QDeclarativeCompiledBindingsPrivate::findproperty(QObject *obj, Register *output,
QDeclarativeEnginePrivate *enginePriv,
int subIdx, const QScriptDeclarativeClass::Identifier &name,
bool isTerminal)
@@ -830,7 +830,7 @@ bool QDeclarativeCompiledBindingsPrivate::findproperty(QObject *obj, Register *o
}
QDeclarativePropertyCache::Data local;
- QDeclarativePropertyCache::Data *property =
+ QDeclarativePropertyCache::Data *property =
QDeclarativePropertyCache::property(QDeclarativeEnginePrivate::get(enginePriv), obj, name, local);
if (property) {
@@ -852,7 +852,7 @@ bool QDeclarativeCompiledBindingsPrivate::findproperty(QObject *obj, Register *o
} else {
bool ok;
output->setQObject(variantToQObject(v, &ok));
- if (!ok)
+ if (!ok)
output->setUndefined();
else
output->settype(QMetaType::QObjectStar);
@@ -879,7 +879,7 @@ bool QDeclarativeCompiledBindingsPrivate::findproperty(QObject *obj, Register *o
QMetaObject::metacall(obj, QMetaObject::ReadProperty, property->coreIndex, args);
output->settype(QMetaType::QString);
} else {
- new (output->typeDataPtr())
+ new (output->typeDataPtr())
QVariant(obj->metaObject()->property(property->coreIndex).read(obj));
output->settype(qMetaTypeId<QVariant>());
}
@@ -892,10 +892,10 @@ bool QDeclarativeCompiledBindingsPrivate::findproperty(QObject *obj, Register *o
}
}
-void QDeclarativeCompiledBindingsPrivate::findgeneric(Register *output,
- int subIdx,
+void QDeclarativeCompiledBindingsPrivate::findgeneric(Register *output,
+ int subIdx,
QDeclarativeContextData *context,
- const QScriptDeclarativeClass::Identifier &name,
+ const QScriptDeclarativeClass::Identifier &name,
bool isTerminal)
{
QDeclarativeEnginePrivate *enginePriv = QDeclarativeEnginePrivate::get(context->engine);
@@ -911,7 +911,7 @@ void QDeclarativeCompiledBindingsPrivate::findgeneric(Register *output,
output->setQObject(context->idValues[contextPropertyIndex]);
output->settype(QMetaType::QObjectStar);
- if (subIdx != -1)
+ if (subIdx != -1)
subscribeId(context, contextPropertyIndex, subIdx);
} else {
@@ -929,7 +929,7 @@ void QDeclarativeCompiledBindingsPrivate::findgeneric(Register *output,
return;
}
- if (subIdx != -1)
+ if (subIdx != -1)
subscribe(context->asQDeclarativeContext(), contextPropertyIndex + cp->notifyIndex, subIdx);
@@ -963,7 +963,7 @@ void QDeclarativeCompiledBindingsPrivate::init()
m_bindings = new QDeclarativeCompiledBindingsPrivate::Binding[program->bindings];
}
-static void throwException(int id, QDeclarativeDelayedError *error,
+static void throwException(int id, QDeclarativeDelayedError *error,
Program *program, QDeclarativeContextData *context,
const QString &description = QString())
{
@@ -973,9 +973,9 @@ static void throwException(int id, QDeclarativeDelayedError *error,
else
error->error.setDescription(description);
if (id != 0xFF) {
- quint64 e = *((quint64 *)(program->data() + program->exceptionDataOffset) + id);
+ quint64 e = *((quint64 *)(program->data() + program->exceptionDataOffset) + id);
error->error.setLine((e >> 32) & 0xFFFFFFFF);
- error->error.setColumn(e & 0xFFFFFFFF);
+ error->error.setColumn(e & 0xFFFFFFFF);
} else {
error->error.setLine(-1);
error->error.setColumn(-1);
@@ -1216,7 +1216,7 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
if (subIdx != -1) {
sub = (subscriptions + subIdx);
sub->target = q;
- sub->targetMethod = methodCount + subIdx;
+ sub->targetMethod = methodCount + subIdx;
}
fastProperties()->accessor(instr->fetchAndSubscribe.function)(object, output.typeDataPtr(), sub);
}
@@ -1248,9 +1248,9 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
if (!object) {
output.setUndefined();
} else {
- QObject *attached =
- qmlAttachedPropertiesObjectById(instr->attached.id,
- registers[instr->attached.reg].getQObject(),
+ QObject *attached =
+ qmlAttachedPropertiesObjectById(instr->attached.id,
+ registers[instr->attached.reg].getQObject(),
true);
Q_ASSERT(attached);
output.setQObject(attached);
@@ -1283,7 +1283,7 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
QML_BEGIN_INSTR(Int)
registers[instr->int_value.reg].setint(instr->int_value.value);
QML_END_INSTR(Int)
-
+
QML_BEGIN_INSTR(Bool)
registers[instr->bool_value.reg].setbool(instr->bool_value.value);
QML_END_INSTR(Bool)
@@ -1291,7 +1291,7 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
QML_BEGIN_INSTR(String)
{
Register &output = registers[instr->string_value.reg];
- new (output.getstringptr())
+ new (output.getstringptr())
QString((QChar *)(data + instr->string_value.offset), instr->string_value.length);
output.settype(QMetaType::QString);
}
@@ -1316,7 +1316,7 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
else output.setint(lhs.getint() + rhs.getint());
}
QML_END_INSTR(AddInt)
-
+
QML_BEGIN_INSTR(AddString)
{
const Register &lhs = registers[instr->binaryop.src1];
@@ -1331,8 +1331,8 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
new (output.getstringptr())
QString(*registers[instr->binaryop.src1].getstringptr() + QLatin1String("undefined"));
else
- new (output.getstringptr())
- QString(*registers[instr->binaryop.src1].getstringptr() +
+ new (output.getstringptr())
+ QString(*registers[instr->binaryop.src1].getstringptr() +
*registers[instr->binaryop.src2].getstringptr());
output.settype(QMetaType::QString);
}
@@ -1490,7 +1490,7 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
int status = -1;
void *argv[] = { data.typeDataPtr(), 0, &status, &storeFlags };
- QMetaObject::metacall(output, QMetaObject::WriteProperty,
+ QMetaObject::metacall(output, QMetaObject::WriteProperty,
instr->store.index, argv);
}
QML_END_INSTR(Store)
@@ -1500,7 +1500,7 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
QML_END_INSTR(Copy)
QML_BEGIN_INSTR(Skip)
- if (instr->skip.reg == -1 || !registers[instr->skip.reg].getbool())
+ if (instr->skip.reg == -1 || !registers[instr->skip.reg].getbool())
instr += instr->skip.count;
QML_END_INSTR(Skip)
@@ -1511,7 +1511,7 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
QML_BEGIN_INSTR(InitString)
if (!identifiers[instr->initstring.offset].identifier) {
quint32 len = *(quint32 *)(data + instr->initstring.dataIdx);
- QChar *strdata = (QChar *)(data + instr->initstring.dataIdx + sizeof(quint32));
+ QChar *strdata = (QChar *)(data + instr->initstring.dataIdx + sizeof(quint32));
QString str = QString::fromRawData(strdata, len);
@@ -1520,12 +1520,12 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
QML_END_INSTR(InitString)
QML_BEGIN_INSTR(FindGenericTerminal)
- // We start the search in the parent context, as we know that the
+ // We start the search in the parent context, as we know that the
// name is not present in the current context or it would have been
// found during the static compile
- findgeneric(registers + instr->find.reg, instr->find.subscribeIndex,
+ findgeneric(registers + instr->find.reg, instr->find.subscribeIndex,
context->parent,
- identifiers[instr->find.name].identifier,
+ identifiers[instr->find.name].identifier,
instr->common.type == Instr::FindGenericTerminal);
QML_END_INSTR(FindGenericTerminal)
@@ -1547,9 +1547,9 @@ void QDeclarativeCompiledBindingsPrivate::run(int instrIndex,
return;
}
- findproperty(object.getQObject(), registers + instr->find.reg,
- QDeclarativeEnginePrivate::get(context->engine),
- instr->find.subscribeIndex, identifiers[instr->find.name].identifier,
+ findproperty(object.getQObject(), registers + instr->find.reg,
+ QDeclarativeEnginePrivate::get(context->engine),
+ instr->find.subscribeIndex, identifiers[instr->find.name].identifier,
instr->common.type == Instr::FindPropertyTerminal);
}
QML_END_INSTR(FindPropertyTerminal)
@@ -1721,7 +1721,7 @@ bool QDeclarativeBindingCompilerPrivate::compile(QDeclarativeJS::AST::Node *node
Result type;
- if (!parseExpression(node, type))
+ if (!parseExpression(node, type))
return false;
if (subscriptionSet.count() > 0xFFFF ||
@@ -1918,7 +1918,7 @@ bool QDeclarativeBindingCompilerPrivate::parseName(AST::Node *node, Result &type
return false;
wasAttachedObject = true;
- }
+ }
if (ii == 0) {
@@ -1949,7 +1949,7 @@ bool QDeclarativeBindingCompilerPrivate::parseName(AST::Node *node, Result &type
absType = idObject;
type.metaObject = absType->metaObject();
- // We check if the id object is the root or
+ // We check if the id object is the root or
// scope object to avoid a subscription
if (idObject == component) {
Instr instr;
@@ -2029,18 +2029,18 @@ bool QDeclarativeBindingCompilerPrivate::parseName(AST::Node *node, Result &type
find.find.exceptionId = exceptionId(nameNodes.at(ii));
subscribeName << QString(QLatin1String("$$$Generic_") + name);
- if (subscription(subscribeName, &type))
+ if (subscription(subscribeName, &type))
find.find.subscribeIndex = subscriptionIndex(subscribeName);
else
find.find.subscribeIndex = -1;
bytecode << find;
type.unknownType = true;
- }
+ }
if (!type.unknownType && type.type == -1)
return false; // Couldn't fetch that type
- }
+ }
} else {
@@ -2074,13 +2074,13 @@ bool QDeclarativeBindingCompilerPrivate::parseName(AST::Node *node, Result &type
subscribeName << name;
if (absType || (wasAttachedObject && idx != -1) || (mo && mo->property(idx).isFinal())) {
- absType = 0;
+ absType = 0;
if (!fetch(type, mo, reg, idx, subscribeName, nameNodes.at(ii)))
return false;
} else {
Instr prop;
- if (ii == nameParts.count() -1 )
+ if (ii == nameParts.count() -1 )
prop.common.type = Instr::FindPropertyTerminal;
else
prop.common.type = Instr::FindProperty;
@@ -2141,8 +2141,8 @@ bool QDeclarativeBindingCompilerPrivate::parseArith(QDeclarativeJS::AST::Node *n
return numberArith(type, lhs, rhs, (QSOperator::Op)expression->op);
else if(expression->op == QSOperator::Sub)
return numberArith(type, lhs, rhs, (QSOperator::Op)expression->op);
- else if ((lhs.type == QMetaType::QString || lhs.unknownType) &&
- (rhs.type == QMetaType::QString || rhs.unknownType) &&
+ else if ((lhs.type == QMetaType::QString || lhs.unknownType) &&
+ (rhs.type == QMetaType::QString || rhs.unknownType) &&
(lhs.type == QMetaType::QString || rhs.type == QMetaType::QString))
return stringArith(type, lhs, rhs, (QSOperator::Op)expression->op);
else
@@ -2379,7 +2379,7 @@ bool QDeclarativeBindingCompilerPrivate::parseConditional(QDeclarativeJS::AST::N
Result etype;
if (!parseExpression(test, etype)) return false;
- if (etype.type != QVariant::Bool)
+ if (etype.type != QVariant::Bool)
return false;
Instr skip;
@@ -2487,7 +2487,7 @@ bool QDeclarativeBindingCompilerPrivate::parseConstant(QDeclarativeJS::AST::Node
bool QDeclarativeBindingCompilerPrivate::tryMethod(QDeclarativeJS::AST::Node *node)
{
- return node->kind == AST::Node::Kind_CallExpression;
+ return node->kind == AST::Node::Kind_CallExpression;
}
bool QDeclarativeBindingCompilerPrivate::parseMethod(QDeclarativeJS::AST::Node *node, Result &result)
@@ -2569,8 +2569,8 @@ bool QDeclarativeBindingCompilerPrivate::buildName(QStringList &name,
return true;
}
-bool QDeclarativeBindingCompilerPrivate::fetch(Result &rv, const QMetaObject *mo, int reg,
- int idx, const QStringList &subName,
+bool QDeclarativeBindingCompilerPrivate::fetch(Result &rv, const QMetaObject *mo, int reg,
+ int idx, const QStringList &subName,
QDeclarativeJS::AST::ExpressionNode *node)
{
QMetaProperty prop = mo->property(idx);
@@ -2722,7 +2722,7 @@ int QDeclarativeBindingCompilerPrivate::registerString(const QString &string)
data += strdata;
iter = registeredStrings.insert(string, qMakePair(registeredStrings.count(), rv));
- }
+ }
Instr reg;
reg.common.type = Instr::InitString;
@@ -2749,7 +2749,7 @@ int QDeclarativeBindingCompilerPrivate::subscriptionIndex(const QStringList &sub
{
QString str = sub.join(QLatin1String("."));
QHash<QString, int>::ConstIterator iter = subscriptionIds.find(str);
- if (iter == subscriptionIds.end())
+ if (iter == subscriptionIds.end())
iter = subscriptionIds.insert(str, subscriptionIds.count());
usedSubscriptionIds.insert(*iter);
return *iter;
@@ -2758,9 +2758,9 @@ int QDeclarativeBindingCompilerPrivate::subscriptionIndex(const QStringList &sub
/*
Returns true if lhs contains no subscriptions that aren't also in base or rhs AND
rhs contains no subscriptions that aren't also in base or lhs.
-*/
-bool QDeclarativeBindingCompilerPrivate::subscriptionNeutral(const QSet<QString> &base,
- const QSet<QString> &lhs,
+*/
+bool QDeclarativeBindingCompilerPrivate::subscriptionNeutral(const QSet<QString> &base,
+ const QSet<QString> &lhs,
const QSet<QString> &rhs)
{
QSet<QString> difflhs = lhs;
@@ -2798,7 +2798,7 @@ QDeclarativeBindingCompiler::~QDeclarativeBindingCompiler()
delete d; d = 0;
}
-/*
+/*
Returns true if any bindings were compiled.
*/
bool QDeclarativeBindingCompiler::isValid() const
@@ -2806,7 +2806,7 @@ bool QDeclarativeBindingCompiler::isValid() const
return !d->committed.bytecode.isEmpty();
}
-/*
+/*
-1 on failure, otherwise the binding index to use.
*/
int QDeclarativeBindingCompiler::compile(const Expression &expression, QDeclarativeEnginePrivate *engine)
@@ -2840,7 +2840,7 @@ QByteArray QDeclarativeBindingCompilerPrivate::buildSignalTable() const
for (int ii = 0; ii < committed.count(); ++ii) {
const QSet<int> &deps = committed.dependencies.at(ii);
- for (QSet<int>::ConstIterator iter = deps.begin(); iter != deps.end(); ++iter)
+ for (QSet<int>::ConstIterator iter = deps.begin(); iter != deps.end(); ++iter)
table[*iter].append(ii);
}
@@ -2866,7 +2866,7 @@ QByteArray QDeclarativeBindingCompilerPrivate::buildExceptionData() const
return rv;
}
-/*
+/*
Returns the compiled program.
*/
QByteArray QDeclarativeBindingCompiler::program() const
@@ -2907,11 +2907,11 @@ QByteArray QDeclarativeBindingCompiler::program() const
programData.resize(size);
memcpy(programData.data(), &prog, sizeof(Program));
if (prog.dataLength)
- memcpy((char *)((Program *)programData.data())->data(), data.constData(),
+ memcpy((char *)((Program *)programData.data())->data(), data.constData(),
data.size());
- memcpy((char *)((Program *)programData.data())->instructions(), bytecode.constData(),
+ memcpy((char *)((Program *)programData.data())->instructions(), bytecode.constData(),
bytecode.count() * sizeof(Instr));
- }
+ }
return programData;
}
diff --git a/src/declarative/qml/qdeclarativecompileddata.cpp b/src/declarative/qml/qdeclarativecompileddata.cpp
index e65cffca..bc3741cb 100644
--- a/src/declarative/qml/qdeclarativecompileddata.cpp
+++ b/src/declarative/qml/qdeclarativecompileddata.cpp
@@ -175,7 +175,7 @@ QDeclarativeCompiledData::~QDeclarativeCompiledData()
types.at(ii).typePropertyCache->release();
}
- for (int ii = 0; ii < propertyCaches.count(); ++ii)
+ for (int ii = 0; ii < propertyCaches.count(); ++ii)
propertyCaches.at(ii)->release();
for (int ii = 0; ii < contextCaches.count(); ++ii)
@@ -225,7 +225,7 @@ QDeclarativePropertyCache *QDeclarativeCompiledData::TypeReference::propertyCach
/*!
Returns the property cache, creating one if it doesn't already exist. The cache is not referenced.
*/
-QDeclarativePropertyCache *QDeclarativeCompiledData::TypeReference::createPropertyCache(QDeclarativeEngine *engine)
+QDeclarativePropertyCache *QDeclarativeCompiledData::TypeReference::createPropertyCache(QDeclarativeEngine *engine)
{
if (typePropertyCache) {
return typePropertyCache;
diff --git a/src/declarative/qml/qdeclarativecompiler.cpp b/src/declarative/qml/qdeclarativecompiler.cpp
index 6256bae3..cf220ee0 100644
--- a/src/declarative/qml/qdeclarativecompiler.cpp
+++ b/src/declarative/qml/qdeclarativecompiler.cpp
@@ -597,10 +597,10 @@ bool QDeclarativeCompiler::compile(QDeclarativeEngine *engine,
err = tr( "Element is not creatable.");
COMPILE_EXCEPTION(parserRef->refObjects.first(), err);
}
-
+
if (ref.type->containsRevisionedAttributes()) {
QDeclarativeError cacheError;
- ref.typePropertyCache =
+ ref.typePropertyCache =
QDeclarativeEnginePrivate::get(engine)->cache(ref.type, resolvedTypes.at(ii).minorVersion, cacheError);
if (!ref.typePropertyCache) {
@@ -707,7 +707,7 @@ void QDeclarativeCompiler::compileTree(QDeclarativeParser::Object *tree)
output->importCache = new QDeclarativeTypeNameCache(engine);
- for (int ii = 0; ii < importedScriptIndexes.count(); ++ii)
+ for (int ii = 0; ii < importedScriptIndexes.count(); ++ii)
output->importCache->add(importedScriptIndexes.at(ii), ii);
unit->imports().populateCache(output->importCache, engine);
@@ -720,7 +720,7 @@ void QDeclarativeCompiler::compileTree(QDeclarativeParser::Object *tree)
static_cast<QMetaObject &>(output->rootData) = *tree->metaObject();
output->root = &output->rootData;
}
- if (!tree->metadata.isEmpty())
+ if (!tree->metadata.isEmpty())
enginePrivate->registerCompositeType(output);
}
@@ -750,13 +750,13 @@ bool QDeclarativeCompiler::buildObject(QDeclarativeParser::Object *obj, const Bi
if (tr.type && obj->metatype == &QDeclarativeComponent::staticMetaObject) {
COMPILE_CHECK(buildComponent(obj, ctxt));
return true;
- }
+ }
// Object instantiations reset the binding context
BindingContext objCtxt(obj);
// Create the synthesized meta object, ignoring aliases
- COMPILE_CHECK(checkDynamicMeta(obj));
+ COMPILE_CHECK(checkDynamicMeta(obj));
COMPILE_CHECK(mergeDynamicMetaProperties(obj));
COMPILE_CHECK(buildDynamicMeta(obj, IgnoreAliases));
@@ -787,7 +787,7 @@ bool QDeclarativeCompiler::buildObject(QDeclarativeParser::Object *obj, const Bi
}
}
- // Merge
+ // Merge
Property *defaultProperty = 0;
Property *skipProperty = 0;
if (obj->defaultProperty) {
@@ -836,7 +836,7 @@ bool QDeclarativeCompiler::buildObject(QDeclarativeParser::Object *obj, const Bi
bool canDefer = false;
if (isCustomParser) {
- if (doesPropertyExist(prop, obj) &&
+ if (doesPropertyExist(prop, obj) &&
(!(cp->flags() & QDeclarativeCustomParser::AcceptsAttachedProperties) ||
!isAttachedPropertyName(prop->name))) {
int ids = compileState.ids.count();
@@ -885,7 +885,7 @@ bool QDeclarativeCompiler::buildObject(QDeclarativeParser::Object *obj, const Bi
prop->isDeferred = true;
}
- if (defaultProperty)
+ if (defaultProperty)
defaultProperty->release();
// Compile custom parser parts
@@ -936,10 +936,10 @@ void QDeclarativeCompiler::genObject(QDeclarativeParser::Object *obj)
if (!obj->custom.isEmpty())
create.create.data = output->indexForByteArray(obj->custom);
create.create.type = obj->type;
- if (!output->types.at(create.create.type).type &&
+ if (!output->types.at(create.create.type).type &&
!obj->bindingBitmask.isEmpty()) {
Q_ASSERT(obj->bindingBitmask.size() % 4 == 0);
- create.create.bindingBits =
+ create.create.bindingBits =
output->indexForByteArray(obj->bindingBitmask);
} else {
create.create.bindingBits = -1;
@@ -963,7 +963,7 @@ void QDeclarativeCompiler::genObject(QDeclarativeParser::Object *obj)
// Add flag for alias properties
if (!obj->synthdata.isEmpty()) {
- const QDeclarativeVMEMetaData *vmeMetaData =
+ const QDeclarativeVMEMetaData *vmeMetaData =
reinterpret_cast<const QDeclarativeVMEMetaData *>(obj->synthdata.constData());
for (int ii = 0; ii < vmeMetaData->aliasCount; ++ii) {
int index = obj->metaObject()->propertyOffset() + vmeMetaData->propertyCount + ii;
@@ -1012,7 +1012,7 @@ void QDeclarativeCompiler::genObjectBody(QDeclarativeParser::Object *obj)
QDeclarativeInstruction ss;
ss.type = QDeclarativeInstruction::StoreScriptString;
ss.storeScriptString.propertyIndex = prop.first->index;
- ss.storeScriptString.value =
+ ss.storeScriptString.value =
output->indexForString(prop.first->values.at(0)->value.asScript());
ss.storeScriptString.scope = prop.second;
output->bytecode << ss;
@@ -1132,7 +1132,7 @@ void QDeclarativeCompiler::genObjectBody(QDeclarativeParser::Object *obj)
}
foreach(Property *prop, obj->valueProperties) {
- if (prop->isDeferred)
+ if (prop->isDeferred)
continue;
if (prop->isAlias)
genValueProperty(prop, obj);
@@ -1245,12 +1245,12 @@ bool QDeclarativeCompiler::buildComponent(QDeclarativeParser::Object *obj,
if (obj->properties.count() > 1 ||
(obj->properties.count() == 1 && obj->properties.begin().key() != "id"))
COMPILE_EXCEPTION(*obj->properties.begin(), tr("Component elements may not contain properties other than id"));
-
+
if (obj->properties.count())
idProp = *obj->properties.begin();
if (idProp) {
- if (idProp->value || idProp->values.count() > 1 || idProp->values.at(0)->object)
+ if (idProp->value || idProp->values.count() > 1 || idProp->values.at(0)->object)
COMPILE_EXCEPTION(idProp, tr("Invalid component id specification"));
COMPILE_CHECK(checkValidId(idProp->values.first(), idProp->values.first()->primitive()))
@@ -1456,9 +1456,9 @@ bool QDeclarativeCompiler::buildProperty(QDeclarativeParser::Property *prop,
unit->imports().resolveType(prop->name, &type, 0, 0, 0, &typeNamespace);
if (typeNamespace) {
- // ### We might need to indicate that this property is a namespace
+ // ### We might need to indicate that this property is a namespace
// for the DOM API
- COMPILE_CHECK(buildPropertyInNamespace(typeNamespace, prop, obj,
+ COMPILE_CHECK(buildPropertyInNamespace(typeNamespace, prop, obj,
ctxt));
return true;
} else if (!type || !type->attachedPropertiesType()) {
@@ -1509,22 +1509,22 @@ bool QDeclarativeCompiler::buildProperty(QDeclarativeParser::Property *prop,
// We can't error here as the "id" property does not require a
// successful index resolution
- if (p.name())
+ if (p.name())
prop->type = p.userType();
// Check if this is an alias
- if (prop->index != -1 &&
- prop->parent &&
- prop->parent->type != -1 &&
+ if (prop->index != -1 &&
+ prop->parent &&
+ prop->parent->type != -1 &&
output->types.at(prop->parent->type).component) {
QDeclarativePropertyCache *cache = output->types.at(prop->parent->type).component->rootPropertyCache;
- if (cache && cache->property(prop->index) &&
+ if (cache && cache->property(prop->index) &&
cache->property(prop->index)->flags & QDeclarativePropertyCache::Data::IsAlias)
prop->isAlias = true;
}
- if (prop->index != -1 && !prop->values.isEmpty())
+ if (prop->index != -1 && !prop->values.isEmpty())
prop->parent->setBindingBit(prop->index);
}
@@ -1572,8 +1572,8 @@ bool QDeclarativeCompiler::buildProperty(QDeclarativeParser::Property *prop,
}
bool QDeclarativeCompiler::buildPropertyInNamespace(QDeclarativeImportedNamespace *ns,
- QDeclarativeParser::Property *nsProp,
- QDeclarativeParser::Object *obj,
+ QDeclarativeParser::Property *nsProp,
+ QDeclarativeParser::Object *obj,
const BindingContext &ctxt)
{
if (!nsProp->value)
@@ -1589,7 +1589,7 @@ bool QDeclarativeCompiler::buildPropertyInNamespace(QDeclarativeImportedNamespac
QDeclarativeType *type = 0;
unit->imports().resolveType(ns, prop->name, &type, 0, 0, 0);
- if (!type || !type->attachedPropertiesType())
+ if (!type || !type->attachedPropertiesType())
COMPILE_EXCEPTION(prop, tr("Non-existent attached object"));
if (!prop->value)
@@ -1880,7 +1880,7 @@ bool QDeclarativeCompiler::buildGroupedProperty(QDeclarativeParser::Property *pr
if (!prop->value->metatype)
COMPILE_EXCEPTION(prop, tr("Invalid grouped property access"));
- if (prop->values.count())
+ if (prop->values.count())
COMPILE_EXCEPTION(prop->values.at(0), tr( "Cannot assign a value directly to a grouped property"));
obj->addGroupedProperty(prop);
@@ -1949,7 +1949,7 @@ bool QDeclarativeCompiler::buildValueTypeProperty(QObject *type,
QDeclarativeParser::Value *v = prop->onValues.at(ii);
Q_ASSERT(v->object);
- COMPILE_CHECK(buildPropertyOnAssignment(prop, obj, baseObj, v, ctxt));
+ COMPILE_CHECK(buildPropertyOnAssignment(prop, obj, baseObj, v, ctxt));
}
obj->addValueProperty(prop);
@@ -1959,7 +1959,7 @@ bool QDeclarativeCompiler::buildValueTypeProperty(QObject *type,
}
// Build assignments to QML lists. QML lists are properties of type
-// QDeclarativeListProperty<T>. List properties can accept a list of
+// QDeclarativeListProperty<T>. List properties can accept a list of
// objects, or a single binding.
bool QDeclarativeCompiler::buildListProperty(QDeclarativeParser::Property *prop,
QDeclarativeParser::Object *obj,
@@ -2009,7 +2009,7 @@ bool QDeclarativeCompiler::buildScriptStringProperty(QDeclarativeParser::Propert
QDeclarativeParser::Object *obj,
const BindingContext &ctxt)
{
- if (prop->values.count() > 1)
+ if (prop->values.count() > 1)
COMPILE_EXCEPTION(prop->values.at(1), tr( "Cannot assign multiple values to a script property"));
if (prop->values.at(0)->object)
@@ -2302,7 +2302,7 @@ int QDeclarativeCompiler::evaluateEnum(const QByteArray& script) const
const QMetaObject *QDeclarativeCompiler::resolveType(const QByteArray& name) const
{
QDeclarativeType *qmltype = 0;
- if (!unit->imports().resolveType(name, &qmltype, 0, 0, 0, 0))
+ if (!unit->imports().resolveType(name, &qmltype, 0, 0, 0, 0))
return 0;
if (!qmltype)
return 0;
@@ -2409,7 +2409,7 @@ bool QDeclarativeCompiler::mergeDynamicMetaProperties(QDeclarativeParser::Object
property = obj->getDefaultProperty();
} else {
property = obj->getProperty(p.name);
- if (!property->values.isEmpty())
+ if (!property->values.isEmpty())
COMPILE_EXCEPTION(property, tr("Property value set multiple times"));
}
@@ -2488,7 +2488,7 @@ bool QDeclarativeCompiler::buildDynamicMeta(QDeclarativeParser::Object *obj, Dyn
QByteArray customTypeName;
QDeclarativeType *qmltype = 0;
QUrl url;
- if (!unit->imports().resolveType(p.customType, &qmltype, &url, 0, 0, 0))
+ if (!unit->imports().resolveType(p.customType, &qmltype, &url, 0, 0, 0))
COMPILE_EXCEPTION(&p, tr("Invalid property type"));
if (!qmltype) {
@@ -2563,7 +2563,7 @@ bool QDeclarativeCompiler::buildDynamicMeta(QDeclarativeParser::Object *obj, Dyn
dynamicData.append((char *)&propertyData, sizeof(propertyData));
builder.addSignal(p.name + "Changed()");
- QMetaPropertyBuilder propBuilder =
+ QMetaPropertyBuilder propBuilder =
builder.addProperty(p.name, type, builder.methodCount() - 1);
propBuilder.setWritable(!readonly);
}
@@ -2604,7 +2604,7 @@ bool QDeclarativeCompiler::buildDynamicMeta(QDeclarativeParser::Object *obj, Dyn
QString funcScript(QStringLiteral("(function ") + QLatin1String(s.name) + QLatin1Char('('));
for (int jj = 0; jj < s.parameterNames.count(); ++jj) {
- if (jj) {
+ if (jj) {
sig.append(',');
funcScript.append(QLatin1Char(','));
}
@@ -2655,7 +2655,7 @@ bool QDeclarativeCompiler::buildDynamicMeta(QDeclarativeParser::Object *obj, Dyn
if (obj->type != -1) {
QDeclarativePropertyCache *cache = output->types[obj->type].createPropertyCache(engine)->copy();
cache->append(engine, &obj->extObject, QDeclarativePropertyCache::Data::NoFlags,
- QDeclarativePropertyCache::Data::IsVMEFunction,
+ QDeclarativePropertyCache::Data::IsVMEFunction,
QDeclarativePropertyCache::Data::IsVMESignal);
obj->synthCache = cache;
}
@@ -2665,10 +2665,10 @@ bool QDeclarativeCompiler::buildDynamicMeta(QDeclarativeParser::Object *obj, Dyn
bool QDeclarativeCompiler::checkValidId(QDeclarativeParser::Value *v, const QString &val)
{
- if (val.isEmpty())
+ if (val.isEmpty())
COMPILE_EXCEPTION(v, tr( "Invalid empty ID"));
- if (val.at(0).isLetter() && !val.at(0).isLower())
+ if (val.at(0).isLetter() && !val.at(0).isLower())
COMPILE_EXCEPTION(v, tr( "IDs cannot start with an uppercase letter"));
QChar u(QLatin1Char('_'));
@@ -2766,12 +2766,12 @@ bool QDeclarativeCompiler::compileAlias(QMetaObjectBuilder &builder,
if (valueTypeIndex == -1)
COMPILE_EXCEPTION(prop.defaultValue, tr("Invalid alias location"));
Q_ASSERT(valueTypeIndex <= 0xFF);
-
+
aliasProperty = valueType->metaObject()->property(valueTypeIndex);
propIdx |= (valueTypeIndex << 16);
}
- if (aliasProperty.isEnumType())
+ if (aliasProperty.isEnumType())
typeName = "int"; // Avoid introducing a dependency on the aliased metaobject
else
typeName = aliasProperty.typeName();
@@ -2803,7 +2803,7 @@ bool QDeclarativeCompiler::compileAlias(QMetaObjectBuilder &builder,
data.append((const char *)&flags, sizeof(flags));
builder.addSignal(prop.name + "Changed()");
- QMetaPropertyBuilder propBuilder =
+ QMetaPropertyBuilder propBuilder =
builder.addProperty(prop.name, typeName.constData(), builder.methodCount() - 1);
propBuilder.setWritable(writable);
return true;
@@ -2846,11 +2846,11 @@ void QDeclarativeCompiler::genBindingAssignment(QDeclarativeParser::Value *bindi
store.assignBinding.value = ref.compiledIndex;
store.assignBinding.context = ref.bindingContext.stack;
store.assignBinding.owner = ref.bindingContext.owner;
- if (valueTypeProperty)
+ if (valueTypeProperty)
store.assignBinding.property = (valueTypeProperty->index & 0xFFFF) |
((valueTypeProperty->type & 0xFF)) << 16 |
((prop->index & 0xFF) << 24);
- else
+ else
store.assignBinding.property = prop->index;
store.line = binding->location.start.line;
output->bytecode << store;
@@ -2887,19 +2887,19 @@ int QDeclarativeCompiler::genContextCache()
for (QHash<QString, QDeclarativeParser::Object *>::ConstIterator iter = compileState.ids.begin();
iter != compileState.ids.end();
- ++iter)
+ ++iter)
cache->add(iter.key(), (*iter)->idIndex);
output->contextCaches.append(cache);
return output->contextCaches.count() - 1;
}
-int QDeclarativeCompiler::genValueTypeData(QDeclarativeParser::Property *valueTypeProp,
+int QDeclarativeCompiler::genValueTypeData(QDeclarativeParser::Property *valueTypeProp,
QDeclarativeParser::Property *prop)
{
QByteArray data =
- QDeclarativePropertyPrivate::saveValueType(prop->parent->metaObject(), prop->index,
- enginePrivate->valueTypes[prop->type]->metaObject(),
+ QDeclarativePropertyPrivate::saveValueType(prop->parent->metaObject(), prop->index,
+ enginePrivate->valueTypes[prop->type]->metaObject(),
valueTypeProp->index);
// valueTypeProp->index, valueTypeProp->type);
@@ -2926,7 +2926,7 @@ bool QDeclarativeCompiler::completeComponentBuild()
QDeclarativeBindingCompiler bindingCompiler;
- for (QHash<QDeclarativeParser::Value*,BindingReference>::Iterator iter = compileState.bindings.begin();
+ for (QHash<QDeclarativeParser::Value*,BindingReference>::Iterator iter = compileState.bindings.begin();
iter != compileState.bindings.end(); ++iter) {
BindingReference &binding = *iter;
@@ -2936,7 +2936,7 @@ bool QDeclarativeCompiler::completeComponentBuild()
expr.expression = binding.expression;
expr.imports = unit->imports();
- // ### We don't currently optimize for bindings on alias's - because
+ // ### We don't currently optimize for bindings on alias's - because
// of the solution to QTBUG-13719
if (!binding.property->isAlias) {
int index = bindingCompiler.compile(expr, enginePrivate);
@@ -2945,7 +2945,7 @@ bool QDeclarativeCompiler::completeComponentBuild()
binding.compiledIndex = index;
componentStat.optimizedBindings.append(iter.key()->location);
continue;
- }
+ }
}
binding.dataType = BindingReference::QtScript;
@@ -2959,8 +2959,8 @@ bool QDeclarativeCompiler::completeComponentBuild()
expression = rewriteBinding(binding.expression.asAST(), expression, &isSharable);
quint32 length = expression.length();
- quint32 pc;
-
+ quint32 pc;
+
if (isSharable) {
pc = output->cachedClosures.count();
pc |= 0x80000000;
@@ -2973,7 +2973,7 @@ bool QDeclarativeCompiler::completeComponentBuild()
binding.compiledData =
QByteArray((const char *)&pc, sizeof(quint32)) +
QByteArray((const char *)&length, sizeof(quint32)) +
- QByteArray((const char *)expression.constData(),
+ QByteArray((const char *)expression.constData(),
expression.length() * sizeof(QChar));
componentStat.scriptBindings.append(iter.key()->location);
@@ -2981,7 +2981,7 @@ bool QDeclarativeCompiler::completeComponentBuild()
if (bindingCompiler.isValid()) {
compileState.compiledBindingData = bindingCompiler.program();
- if (bindingsDump())
+ if (bindingsDump())
QDeclarativeBindingCompiler::dump(compileState.compiledBindingData);
}
@@ -3045,7 +3045,7 @@ void QDeclarativeCompiler::dumpStats()
*/
bool QDeclarativeCompiler::canCoerce(int to, QDeclarativeParser::Object *from)
{
- const QMetaObject *toMo =
+ const QMetaObject *toMo =
enginePrivate->rawMetaObjectForType(to);
const QMetaObject *fromMo = from->metaObject();
@@ -3083,7 +3083,7 @@ QStringList QDeclarativeCompiler::deferredProperties(QDeclarativeParser::Object
}
// This code must match the semantics of QDeclarativePropertyPrivate::findSignalByName
-int QDeclarativeCompiler::indexOfSignal(QDeclarativeParser::Object *object, const QByteArray &name,
+int QDeclarativeCompiler::indexOfSignal(QDeclarativeParser::Object *object, const QByteArray &name,
bool *notInRevision)
{
if (notInRevision) *notInRevision = false;
@@ -3091,7 +3091,7 @@ int QDeclarativeCompiler::indexOfSignal(QDeclarativeParser::Object *object, cons
if (object->synthCache || (object->type != -1 && output->types.at(object->type).propertyCache())) {
// XXX fromUtf8
QString strName(QString::fromUtf8(name));
- QDeclarativePropertyCache *cache =
+ QDeclarativePropertyCache *cache =
object->synthCache?object->synthCache:output->types.at(object->type).propertyCache();
QDeclarativePropertyCache::Data *d = cache->property(strName);
@@ -3124,7 +3124,7 @@ int QDeclarativeCompiler::indexOfSignal(QDeclarativeParser::Object *object, cons
}
-int QDeclarativeCompiler::indexOfProperty(QDeclarativeParser::Object *object, const QByteArray &name,
+int QDeclarativeCompiler::indexOfProperty(QDeclarativeParser::Object *object, const QByteArray &name,
bool *notInRevision)
{
if (notInRevision) *notInRevision = false;
@@ -3132,12 +3132,12 @@ int QDeclarativeCompiler::indexOfProperty(QDeclarativeParser::Object *object, co
if (object->synthCache || (object->type != -1 && output->types.at(object->type).propertyCache())) {
// XXX fromUtf8
QString strName(QString::fromUtf8(name));
- QDeclarativePropertyCache *cache =
+ QDeclarativePropertyCache *cache =
object->synthCache?object->synthCache:output->types.at(object->type).propertyCache();
QDeclarativePropertyCache::Data *d = cache->property(strName);
// Find the first property
- while (d && d->flags & QDeclarativePropertyCache::Data::IsFunction)
+ while (d && d->flags & QDeclarativePropertyCache::Data::IsFunction)
d = cache->overrideData(d);
if (d && !cache->isAllowedInRevision(d)) {
diff --git a/src/declarative/qml/qdeclarativecompiler_p.h b/src/declarative/qml/qdeclarativecompiler_p.h
index 1b6dbf35..a47674bc 100644
--- a/src/declarative/qml/qdeclarativecompiler_p.h
+++ b/src/declarative/qml/qdeclarativecompiler_p.h
@@ -86,7 +86,7 @@ public:
QUrl url;
QDeclarativeTypeNameCache *importCache;
- struct TypeReference
+ struct TypeReference
{
TypeReference()
: type(0), typePropertyCache(0), component(0) {}
@@ -191,23 +191,23 @@ private:
bool buildObject(QDeclarativeParser::Object *obj, const BindingContext &);
bool buildComponent(QDeclarativeParser::Object *obj, const BindingContext &);
bool buildSubObject(QDeclarativeParser::Object *obj, const BindingContext &);
- bool buildSignal(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj,
+ bool buildSignal(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj,
const BindingContext &);
- bool buildProperty(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj,
+ bool buildProperty(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj,
const BindingContext &);
bool buildPropertyInNamespace(QDeclarativeImportedNamespace *ns,
- QDeclarativeParser::Property *prop,
- QDeclarativeParser::Object *obj,
+ QDeclarativeParser::Property *prop,
+ QDeclarativeParser::Object *obj,
const BindingContext &);
bool buildIdProperty(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj);
- bool buildAttachedProperty(QDeclarativeParser::Property *prop,
+ bool buildAttachedProperty(QDeclarativeParser::Property *prop,
QDeclarativeParser::Object *obj,
const BindingContext &ctxt);
bool buildGroupedProperty(QDeclarativeParser::Property *prop,
QDeclarativeParser::Object *obj,
const BindingContext &ctxt);
- bool buildValueTypeProperty(QObject *type,
- QDeclarativeParser::Object *obj,
+ bool buildValueTypeProperty(QObject *type,
+ QDeclarativeParser::Object *obj,
QDeclarativeParser::Object *baseObj,
const BindingContext &ctxt);
bool buildListProperty(QDeclarativeParser::Property *prop,
@@ -233,7 +233,7 @@ private:
QDeclarativeParser::Value *value,
const BindingContext &ctxt);
bool doesPropertyExist(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj);
- bool testLiteralAssignment(const QMetaProperty &prop,
+ bool testLiteralAssignment(const QMetaProperty &prop,
QDeclarativeParser::Value *value);
bool testQualifiedEnumAssignment(const QMetaProperty &prop,
QDeclarativeParser::Object *obj,
@@ -246,9 +246,9 @@ private:
bool buildBinding(QDeclarativeParser::Value *, QDeclarativeParser::Property *prop,
const BindingContext &ctxt);
bool buildComponentFromRoot(QDeclarativeParser::Object *obj, const BindingContext &);
- bool compileAlias(QMetaObjectBuilder &,
+ bool compileAlias(QMetaObjectBuilder &,
QByteArray &data,
- QDeclarativeParser::Object *obj,
+ QDeclarativeParser::Object *obj,
const QDeclarativeParser::Object::DynamicProperty &);
bool completeComponentBuild();
bool checkValidId(QDeclarativeParser::Value *, const QString &);
@@ -260,13 +260,13 @@ private:
void genComponent(QDeclarativeParser::Object *obj);
void genValueProperty(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj);
void genListProperty(QDeclarativeParser::Property *prop, QDeclarativeParser::Object *obj);
- void genPropertyAssignment(QDeclarativeParser::Property *prop,
+ void genPropertyAssignment(QDeclarativeParser::Property *prop,
QDeclarativeParser::Object *obj,
QDeclarativeParser::Property *valueTypeProperty = 0);
- void genLiteralAssignment(const QMetaProperty &prop,
+ void genLiteralAssignment(const QMetaProperty &prop,
QDeclarativeParser::Value *value);
- void genBindingAssignment(QDeclarativeParser::Value *binding,
- QDeclarativeParser::Property *prop,
+ void genBindingAssignment(QDeclarativeParser::Value *binding,
+ QDeclarativeParser::Property *prop,
QDeclarativeParser::Object *obj,
QDeclarativeParser::Property *valueTypeProperty = 0);
int genContextCache();
@@ -304,7 +304,7 @@ private:
struct ComponentCompileState
{
- ComponentCompileState()
+ ComponentCompileState()
: parserStatusCount(0), pushedProperties(0), root(0) {}
QHash<QString, QDeclarativeParser::Object *> ids;
QHash<int, QDeclarativeParser::Object *> idIndexes;
diff --git a/src/declarative/qml/qdeclarativecomponent.cpp b/src/declarative/qml/qdeclarativecomponent.cpp
index f2596cc1..aebf912b 100644
--- a/src/declarative/qml/qdeclarativecomponent.cpp
+++ b/src/declarative/qml/qdeclarativecomponent.cpp
@@ -160,7 +160,7 @@ class QByteArray;
\snippet doc/src/snippets/declarative/component.qml 0
- Notice that while a \l Rectangle by itself would be automatically
+ Notice that while a \l Rectangle by itself would be automatically
rendered and displayed, this is not the case for the above rectangle
because it is defined inside a \c Component. The component encapsulates the
QML elements within, as if they were defined in a separate QML
@@ -230,7 +230,7 @@ class QByteArray;
/*!
\enum QDeclarativeComponent::Status
-
+
Specifies the loading status of the QDeclarativeComponent.
\value Null This QDeclarativeComponent has no data. Call loadUrl() or setData() to add QML content.
@@ -282,8 +282,8 @@ void QDeclarativeComponentPrivate::clear()
typeData->release();
typeData = 0;
}
-
- if (cc) {
+
+ if (cc) {
cc->release();
cc = 0;
}
@@ -439,12 +439,12 @@ QDeclarativeComponent::QDeclarativeComponent(QDeclarativeEngine *engine, const Q
}
/*!
- Create a QDeclarativeComponent from the given \a fileName and give it the specified
+ Create a QDeclarativeComponent from the given \a fileName and give it the specified
\a parent and \a engine.
\sa loadUrl()
*/
-QDeclarativeComponent::QDeclarativeComponent(QDeclarativeEngine *engine, const QString &fileName,
+QDeclarativeComponent::QDeclarativeComponent(QDeclarativeEngine *engine, const QString &fileName,
QObject *parent)
: QObject(*(new QDeclarativeComponentPrivate), parent)
{
@@ -483,7 +483,7 @@ void QDeclarativeComponent::setData(const QByteArray &data, const QUrl &url)
d->url = url;
QDeclarativeTypeData *typeData = QDeclarativeEnginePrivate::get(d->engine)->typeLoader.get(data, url);
-
+
if (typeData->isCompleteOrError()) {
d->fromTypeData(typeData);
} else {
@@ -627,8 +627,8 @@ QDeclarativeComponent::QDeclarativeComponent(QDeclarativeComponentPrivate &dd, Q
which were not created in QML.
If you wish to create an object without setting a parent, specify \c null for
- the \a parent value. Note that if the returned object is to be displayed, you
- must provide a valid \a parent value or set the returned object's \l{Item::parent}{parent}
+ the \a parent value. Note that if the returned object is to be displayed, you
+ must provide a valid \a parent value or set the returned object's \l{Item::parent}{parent}
property, or else the object will not be visible.
If a \a parent is not provided to createObject(), a reference to the returned object must be held so that
@@ -753,7 +753,7 @@ QScriptValue QDeclarativeComponentPrivate::createObject(QObject *publicParent, c
/*!
Create an object instance from this component. Returns 0 if creation
failed. \a context specifies the context within which to create the object
- instance.
+ instance.
If \a context is 0 (the default), it will create the instance in the
engine' s \l {QDeclarativeEngine::rootContext()}{root context}.
@@ -772,21 +772,21 @@ QObject *QDeclarativeComponent::create(QDeclarativeContext *context)
/*!
This method provides more advanced control over component instance creation.
- In general, programmers should use QDeclarativeComponent::create() to create a
+ In general, programmers should use QDeclarativeComponent::create() to create a
component.
Create an object instance from this component. Returns 0 if creation
failed. \a context specifies the context within which to create the object
- instance.
+ instance.
When QDeclarativeComponent constructs an instance, it occurs in three steps:
\list 1
\li The object hierarchy is created, and constant values are assigned.
\li Property bindings are evaluated for the the first time.
\li If applicable, QDeclarativeParserStatus::componentComplete() is called on objects.
- \endlist
+ \endlist
QDeclarativeComponent::beginCreate() differs from QDeclarativeComponent::create() in that it
- only performs step 1. QDeclarativeComponent::completeCreate() must be called to
+ only performs step 1. QDeclarativeComponent::completeCreate() must be called to
complete steps 2 and 3.
This breaking point is sometimes useful when using attached properties to
@@ -837,7 +837,7 @@ QDeclarativeComponentPrivate::beginCreate(QDeclarativeContextData *context, cons
return begin(context, creationContext, cc, start, count, &state, 0, bindings);
}
-QObject * QDeclarativeComponentPrivate::begin(QDeclarativeContextData *parentContext,
+QObject * QDeclarativeComponentPrivate::begin(QDeclarativeContextData *parentContext,
QDeclarativeContextData *componentCreationContext,
QDeclarativeCompiledData *component, int start, int count,
ConstructionState *state, QList<QDeclarativeError> *errors,
@@ -860,7 +860,7 @@ QObject * QDeclarativeComponentPrivate::begin(QDeclarativeContextData *parentCon
ctxt->imports = component->importCache;
// Nested global imports
- if (componentCreationContext && start != -1)
+ if (componentCreationContext && start != -1)
ctxt->importedScripts = componentCreationContext->importedScripts;
component->importCache->addref();
@@ -912,7 +912,7 @@ void QDeclarativeComponentPrivate::beginDeferred(QDeclarativeEnginePrivate *engi
QDeclarativeVME vme;
vme.runDeferred(object);
- if (vme.isError())
+ if (vme.isError())
state->errors = vme.errors();
if (isRoot) {
@@ -939,13 +939,13 @@ void QDeclarativeComponentPrivate::complete(QDeclarativeEnginePrivate *enginePri
if (state->completePending) {
QT_TRY {
for (int ii = 0; ii < state->bindValues.count(); ++ii) {
- QDeclarativeEnginePrivate::SimpleList<QDeclarativeAbstractBinding> bv =
+ QDeclarativeEnginePrivate::SimpleList<QDeclarativeAbstractBinding> bv =
state->bindValues.at(ii);
for (int jj = 0; jj < bv.count; ++jj) {
if(bv.at(jj)) {
// XXX akennedy
bv.at(jj)->m_mePtr = 0;
- bv.at(jj)->setEnabled(true, QDeclarativePropertyPrivate::BypassInterceptor |
+ bv.at(jj)->setEnabled(true, QDeclarativePropertyPrivate::BypassInterceptor |
QDeclarativePropertyPrivate::DontRemoveBinding);
}
}
@@ -953,7 +953,7 @@ void QDeclarativeComponentPrivate::complete(QDeclarativeEnginePrivate *enginePri
}
for (int ii = 0; ii < state->parserStatus.count(); ++ii) {
- QDeclarativeEnginePrivate::SimpleList<QDeclarativeParserStatus> ps =
+ QDeclarativeEnginePrivate::SimpleList<QDeclarativeParserStatus> ps =
state->parserStatus.at(ii);
for (int jj = ps.count - 1; jj >= 0; --jj) {
@@ -1026,7 +1026,7 @@ void QDeclarativeComponentPrivate::complete(QDeclarativeEnginePrivate *enginePri
/*!
This method provides more advanced control over component instance creation.
- In general, programmers should use QDeclarativeComponent::create() to create a
+ In general, programmers should use QDeclarativeComponent::create() to create a
component.
Complete a component creation begin with QDeclarativeComponent::beginCreate().
diff --git a/src/declarative/qml/qdeclarativecomponent_p.h b/src/declarative/qml/qdeclarativecomponent_p.h
index 4d4551b9..f51810c3 100644
--- a/src/declarative/qml/qdeclarativecomponent_p.h
+++ b/src/declarative/qml/qdeclarativecomponent_p.h
@@ -77,7 +77,7 @@ class QDeclarativeComponentAttached;
class Q_AUTOTEST_EXPORT QDeclarativeComponentPrivate : public QObjectPrivate, public QDeclarativeTypeData::TypeDataCallback
{
Q_DECLARE_PUBLIC(QDeclarativeComponent)
-
+
public:
QDeclarativeComponentPrivate() : typeData(0), progress(0.), start(-1), count(-1), cc(0), engine(0), creationContext(0) {}
@@ -87,7 +87,7 @@ public:
QDeclarativeTypeData *typeData;
virtual void typeDataReady(QDeclarativeTypeData *);
virtual void typeDataProgress(QDeclarativeTypeData *, qreal);
-
+
void fromTypeData(QDeclarativeTypeData *data);
QUrl url;
@@ -109,10 +109,10 @@ public:
ConstructionState state;
static QObject *begin(QDeclarativeContextData *parentContext, QDeclarativeContextData *componentCreationContext,
- QDeclarativeCompiledData *component, int start, int count,
- ConstructionState *state, QList<QDeclarativeError> *errors,
+ QDeclarativeCompiledData *component, int start, int count,
+ ConstructionState *state, QList<QDeclarativeError> *errors,
const QBitField &bindings = QBitField());
- static void beginDeferred(QDeclarativeEnginePrivate *enginePriv, QObject *object,
+ static void beginDeferred(QDeclarativeEnginePrivate *enginePriv, QObject *object,
ConstructionState *state);
static void complete(QDeclarativeEnginePrivate *enginePriv, ConstructionState *state);
diff --git a/src/declarative/qml/qdeclarativecontext_p.h b/src/declarative/qml/qdeclarativecontext_p.h
index b485f454..89672f74 100644
--- a/src/declarative/qml/qdeclarativecontext_p.h
+++ b/src/declarative/qml/qdeclarativecontext_p.h
@@ -131,7 +131,7 @@ public:
QUrl resolvedUrl(const QUrl &);
- // My containing QDeclarativeContext. If isInternal is true this owns publicContext.
+ // My containing QDeclarativeContext. If isInternal is true this owns publicContext.
// If internal is false publicContext owns this.
QDeclarativeContext *asQDeclarativeContext();
QDeclarativeContextPrivate *asQDeclarativeContextPrivate();
@@ -176,8 +176,8 @@ public:
ContextGuard() : context(0) {}
inline ContextGuard &operator=(QObject *obj)
{ QDeclarativeGuard<QObject>::operator=(obj); return *this; }
- virtual void objectDestroyed(QObject *) {
- if (context->contextObject && !QObjectPrivate::get(context->contextObject)->wasDeleted) bindings.notify();
+ virtual void objectDestroyed(QObject *) {
+ if (context->contextObject && !QObjectPrivate::get(context->contextObject)->wasDeleted) bindings.notify();
}
QDeclarativeContextData *context;
QDeclarativeNotifier bindings;
diff --git a/src/declarative/qml/qdeclarativecontextscriptclass.cpp b/src/declarative/qml/qdeclarativecontextscriptclass.cpp
index d17b960a..899622ad 100644
--- a/src/declarative/qml/qdeclarativecontextscriptclass.cpp
+++ b/src/declarative/qml/qdeclarativecontextscriptclass.cpp
@@ -51,7 +51,7 @@ QT_BEGIN_NAMESPACE
struct ContextData : public QScriptDeclarativeClass::Object {
ContextData() : overrideObject(0), isSharedContext(true) {}
- ContextData(QDeclarativeContextData *c, QObject *o)
+ ContextData(QDeclarativeContextData *c, QObject *o)
: context(c), scopeObject(o), overrideObject(0), isSharedContext(false), isUrlContext(false) {}
QDeclarativeGuardedContextData context;
QDeclarativeGuard<QObject> scopeObject;
@@ -77,11 +77,11 @@ struct ContextData : public QScriptDeclarativeClass::Object {
};
struct UrlContextData : public ContextData {
- UrlContextData(QDeclarativeContextData *c, QObject *o, const QString &u)
+ UrlContextData(QDeclarativeContextData *c, QObject *o, const QString &u)
: ContextData(c, o), url(u) {
isUrlContext = true;
}
- UrlContextData(const QString &u)
+ UrlContextData(const QString &u)
: ContextData(0, 0), url(u) {
isUrlContext = true;
}
@@ -109,7 +109,7 @@ QScriptValue QDeclarativeContextScriptClass::newContext(QDeclarativeContextData
return newObject(scriptEngine, this, new ContextData(context, scopeObject));
}
-QScriptValue QDeclarativeContextScriptClass::newUrlContext(QDeclarativeContextData *context, QObject *scopeObject,
+QScriptValue QDeclarativeContextScriptClass::newUrlContext(QDeclarativeContextData *context, QObject *scopeObject,
const QString &url)
{
QScriptEngine *scriptEngine = QDeclarativeEnginePrivate::getScriptEngine(engine);
@@ -164,12 +164,12 @@ QObject *QDeclarativeContextScriptClass::setOverrideObject(QScriptValue &v, QObj
return rv;
}
-QScriptClass::QueryFlags
-QDeclarativeContextScriptClass::queryProperty(Object *object, const Identifier &name,
+QScriptClass::QueryFlags
+QDeclarativeContextScriptClass::queryProperty(Object *object, const Identifier &name,
QScriptClass::QueryFlags flags)
{
Q_UNUSED(flags);
-
+
lastScopeObject = 0;
lastContext = 0;
lastData = 0;
@@ -183,9 +183,9 @@ QDeclarativeContextScriptClass::queryProperty(Object *object, const Identifier &
QObject *overrideObject = ((ContextData *)object)->overrideObject;
if (overrideObject) {
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(engine);
- QScriptClass::QueryFlags rv =
- ep->objectClass->queryProperty(overrideObject, name, flags, bindContext,
- QDeclarativeObjectScriptClass::ImplicitObject |
+ QScriptClass::QueryFlags rv =
+ ep->objectClass->queryProperty(overrideObject, name, flags, bindContext,
+ QDeclarativeObjectScriptClass::ImplicitObject |
QDeclarativeObjectScriptClass::SkipAttachedProperties);
if (rv) {
lastScopeObject = overrideObject;
@@ -196,7 +196,7 @@ QDeclarativeContextScriptClass::queryProperty(Object *object, const Identifier &
bool includeTypes = true;
while (bindContext) {
- QScriptClass::QueryFlags rv =
+ QScriptClass::QueryFlags rv =
queryProperty(bindContext, scopeObject, name, flags, includeTypes);
scopeObject = 0; // Only applies to the first context
includeTypes = false; // Only applies to the first context
@@ -207,10 +207,10 @@ QDeclarativeContextScriptClass::queryProperty(Object *object, const Identifier &
return 0;
}
-QScriptClass::QueryFlags
+QScriptClass::QueryFlags
QDeclarativeContextScriptClass::queryProperty(QDeclarativeContextData *bindContext, QObject *scopeObject,
const Identifier &name,
- QScriptClass::QueryFlags flags,
+ QScriptClass::QueryFlags flags,
bool includeTypes)
{
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(engine);
@@ -221,7 +221,7 @@ QDeclarativeContextScriptClass::queryProperty(QDeclarativeContextData *bindConte
return QScriptClass::HandlesReadAccess;
}
- if (includeTypes && bindContext->imports) {
+ if (includeTypes && bindContext->imports) {
QDeclarativeTypeNameCache::Data *data = bindContext->imports->data(name);
if (data) {
@@ -233,8 +233,8 @@ QDeclarativeContextScriptClass::queryProperty(QDeclarativeContextData *bindConte
}
if (scopeObject) {
- QScriptClass::QueryFlags rv =
- ep->objectClass->queryProperty(scopeObject, name, flags, bindContext,
+ QScriptClass::QueryFlags rv =
+ ep->objectClass->queryProperty(scopeObject, name, flags, bindContext,
QDeclarativeObjectScriptClass::ImplicitObject | QDeclarativeObjectScriptClass::SkipAttachedProperties);
if (rv) {
lastScopeObject = scopeObject;
@@ -244,8 +244,8 @@ QDeclarativeContextScriptClass::queryProperty(QDeclarativeContextData *bindConte
}
if (bindContext->contextObject) {
- QScriptClass::QueryFlags rv =
- ep->objectClass->queryProperty(bindContext->contextObject, name, flags, bindContext,
+ QScriptClass::QueryFlags rv =
+ ep->objectClass->queryProperty(bindContext->contextObject, name, flags, bindContext,
QDeclarativeObjectScriptClass::ImplicitObject | QDeclarativeObjectScriptClass::SkipAttachedProperties);
if (rv) {
@@ -294,7 +294,7 @@ QDeclarativeContextScriptClass::property(Object *object, const Identifier &name)
if (lastPropertyIndex < bindContext->idValueCount) {
rv = ep->objectClass->newQObject(bindContext->idValues[lastPropertyIndex].data());
- if (ep->captureProperties)
+ if (ep->captureProperties)
ep->capturedProperties << QDeclarativeEnginePrivate::CapturedProperty(&bindContext->idValues[lastPropertyIndex].bindings);
} else {
QDeclarativeContextPrivate *cp = bindContext->asQDeclarativeContextPrivate();
@@ -305,7 +305,7 @@ QDeclarativeContextScriptClass::property(Object *object, const Identifier &name)
rv = ep->scriptValueFromVariant(value);
}
- if (ep->captureProperties)
+ if (ep->captureProperties)
ep->capturedProperties << QDeclarativeEnginePrivate::CapturedProperty(bindContext->asQDeclarativeContext(), -1, lastPropertyIndex + cp->notifyIndex);
}
@@ -318,7 +318,7 @@ QDeclarativeContextScriptClass::property(Object *object, const Identifier &name)
}
}
-void QDeclarativeContextScriptClass::setProperty(Object *object, const Identifier &name,
+void QDeclarativeContextScriptClass::setProperty(Object *object, const Identifier &name,
const QScriptValue &value)
{
Q_UNUSED(object);
diff --git a/src/declarative/qml/qdeclarativecontextscriptclass_p.h b/src/declarative/qml/qdeclarativecontextscriptclass_p.h
index 0e2d7cf5..3d49b959 100644
--- a/src/declarative/qml/qdeclarativecontextscriptclass_p.h
+++ b/src/declarative/qml/qdeclarativecontextscriptclass_p.h
@@ -78,13 +78,13 @@ public:
QObject *setOverrideObject(QScriptValue &, QObject *);
protected:
- virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
+ virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
QScriptClass::QueryFlags flags);
virtual Value property(Object *, const Identifier &);
virtual void setProperty(Object *, const Identifier &name, const QScriptValue &);
private:
- QScriptClass::QueryFlags queryProperty(QDeclarativeContextData *, QObject *scopeObject,
+ QScriptClass::QueryFlags queryProperty(QDeclarativeContextData *, QObject *scopeObject,
const Identifier &,
QScriptClass::QueryFlags flags,
bool includeTypes);
diff --git a/src/declarative/qml/qdeclarativecustomparser.cpp b/src/declarative/qml/qdeclarativecustomparser.cpp
index 3568d7ca..037cec7f 100644
--- a/src/declarative/qml/qdeclarativecustomparser.cpp
+++ b/src/declarative/qml/qdeclarativecustomparser.cpp
@@ -94,7 +94,7 @@ using namespace QDeclarativeParser;
The \a object will be an instance of the TypeClass specified by QML_REGISTER_CUSTOM_TYPE.
*/
-QDeclarativeCustomParserNode
+QDeclarativeCustomParserNode
QDeclarativeCustomParserNodePrivate::fromObject(QDeclarativeParser::Object *root)
{
QDeclarativeCustomParserNode rootNode;
@@ -116,7 +116,7 @@ QDeclarativeCustomParserNodePrivate::fromObject(QDeclarativeParser::Object *root
return rootNode;
}
-QDeclarativeCustomParserProperty
+QDeclarativeCustomParserProperty
QDeclarativeCustomParserNodePrivate::fromProperty(QDeclarativeParser::Property *p)
{
QDeclarativeCustomParserProperty prop;
diff --git a/src/declarative/qml/qdeclarativecustomparser_p.h b/src/declarative/qml/qdeclarativecustomparser_p.h
index 415f7889..6a53b188 100644
--- a/src/declarative/qml/qdeclarativecustomparser_p.h
+++ b/src/declarative/qml/qdeclarativecustomparser_p.h
@@ -80,7 +80,7 @@ public:
QDeclarativeParser::Location location() const;
bool isList() const;
- // Will be one of QDeclarativeParser::Variant, QDeclarativeCustomParserProperty or
+ // Will be one of QDeclarativeParser::Variant, QDeclarativeCustomParserProperty or
// QDeclarativeCustomParserNode
QList<QVariant> assignedValues() const;
diff --git a/src/declarative/qml/qdeclarativedata_p.h b/src/declarative/qml/qdeclarativedata_p.h
index b2d7eb90..b9ad7259 100644
--- a/src/declarative/qml/qdeclarativedata_p.h
+++ b/src/declarative/qml/qdeclarativedata_p.h
@@ -75,10 +75,10 @@ class Q_AUTOTEST_EXPORT QDeclarativeData : public QAbstractDeclarativeData
public:
QDeclarativeData()
: ownedByQml1(true), ownMemory(true), ownContext(false), indestructible(true), explicitIndestructibleSet(false),
- context(0), outerContext(0), bindings(0), nextContextObject(0), prevContextObject(0), bindingBitsSize(0),
- bindingBits(0), lineNumber(0), columnNumber(0), deferredComponent(0), deferredIdx(0),
+ context(0), outerContext(0), bindings(0), nextContextObject(0), prevContextObject(0), bindingBitsSize(0),
+ bindingBits(0), lineNumber(0), columnNumber(0), deferredComponent(0), deferredIdx(0),
scriptValue(0), objectDataRefCount(0), propertyCache(0), guards(0), extendedData(0) {
- init();
+ init();
}
static inline void init() {
@@ -101,7 +101,7 @@ public:
quint32 dummy:27;
// The context that created the C++ object
- QDeclarativeContextData *context;
+ QDeclarativeContextData *context;
// The outermost context in which this object lives
QDeclarativeContextData *outerContext;
@@ -112,7 +112,7 @@ public:
QDeclarativeData**prevContextObject;
int bindingBitsSize;
- quint32 *bindingBits;
+ quint32 *bindingBits;
bool hasBindingBit(int) const;
void clearBindingBit(int);
void setBindingBit(QObject *obj, int);
diff --git a/src/declarative/qml/qdeclarativedirparser.cpp b/src/declarative/qml/qdeclarativedirparser.cpp
index 2f112f62..dedd881a 100644
--- a/src/declarative/qml/qdeclarativedirparser.cpp
+++ b/src/declarative/qml/qdeclarativedirparser.cpp
@@ -227,7 +227,7 @@ bool QDeclarativeDirParser::parse()
}
}
} else {
- reportError(lineNumber, -1,
+ reportError(lineNumber, -1,
QString::fromUtf8("a component declaration requires 3 arguments, but %1 were provided").arg(sectionCount + 1));
}
}
diff --git a/src/declarative/qml/qdeclarativedom_p.h b/src/declarative/qml/qdeclarativedom_p.h
index df1cfdc2..9cda7c85 100644
--- a/src/declarative/qml/qdeclarativedom_p.h
+++ b/src/declarative/qml/qdeclarativedom_p.h
@@ -271,14 +271,14 @@ public:
class Q_DECLARATIVE_PRIVATE_EXPORT QDeclarativeDomValue
{
public:
- enum Type {
+ enum Type {
Invalid,
- Literal,
- PropertyBinding,
+ Literal,
+ PropertyBinding,
ValueSource,
ValueInterceptor,
Object,
- List
+ List
};
QDeclarativeDomValue();
diff --git a/src/declarative/qml/qdeclarativedom_p_p.h b/src/declarative/qml/qdeclarativedom_p_p.h
index e1b33a38..a87ac711 100644
--- a/src/declarative/qml/qdeclarativedom_p_p.h
+++ b/src/declarative/qml/qdeclarativedom_p_p.h
@@ -128,7 +128,7 @@ class QDeclarativeDomBasicValuePrivate : public QSharedData
{
public:
QDeclarativeDomBasicValuePrivate();
- QDeclarativeDomBasicValuePrivate(const QDeclarativeDomBasicValuePrivate &o)
+ QDeclarativeDomBasicValuePrivate(const QDeclarativeDomBasicValuePrivate &o)
: QSharedData(o) { qFatal("Not impl"); }
~QDeclarativeDomBasicValuePrivate();
@@ -139,7 +139,7 @@ class QDeclarativeDomImportPrivate : public QSharedData
{
public:
QDeclarativeDomImportPrivate();
- QDeclarativeDomImportPrivate(const QDeclarativeDomImportPrivate &o)
+ QDeclarativeDomImportPrivate(const QDeclarativeDomImportPrivate &o)
: QSharedData(o) { qFatal("Not impl"); }
~QDeclarativeDomImportPrivate();
diff --git a/src/declarative/qml/qdeclarativeengine.cpp b/src/declarative/qml/qdeclarativeengine.cpp
index a42c6a04..612931b2 100644
--- a/src/declarative/qml/qdeclarativeengine.cpp
+++ b/src/declarative/qml/qdeclarativeengine.cpp
@@ -110,7 +110,7 @@
#include <qlibrary.h>
#include <windows.h>
-#define CSIDL_APPDATA 0x001a // <username>\Application Data
+#define CSIDL_APPDATA 0x001a // <username>\Application Data
#endif
Q_DECLARE_METATYPE(QDeclarativeProperty)
diff --git a/src/declarative/qml/qdeclarativeerror.cpp b/src/declarative/qml/qdeclarativeerror.cpp
index 5ec0307d..9a25943a 100644
--- a/src/declarative/qml/qdeclarativeerror.cpp
+++ b/src/declarative/qml/qdeclarativeerror.cpp
@@ -123,7 +123,7 @@ QDeclarativeError &QDeclarativeError::operator=(const QDeclarativeError &other)
}
/*!
- \internal
+ \internal
*/
QDeclarativeError::~QDeclarativeError()
{
@@ -220,7 +220,7 @@ QString QDeclarativeError::toString() const
rv = QLatin1String("<Unknown File>");
} else if (line() != -1) {
rv = url().toString() + QLatin1Char(':') + QString::number(line());
- if(column() != -1)
+ if (column() != -1)
rv += QLatin1Char(':') + QString::number(column());
} else {
rv = url().toString();
@@ -262,7 +262,7 @@ QDebug operator<<(QDebug debug, const QDeclarativeError &error)
if(error.column() > 0) {
int column = qMax(0, error.column() - 1);
- column = qMin(column, line.length());
+ column = qMin(column, line.length());
QByteArray ind;
ind.reserve(column);
diff --git a/src/declarative/qml/qdeclarativeexpression.cpp b/src/declarative/qml/qdeclarativeexpression.cpp
index 7455bd2d..082db7f8 100644
--- a/src/declarative/qml/qdeclarativeexpression.cpp
+++ b/src/declarative/qml/qdeclarativeexpression.cpp
@@ -72,7 +72,7 @@ bool QDeclarativeDelayedError::addError(QDeclarativeEnginePrivate *e)
}
QDeclarativeQtScriptExpression::QDeclarativeQtScriptExpression()
-: dataRef(0), expressionFunctionMode(ExplicitContext), scopeObject(0), trackChange(false),
+: dataRef(0), expressionFunctionMode(ExplicitContext), scopeObject(0), trackChange(false),
guardList(0), guardListLength(0), guardObject(0), guardObjectNotifyIndex(-1), deleted(0)
{
}
@@ -93,7 +93,7 @@ QDeclarativeExpressionPrivate::~QDeclarativeExpressionPrivate()
{
}
-void QDeclarativeExpressionPrivate::init(QDeclarativeContextData *ctxt, const QString &expr,
+void QDeclarativeExpressionPrivate::init(QDeclarativeContextData *ctxt, const QString &expr,
QObject *me)
{
expression = expr;
@@ -116,8 +116,8 @@ void QDeclarativeExpressionPrivate::init(QDeclarativeContextData *ctxt, const QS
expressionFunctionValid = true;
}
-void QDeclarativeExpressionPrivate::init(QDeclarativeContextData *ctxt, void *expr,
- QDeclarativeRefCount *rc,
+void QDeclarativeExpressionPrivate::init(QDeclarativeContextData *ctxt, void *expr,
+ QDeclarativeRefCount *rc,
QObject *me, const QString &srcUrl, int lineNumber)
{
url = srcUrl;
@@ -160,7 +160,7 @@ void QDeclarativeExpressionPrivate::init(QDeclarativeContextData *ctxt, void *ex
dd->cachedPrograms[progIdx] = new QScriptProgram(expression, url, line);
}
- expressionFunction = evalInObjectScope(ctxt, me, *dd->cachedPrograms.at(progIdx),
+ expressionFunction = evalInObjectScope(ctxt, me, *dd->cachedPrograms.at(progIdx),
&expressionContext);
expressionFunctionMode = ExplicitContext;
@@ -171,7 +171,7 @@ void QDeclarativeExpressionPrivate::init(QDeclarativeContextData *ctxt, void *ex
scopeObject = me;
}
-QScriptValue QDeclarativeExpressionPrivate::evalInObjectScope(QDeclarativeContextData *context, QObject *object,
+QScriptValue QDeclarativeExpressionPrivate::evalInObjectScope(QDeclarativeContextData *context, QObject *object,
const QString &program, const QString &fileName,
int lineNumber, QScriptValue *contextObject)
{
@@ -189,8 +189,8 @@ QScriptValue QDeclarativeExpressionPrivate::evalInObjectScope(QDeclarativeContex
return rv;
}
-QScriptValue QDeclarativeExpressionPrivate::evalInObjectScope(QDeclarativeContextData *context, QObject *object,
- const QScriptProgram &program,
+QScriptValue QDeclarativeExpressionPrivate::evalInObjectScope(QDeclarativeContextData *context, QObject *object,
+ const QScriptProgram &program,
QScriptValue *contextObject)
{
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(context->engine);
@@ -248,14 +248,14 @@ QDeclarativeExpression::QDeclarativeExpression()
{
Q_D(QDeclarativeExpression);
- if (QDeclarativeExpression_notifyIdx == -1)
+ if (QDeclarativeExpression_notifyIdx == -1)
QDeclarativeExpression_notifyIdx = QDeclarativeExpression::staticMetaObject.indexOfMethod("_q_notify()");
d->setNotifyObject(this, QDeclarativeExpression_notifyIdx);
}
/*! \internal */
QDeclarativeExpression::QDeclarativeExpression(QDeclarativeContextData *ctxt, void *expr,
- QDeclarativeRefCount *rc, QObject *me,
+ QDeclarativeRefCount *rc, QObject *me,
const QString &url, int lineNumber,
QDeclarativeExpressionPrivate &dd)
: QObject(dd, 0)
@@ -263,7 +263,7 @@ QDeclarativeExpression::QDeclarativeExpression(QDeclarativeContextData *ctxt, vo
Q_D(QDeclarativeExpression);
d->init(ctxt, expr, rc, me, url, lineNumber);
- if (QDeclarativeExpression_notifyIdx == -1)
+ if (QDeclarativeExpression_notifyIdx == -1)
QDeclarativeExpression_notifyIdx = QDeclarativeExpression::staticMetaObject.indexOfMethod("_q_notify()");
d->setNotifyObject(this, QDeclarativeExpression_notifyIdx);
}
@@ -284,12 +284,12 @@ QDeclarativeExpression::QDeclarativeExpression(QDeclarativeContext *ctxt,
Q_D(QDeclarativeExpression);
d->init(QDeclarativeContextData::get(ctxt), expression, scope);
- if (QDeclarativeExpression_notifyIdx == -1)
+ if (QDeclarativeExpression_notifyIdx == -1)
QDeclarativeExpression_notifyIdx = QDeclarativeExpression::staticMetaObject.indexOfMethod("_q_notify()");
d->setNotifyObject(this, QDeclarativeExpression_notifyIdx);
}
-/*!
+/*!
\internal
*/
QDeclarativeExpression::QDeclarativeExpression(QDeclarativeContextData *ctxt, QObject *scope,
@@ -299,7 +299,7 @@ QDeclarativeExpression::QDeclarativeExpression(QDeclarativeContextData *ctxt, QO
Q_D(QDeclarativeExpression);
d->init(ctxt, expression, scope);
- if (QDeclarativeExpression_notifyIdx == -1)
+ if (QDeclarativeExpression_notifyIdx == -1)
QDeclarativeExpression_notifyIdx = QDeclarativeExpression::staticMetaObject.indexOfMethod("_q_notify()");
d->setNotifyObject(this, QDeclarativeExpression_notifyIdx);
}
@@ -312,7 +312,7 @@ QDeclarativeExpression::QDeclarativeExpression(QDeclarativeContextData *ctxt, QO
Q_D(QDeclarativeExpression);
d->init(ctxt, expression, scope);
- if (QDeclarativeExpression_notifyIdx == -1)
+ if (QDeclarativeExpression_notifyIdx == -1)
QDeclarativeExpression_notifyIdx = QDeclarativeExpression::staticMetaObject.indexOfMethod("_q_notify()");
d->setNotifyObject(this, QDeclarativeExpression_notifyIdx);
}
@@ -380,10 +380,10 @@ void QDeclarativeExpression::setExpression(const QString &expression)
d->expressionFunction = QScriptValue();
}
-void QDeclarativeExpressionPrivate::exceptionToError(QScriptEngine *scriptEngine,
+void QDeclarativeExpressionPrivate::exceptionToError(QScriptEngine *scriptEngine,
QDeclarativeError &error)
{
- if (scriptEngine->hasUncaughtException() &&
+ if (scriptEngine->hasUncaughtException() &&
scriptEngine->uncaughtException().isError()) {
QString fileName;
@@ -412,7 +412,7 @@ bool QDeclarativeQtScriptExpression::notifyOnValueChange() const
void QDeclarativeQtScriptExpression::setNotifyOnValueChange(bool notify)
{
trackChange = notify;
- if (!notify && guardList)
+ if (!notify && guardList)
clearGuards();
}
@@ -526,7 +526,7 @@ QScriptValue QDeclarativeQtScriptExpression::eval(QObject *secondaryScope, bool
// Handle exception
if (scriptEngine->hasUncaughtException()) {
- if (!watcher.wasDeleted())
+ if (!watcher.wasDeleted())
QDeclarativeExpressionPrivate::exceptionToError(scriptEngine, error);
scriptEngine->clearExceptions();
@@ -547,7 +547,7 @@ void QDeclarativeQtScriptExpression::updateGuards(const QPODVector<QDeclarativeE
if (properties.count() != guardListLength) {
QDeclarativeNotifierEndpoint *newGuardList = new QDeclarativeNotifierEndpoint[properties.count()];
- for (int ii = 0; ii < qMin(guardListLength, properties.count()); ++ii)
+ for (int ii = 0; ii < qMin(guardListLength, properties.count()); ++ii)
guardList[ii].copyAndClear(newGuardList[ii]);
delete [] guardList;
@@ -573,8 +573,8 @@ void QDeclarativeQtScriptExpression::updateGuards(const QPODVector<QDeclarativeE
noChanges = false;
bool existing = false;
- for (int jj = 0; !existing && jj < ii; ++jj)
- if (guardList[jj].isConnected(property.notifier))
+ for (int jj = 0; !existing && jj < ii; ++jj)
+ if (guardList[jj].isConnected(property.notifier))
existing = true;
if (existing) {
@@ -595,8 +595,8 @@ void QDeclarativeQtScriptExpression::updateGuards(const QPODVector<QDeclarativeE
noChanges = false;
bool existing = false;
- for (int jj = 0; !existing && jj < ii; ++jj)
- if (guardList[jj].isConnected(property.object, property.notifyIndex))
+ for (int jj = 0; !existing && jj < ii; ++jj)
+ if (guardList[jj].isConnected(property.object, property.notifyIndex))
existing = true;
if (existing) {
@@ -639,7 +639,7 @@ QScriptValue QDeclarativeExpressionPrivate::scriptValue(QObject *secondaryScope,
rewriteBinding.setName(name);
bool ok = true;
const QString code = rewriteBinding(expression, &ok);
- if (ok)
+ if (ok)
expressionFunction = scriptEngine->evaluate(code, url, line);
scriptEngine->popContext();
@@ -722,7 +722,7 @@ QString QDeclarativeExpression::sourceFile() const
}
/*!
- Returns the source file line number for this expression. The source location
+ Returns the source file line number for this expression. The source location
must have been previously set by calling setSourceLocation().
*/
int QDeclarativeExpression::lineNumber() const
@@ -757,7 +757,7 @@ QObject *QDeclarativeExpression::scopeObject() const
/*!
Returns true if the last call to evaluate() resulted in an error,
otherwise false.
-
+
\sa error(), clearError()
*/
bool QDeclarativeExpression::hasError() const
@@ -799,8 +799,8 @@ void QDeclarativeExpressionPrivate::_q_notify()
void QDeclarativeQtScriptExpression::clearGuards()
{
- delete [] guardList;
- guardList = 0;
+ delete [] guardList;
+ guardList = 0;
guardListLength = 0;
}
@@ -827,7 +827,7 @@ QDeclarativeAbstractExpression::~QDeclarativeAbstractExpression()
{
if (m_prevExpression) {
*m_prevExpression = m_nextExpression;
- if (m_nextExpression)
+ if (m_nextExpression)
m_nextExpression->m_prevExpression = m_prevExpression;
}
}
@@ -841,7 +841,7 @@ void QDeclarativeAbstractExpression::setContext(QDeclarativeContextData *context
{
if (m_prevExpression) {
*m_prevExpression = m_nextExpression;
- if (m_nextExpression)
+ if (m_nextExpression)
m_nextExpression->m_prevExpression = m_prevExpression;
m_prevExpression = 0;
m_nextExpression = 0;
@@ -851,7 +851,7 @@ void QDeclarativeAbstractExpression::setContext(QDeclarativeContextData *context
if (m_context) {
m_nextExpression = m_context->expressions;
- if (m_nextExpression)
+ if (m_nextExpression)
m_nextExpression->m_prevExpression = &m_nextExpression;
m_prevExpression = &context->expressions;
m_context->expressions = this;
diff --git a/src/declarative/qml/qdeclarativeexpression.h b/src/declarative/qml/qdeclarativeexpression.h
index 728a4ac2..b48acd15 100644
--- a/src/declarative/qml/qdeclarativeexpression.h
+++ b/src/declarative/qml/qdeclarativeexpression.h
@@ -95,7 +95,7 @@ protected:
QDeclarativeExpressionPrivate &dd);
QDeclarativeExpression(QDeclarativeContextData *, QObject *, const QScriptValue &,
QDeclarativeExpressionPrivate &dd);
- QDeclarativeExpression(QDeclarativeContextData *, void *, QDeclarativeRefCount *rc,
+ QDeclarativeExpression(QDeclarativeContextData *, void *, QDeclarativeRefCount *rc,
QObject *me, const QString &, int, QDeclarativeExpressionPrivate &dd);
private:
diff --git a/src/declarative/qml/qdeclarativeexpression_p.h b/src/declarative/qml/qdeclarativeexpression_p.h
index 5cc568ef..13cefebc 100644
--- a/src/declarative/qml/qdeclarativeexpression_p.h
+++ b/src/declarative/qml/qdeclarativeexpression_p.h
@@ -84,7 +84,7 @@ private:
QDeclarativeAbstractExpression *m_nextExpression;
};
-class QDeclarativeDelayedError
+class QDeclarativeDelayedError
{
public:
inline QDeclarativeDelayedError() : nextError(0), prevError(0) {}
@@ -107,7 +107,7 @@ private:
QDeclarativeDelayedError **prevError;
};
-class QDeclarativeQtScriptExpression : public QDeclarativeAbstractExpression,
+class QDeclarativeQtScriptExpression : public QDeclarativeAbstractExpression,
public QDeclarativeDelayedError
{
public:
@@ -199,7 +199,7 @@ public:
static void exceptionToError(QScriptEngine *, QDeclarativeError &);
static QScriptValue evalInObjectScope(QDeclarativeContextData *, QObject *, const QString &, const QString &,
int, QScriptValue *);
- static QScriptValue evalInObjectScope(QDeclarativeContextData *, QObject *, const QScriptProgram &,
+ static QScriptValue evalInObjectScope(QDeclarativeContextData *, QObject *, const QScriptProgram &,
QScriptValue *);
bool expressionFunctionValid:1;
@@ -210,22 +210,22 @@ public:
};
QDeclarativeQtScriptExpression::DeleteWatcher::DeleteWatcher(QDeclarativeQtScriptExpression *data)
-: m_wasDeletedStorage(false), m_d(data)
+: m_wasDeletedStorage(false), m_d(data)
{
- if (!m_d->deleted)
- m_d->deleted = &m_wasDeletedStorage;
+ if (!m_d->deleted)
+ m_d->deleted = &m_wasDeletedStorage;
m_wasDeleted = m_d->deleted;
}
-QDeclarativeQtScriptExpression::DeleteWatcher::~DeleteWatcher()
+QDeclarativeQtScriptExpression::DeleteWatcher::~DeleteWatcher()
{
if (false == *m_wasDeleted && m_wasDeleted == m_d->deleted)
m_d->deleted = 0;
}
-bool QDeclarativeQtScriptExpression::DeleteWatcher::wasDeleted() const
-{
- return *m_wasDeleted;
+bool QDeclarativeQtScriptExpression::DeleteWatcher::wasDeleted() const
+{
+ return *m_wasDeleted;
}
QT_END_NAMESPACE
diff --git a/src/declarative/qml/qdeclarativeextensionplugin.cpp b/src/declarative/qml/qdeclarativeextensionplugin.cpp
index 76aa6012..e4925bde 100644
--- a/src/declarative/qml/qdeclarativeextensionplugin.cpp
+++ b/src/declarative/qml/qdeclarativeextensionplugin.cpp
@@ -52,10 +52,10 @@ QT_BEGIN_NAMESPACE
QDeclarativeExtensionPlugin is a plugin interface that makes it possible to
create QML extensions that can be loaded dynamically into QML applications.
- These extensions allow custom QML types to be made available to the QML engine.
-
+ These extensions allow custom QML types to be made available to the QML engine.
+
To write a QML extension plugin:
-
+
\list
\li Subclass QDeclarativeExtensionPlugin, implement registerTypes() method
to register types using qmlRegisterType(), and export the class using the Q_PLUGIN_METADATA() macro
@@ -72,7 +72,7 @@ QT_BEGIN_NAMESPACE
\section1 An example
Suppose there is a new \c TimeModel C++ class that should be made available
- as a new QML element. It provides the current time through \c hour and \c minute
+ as a new QML element. It provides the current time through \c hour and \c minute
properties, like this:
\snippet examples/declarative/cppextensions/plugins/plugin.cpp 0
@@ -87,11 +87,11 @@ QT_BEGIN_NAMESPACE
\codeline
\snippet examples/declarative/cppextensions/plugins/plugin.cpp export
- This registers the \c TimeModel class with the 1.0 version of this
- plugin library, as a QML type called \c Time. The Q_ASSERT statement
+ This registers the \c TimeModel class with the 1.0 version of this
+ plugin library, as a QML type called \c Time. The Q_ASSERT statement
ensures the module is imported correctly by any QML components that use this plugin.
- The project file defines the project as a plugin library and specifies
+ The project file defines the project as a plugin library and specifies
it should be built into the \c com/nokia/TimeExample directory:
\code
@@ -102,7 +102,7 @@ QT_BEGIN_NAMESPACE
DESTDIR = com/nokia/TimeExample
TARGET = qmlqtimeexampleplugin
...
- \endcode
+ \endcode
Finally, a \l{Writing a qmldir file}{qmldir file} is required in the \c com/nokia/TimeExample directory
that describes the plugin. This directory includes a \c Clock.qml file that
@@ -111,7 +111,7 @@ QT_BEGIN_NAMESPACE
\quotefile examples/declarative/cppextensions/plugins/com/nokia/TimeExample/qmldir
- Once the project is built and installed, the new \c Time element can be
+ Once the project is built and installed, the new \c Time element can be
used by any QML component that imports the \c com.nokia.TimeExample module:
\snippet examples/declarative/cppextensions/plugins/plugins.qml 0
@@ -132,7 +132,7 @@ QT_BEGIN_NAMESPACE
plugin.
The \a uri is an identifier for the plugin generated by the QML engine
- based on the name and path of the extension's plugin library.
+ based on the name and path of the extension's plugin library.
*/
/*!
diff --git a/src/declarative/qml/qdeclarativefastproperties.cpp b/src/declarative/qml/qdeclarativefastproperties.cpp
index dd5fa540..b2148945 100644
--- a/src/declarative/qml/qdeclarativefastproperties.cpp
+++ b/src/declarative/qml/qdeclarativefastproperties.cpp
@@ -45,10 +45,10 @@
QT_BEGIN_NAMESPACE
-// Adding entries to the QDeclarativeFastProperties class allows the QML
-// binding optimizer to bypass Qt's meta system and read and, more
+// Adding entries to the QDeclarativeFastProperties class allows the QML
+// binding optimizer to bypass Qt's meta system and read and, more
// importantly, subscribe to properties directly. Any property that is
-// primarily read from bindings is a candidate for inclusion as a fast
+// primarily read from bindings is a candidate for inclusion as a fast
// property.
QDeclarativeFastProperties::QDeclarativeFastProperties()
@@ -63,10 +63,10 @@ int QDeclarativeFastProperties::accessorIndexForProperty(const QMetaObject *meta
Q_ASSERT(propertyIndex >= 0);
// Find the "real" metaObject
- while (metaObject->propertyOffset() > propertyIndex)
+ while (metaObject->propertyOffset() > propertyIndex)
metaObject = metaObject->superClass();
- QHash<QPair<const QMetaObject *, int>, int>::Iterator iter =
+ QHash<QPair<const QMetaObject *, int>, int>::Iterator iter =
m_index.find(qMakePair(metaObject, propertyIndex));
if (iter != m_index.end())
return *iter;
@@ -80,7 +80,7 @@ void QDeclarativeFastProperties::add(const QMetaObject *metaObject, int property
Q_ASSERT(propertyIndex >= 0);
// Find the "real" metaObject
- while (metaObject->propertyOffset() > propertyIndex)
+ while (metaObject->propertyOffset() > propertyIndex)
metaObject = metaObject->superClass();
QPair<const QMetaObject *, int> data = qMakePair(metaObject, propertyIndex);
diff --git a/src/declarative/qml/qdeclarativeglobal_p.h b/src/declarative/qml/qdeclarativeglobal_p.h
index 11ebd3fd..dbefee69 100644
--- a/src/declarative/qml/qdeclarativeglobal_p.h
+++ b/src/declarative/qml/qdeclarativeglobal_p.h
@@ -73,14 +73,14 @@ struct QDeclarativeGraphics_DerivedObject : public QObject
};
/*!
- Returns true if the case of \a fileName is equivalent to the file case of
+ Returns true if the case of \a fileName is equivalent to the file case of
\a fileName on disk, and false otherwise.
- This is used to ensure that the behavior of QML on a case-insensitive file
- system is the same as on a case-sensitive file system. This function
- performs a "best effort" attempt to determine the real case of the file.
+ This is used to ensure that the behavior of QML on a case-insensitive file
+ system is the same as on a case-sensitive file system. This function
+ performs a "best effort" attempt to determine the real case of the file.
It may have false positives (say the case is correct when it isn't), but it
- should never have a false negative (say the case is incorrect when it is
+ should never have a false negative (say the case is incorrect when it is
correct).
Length specifies specifies the number of characters to be checked from
diff --git a/src/declarative/qml/qdeclarativeglobalscriptclass.cpp b/src/declarative/qml/qdeclarativeglobalscriptclass.cpp
index 6aa14c5e..6a745c86 100644
--- a/src/declarative/qml/qdeclarativeglobalscriptclass.cpp
+++ b/src/declarative/qml/qdeclarativeglobalscriptclass.cpp
@@ -94,7 +94,7 @@ QDeclarativeGlobalScriptClass::QDeclarativeGlobalScriptClass(QScriptEngine *engi
engine->setGlobalObject(newGlobalObject);
}
-QScriptClass::QueryFlags
+QScriptClass::QueryFlags
QDeclarativeGlobalScriptClass::queryProperty(const QScriptValue &object,
const QScriptString &name,
QueryFlags flags, uint *id)
@@ -106,14 +106,14 @@ QDeclarativeGlobalScriptClass::queryProperty(const QScriptValue &object,
return HandlesWriteAccess;
}
-void QDeclarativeGlobalScriptClass::setProperty(QScriptValue &object,
+void QDeclarativeGlobalScriptClass::setProperty(QScriptValue &object,
const QScriptString &name,
uint id, const QScriptValue &value)
{
Q_UNUSED(object);
Q_UNUSED(id);
Q_UNUSED(value);
- QString error = QLatin1String("Invalid write to global property \"") +
+ QString error = QLatin1String("Invalid write to global property \"") +
name.toString() + QLatin1Char('\"');
engine()->currentContext()->throwError(error);
}
diff --git a/src/declarative/qml/qdeclarativeguard_p.h b/src/declarative/qml/qdeclarativeguard_p.h
index 5d8a6c5f..dd4040db 100644
--- a/src/declarative/qml/qdeclarativeguard_p.h
+++ b/src/declarative/qml/qdeclarativeguard_p.h
@@ -59,7 +59,7 @@
QT_BEGIN_NAMESPACE
-class QDeclarativeGuardImpl
+class QDeclarativeGuardImpl
{
public:
inline QDeclarativeGuardImpl();
@@ -91,7 +91,7 @@ public:
inline T *object() const;
inline void setObject(T *g);
-
+
inline bool isNull() const
{ return !o; }
@@ -135,7 +135,7 @@ void QDeclarativeGuardImpl::addGuard()
{
Q_ASSERT(!prev);
- if (QObjectPrivate::get(o)->wasDeleted)
+ if (QObjectPrivate::get(o)->wasDeleted)
return;
QDeclarativeData *data = QDeclarativeData::get(o, true);
@@ -192,13 +192,13 @@ QDeclarativeGuard<T> &QDeclarativeGuard<T>::operator=(T *g)
}
template<class T>
-T *QDeclarativeGuard<T>::object() const
-{
- return static_cast<T *>(o);
+T *QDeclarativeGuard<T>::object() const
+{
+ return static_cast<T *>(o);
};
template<class T>
-void QDeclarativeGuard<T>::setObject(T *g)
+void QDeclarativeGuard<T>::setObject(T *g)
{
if (g != o) {
if (prev) remGuard();
diff --git a/src/declarative/qml/qdeclarativeimageprovider.cpp b/src/declarative/qml/qdeclarativeimageprovider.cpp
index 0b14ee6f..0ba64aea 100644
--- a/src/declarative/qml/qdeclarativeimageprovider.cpp
+++ b/src/declarative/qml/qdeclarativeimageprovider.cpp
@@ -70,8 +70,8 @@ public:
Image { source: "image://myimageprovider/image.png" }
\endqml
- This specifies that the image should be loaded by the image provider named
- "myimageprovider", and the image to be loaded is named "image.png". The QML engine
+ This specifies that the image should be loaded by the image provider named
+ "myimageprovider", and the image to be loaded is named "image.png". The QML engine
invokes the appropriate image provider according to the providers that have
been registered through QDeclarativeEngine::addImageProvider().
@@ -96,11 +96,11 @@ public:
When these images are loaded by QML, it looks for a matching image provider
and calls its requestImage() or requestPixmap() method (depending on its
- imageType()) to load the image. The method is called with the \c id
+ imageType()) to load the image. The method is called with the \c id
parameter set to "yellow" for the first image, and "red" for the second.
- Here is an image provider implementation that can load the images
- requested by the above QML. This implementation dynamically
+ Here is an image provider implementation that can load the images
+ requested by the above QML. This implementation dynamically
generates QPixmap images that are filled with the requested color:
\snippet examples/declarative/cppextensions/imageprovider/imageprovider.cpp 0
@@ -111,7 +111,7 @@ public:
with a "colors" identifier:
\code
- int main(int argc, char *argv[])
+ int main(int argc, char *argv[])
{
...
@@ -128,7 +128,7 @@ public:
\image imageprovider.png
- A complete example is available in Qt's
+ A complete example is available in Qt's
\l {declarative/cppextensions/imageprovider}{examples/declarative/cppextensions/imageprovider}
directory. Note the example registers the provider via a \l{QDeclarativeExtensionPlugin}{plugin}
instead of registering it in the application \c main() function as shown above.
@@ -139,14 +139,14 @@ public:
Image providers that support QImage loading automatically include support
for asychronous loading of images. To enable asynchronous loading for an
image source, set the \c asynchronous property to \c true for the relevant
- \l Image, \l BorderImage or \l AnimatedImage object. When this is enabled,
+ \l Image, \l BorderImage or \l AnimatedImage object. When this is enabled,
the image request to the provider is run in a low priority thread,
allowing image loading to be executed in the background, and reducing the
performance impact on the user interface.
Asynchronous loading is not supported for image providers that provide
QPixmap rather than QImage values, as pixmaps can only be created in the
- main thread. In this case, if \l {Image::}{asynchronous} is set to
+ main thread. In this case, if \l {Image::}{asynchronous} is set to
\c true, the value is ignored and the image is loaded
synchronously.
@@ -169,9 +169,9 @@ public:
Defines the type of image supported by this image provider.
- \value Image The Image Provider provides QImage images. The
+ \value Image The Image Provider provides QImage images. The
requestImage() method will be called for all image requests.
- \value Pixmap The Image Provider provides QPixmap images. The
+ \value Pixmap The Image Provider provides QPixmap images. The
requestPixmap() method will be called for all image requests.
*/
@@ -203,7 +203,7 @@ QDeclarativeImageProvider::ImageType QDeclarativeImageProvider::imageType() cons
}
/*!
- Implement this method to return the image with \a id. The default
+ Implement this method to return the image with \a id. The default
implementation returns an empty image.
The \a id is the requested image source, with the "image:" scheme and
diff --git a/src/declarative/qml/qdeclarativeimport.cpp b/src/declarative/qml/qdeclarativeimport.cpp
index b96b64c3..d175099b 100644
--- a/src/declarative/qml/qdeclarativeimport.cpp
+++ b/src/declarative/qml/qdeclarativeimport.cpp
@@ -67,7 +67,7 @@ static bool greaterThan(const QString &s1, const QString &s2)
typedef QMap<QString, QString> StringStringMap;
Q_GLOBAL_STATIC(StringStringMap, qmlEnginePluginsWithRegisteredTypes); // stores the uri
-class QDeclarativeImportedNamespace
+class QDeclarativeImportedNamespace
{
public:
QStringList uris;
@@ -90,16 +90,16 @@ public:
QDeclarativeImportsPrivate(QDeclarativeTypeLoader *loader);
~QDeclarativeImportsPrivate();
- bool importExtension(const QString &absoluteFilePath, const QString &uri,
- QDeclarativeImportDatabase *database, QDeclarativeDirComponents* components,
+ bool importExtension(const QString &absoluteFilePath, const QString &uri,
+ QDeclarativeImportDatabase *database, QDeclarativeDirComponents* components,
QString *errorString);
QString resolvedUri(const QString &dir_arg, QDeclarativeImportDatabase *database);
- bool add(const QDeclarativeDirComponents &qmldircomponentsnetwork,
- const QString& uri_arg, const QString& prefix,
- int vmaj, int vmin, QDeclarativeScriptParser::Import::Type importType,
+ bool add(const QDeclarativeDirComponents &qmldircomponentsnetwork,
+ const QString& uri_arg, const QString& prefix,
+ int vmaj, int vmin, QDeclarativeScriptParser::Import::Type importType,
QDeclarativeImportDatabase *database, QString *errorString);
- bool find(const QByteArray& type, int *vmajor, int *vminor,
+ bool find(const QByteArray& type, int *vmajor, int *vminor,
QDeclarativeType** type_return, QUrl* url_return, QString *errorString);
QDeclarativeImportedNamespace *findNamespace(const QString& type);
@@ -118,7 +118,7 @@ public:
\brief The QDeclarativeImports class encapsulates one QML document's import statements.
\internal
*/
-QDeclarativeImports::QDeclarativeImports(const QDeclarativeImports &copy)
+QDeclarativeImports::QDeclarativeImports(const QDeclarativeImports &copy)
: d(copy.d)
{
++d->ref;
@@ -165,7 +165,7 @@ QUrl QDeclarativeImports::baseUrl() const
}
static QDeclarativeTypeNameCache *
-cacheForNamespace(QDeclarativeEngine *engine, const QDeclarativeImportedNamespace &set,
+cacheForNamespace(QDeclarativeEngine *engine, const QDeclarativeImportedNamespace &set,
QDeclarativeTypeNameCache *cache)
{
if (!cache)
@@ -228,7 +228,7 @@ void QDeclarativeImports::populateCache(QDeclarativeTypeNameCache *cache, QDecla
\sa addImport()
*/
-bool QDeclarativeImports::resolveType(const QByteArray& type,
+bool QDeclarativeImports::resolveType(const QByteArray& type,
QDeclarativeType** type_return, QUrl* url_return, int *vmaj, int *vmin,
QDeclarativeImportedNamespace** ns_return, QString *errorString) const
{
@@ -242,13 +242,13 @@ bool QDeclarativeImports::resolveType(const QByteArray& type,
if (d->find(type,vmaj,vmin,type_return,url_return, errorString)) {
if (qmlImportTrace()) {
if (type_return && *type_return && url_return && !url_return->isEmpty())
- qDebug().nospace() << "QDeclarativeImports(" << qPrintable(baseUrl().toString()) << ")" << "::resolveType: "
+ qDebug().nospace() << "QDeclarativeImports(" << qPrintable(baseUrl().toString()) << ")" << "::resolveType: "
<< type << " => " << (*type_return)->typeName() << " " << *url_return;
if (type_return && *type_return)
- qDebug().nospace() << "QDeclarativeImports(" << qPrintable(baseUrl().toString()) << ")" << "::resolveType: "
+ qDebug().nospace() << "QDeclarativeImports(" << qPrintable(baseUrl().toString()) << ")" << "::resolveType: "
<< type << " => " << (*type_return)->typeName();
if (url_return && !url_return->isEmpty())
- qDebug().nospace() << "QDeclarativeImports(" << qPrintable(baseUrl().toString()) << ")" << "::resolveType: "
+ qDebug().nospace() << "QDeclarativeImports(" << qPrintable(baseUrl().toString()) << ")" << "::resolveType: "
<< type << " => " << *url_return;
}
return true;
@@ -267,8 +267,8 @@ bool QDeclarativeImports::resolveType(const QByteArray& type,
If either return pointer is 0, the corresponding search is not done.
*/
-bool QDeclarativeImports::resolveType(QDeclarativeImportedNamespace* ns, const QByteArray& type,
- QDeclarativeType** type_return, QUrl* url_return,
+bool QDeclarativeImports::resolveType(QDeclarativeImportedNamespace* ns, const QByteArray& type,
+ QDeclarativeType** type_return, QUrl* url_return,
int *vmaj, int *vmin) const
{
Q_ASSERT(d->typeLoader);
@@ -353,9 +353,9 @@ QDeclarativeImportsPrivate::~QDeclarativeImportsPrivate()
delete s;
}
-bool QDeclarativeImportsPrivate::importExtension(const QString &absoluteFilePath, const QString &uri,
- QDeclarativeImportDatabase *database,
- QDeclarativeDirComponents* components, QString *errorString)
+bool QDeclarativeImportsPrivate::importExtension(const QString &absoluteFilePath, const QString &uri,
+ QDeclarativeImportDatabase *database,
+ QDeclarativeDirComponents* components, QString *errorString)
{
Q_ASSERT(typeLoader);
const QDeclarativeDirParser *qmldirParser = typeLoader->qmlDirParser(absoluteFilePath);
@@ -426,9 +426,9 @@ QString QDeclarativeImportsPrivate::resolvedUri(const QString &dir_arg, QDeclara
return stableRelativePath;
}
-bool QDeclarativeImportsPrivate::add(const QDeclarativeDirComponents &qmldircomponentsnetwork,
- const QString& uri_arg, const QString& prefix, int vmaj, int vmin,
- QDeclarativeScriptParser::Import::Type importType,
+bool QDeclarativeImportsPrivate::add(const QDeclarativeDirComponents &qmldircomponentsnetwork,
+ const QString& uri_arg, const QString& prefix, int vmaj, int vmin,
+ QDeclarativeScriptParser::Import::Type importType,
QDeclarativeImportDatabase *database, QString *errorString)
{
Q_ASSERT(typeLoader);
@@ -767,16 +767,16 @@ QDeclarativeImportDatabase::~QDeclarativeImportDatabase()
The base URL must already have been set with Import::setBaseUrl().
*/
-bool QDeclarativeImports::addImport(QDeclarativeImportDatabase *importDb,
- const QString& uri, const QString& prefix, int vmaj, int vmin,
- QDeclarativeScriptParser::Import::Type importType,
- const QDeclarativeDirComponents &qmldircomponentsnetwork,
- QString *errorString)
+bool QDeclarativeImports::addImport(QDeclarativeImportDatabase *importDb,
+ const QString& uri, const QString& prefix, int vmaj, int vmin,
+ QDeclarativeScriptParser::Import::Type importType,
+ const QDeclarativeDirComponents &qmldircomponentsnetwork,
+ QString *errorString)
{
if (qmlImportTrace())
- qDebug().nospace() << "QDeclarativeImports(" << qPrintable(baseUrl().toString()) << ")" << "::addImport: "
- << uri << " " << vmaj << '.' << vmin << " "
- << (importType==QDeclarativeScriptParser::Import::Library? "Library" : "File")
+ qDebug().nospace() << "QDeclarativeImports(" << qPrintable(baseUrl().toString()) << ")" << "::addImport: "
+ << uri << " " << vmaj << '.' << vmin << " "
+ << (importType==QDeclarativeScriptParser::Import::Library? "Library" : "File")
<< " as " << prefix;
return d->add(qmldircomponentsnetwork, uri, prefix, vmaj, vmin, importType, importDb, errorString);
@@ -790,7 +790,7 @@ bool QDeclarativeImports::addImport(QDeclarativeImportDatabase *importDb,
\a qmldirPath is the location of the qmldir file.
*/
-QString QDeclarativeImportDatabase::resolvePlugin(const QDir &qmldirPath, const QString &qmldirPluginPath,
+QString QDeclarativeImportDatabase::resolvePlugin(const QDir &qmldirPath, const QString &qmldirPluginPath,
const QString &baseName, const QStringList &suffixes,
const QString &prefix)
{
@@ -831,7 +831,7 @@ QString QDeclarativeImportDatabase::resolvePlugin(const QDir &qmldirPath, const
}
if (qmlImportTrace())
- qDebug() << "QDeclarativeImportDatabase::resolvePlugin: Could not resolve plugin" << baseName
+ qDebug() << "QDeclarativeImportDatabase::resolvePlugin: Could not resolve plugin" << baseName
<< "in" << qmldirPath.absolutePath();
return QString();
@@ -853,7 +853,7 @@ QString QDeclarativeImportDatabase::resolvePlugin(const QDir &qmldirPath, const
Version number on unix are ignored.
*/
-QString QDeclarativeImportDatabase::resolvePlugin(const QDir &qmldirPath, const QString &qmldirPluginPath,
+QString QDeclarativeImportDatabase::resolvePlugin(const QDir &qmldirPath, const QString &qmldirPluginPath,
const QString &baseName)
{
#if defined(Q_OS_WIN32) || defined(Q_OS_WINCE)
@@ -1008,7 +1008,7 @@ bool QDeclarativeImportDatabase::importPlugin(const QString &filePath, const QSt
if (!engineInitialized || !typesRegistered) {
if (!QDeclarative_isFileCaseCorrect(absoluteFilePath)) {
- if (errorString)
+ if (errorString)
*errorString = tr("File name case mismatch for \"%1\"").arg(absoluteFilePath);
return false;
}
diff --git a/src/declarative/qml/qdeclarativeimport_p.h b/src/declarative/qml/qdeclarativeimport_p.h
index 91a50e8c..e3013561 100644
--- a/src/declarative/qml/qdeclarativeimport_p.h
+++ b/src/declarative/qml/qdeclarativeimport_p.h
@@ -87,15 +87,15 @@ public:
int *version_major, int *version_minor,
QDeclarativeImportedNamespace** ns_return,
QString *errorString = 0) const;
- bool resolveType(QDeclarativeImportedNamespace*,
+ bool resolveType(QDeclarativeImportedNamespace*,
const QByteArray& type,
QDeclarativeType** type_return, QUrl* url_return,
int *version_major, int *version_minor) const;
- bool addImport(QDeclarativeImportDatabase *,
- const QString& uri, const QString& prefix, int vmaj, int vmin,
+ bool addImport(QDeclarativeImportDatabase *,
+ const QString& uri, const QString& prefix, int vmaj, int vmin,
QDeclarativeScriptParser::Import::Type importType,
- const QDeclarativeDirComponents &qmldircomponentsnetwork,
+ const QDeclarativeDirComponents &qmldircomponentsnetwork,
QString *errorString);
void populateCache(QDeclarativeTypeNameCache *cache, QDeclarativeEngine *) const;
@@ -124,10 +124,10 @@ public:
private:
friend class QDeclarativeImportsPrivate;
- QString resolvePlugin(const QDir &qmldirPath, const QString &qmldirPluginPath,
+ QString resolvePlugin(const QDir &qmldirPath, const QString &qmldirPluginPath,
const QString &baseName, const QStringList &suffixes,
const QString &prefix = QString());
- QString resolvePlugin(const QDir &qmldirPath, const QString &qmldirPluginPath,
+ QString resolvePlugin(const QDir &qmldirPath, const QString &qmldirPluginPath,
const QString &baseName);
diff --git a/src/declarative/qml/qdeclarativeinclude.cpp b/src/declarative/qml/qdeclarativeinclude.cpp
index 3e84f60d..7486058d 100644
--- a/src/declarative/qml/qdeclarativeinclude.cpp
+++ b/src/declarative/qml/qdeclarativeinclude.cpp
@@ -51,8 +51,8 @@
QT_BEGIN_NAMESPACE
-QDeclarativeInclude::QDeclarativeInclude(const QUrl &url,
- QDeclarativeEngine *engine,
+QDeclarativeInclude::QDeclarativeInclude(const QUrl &url,
+ QDeclarativeEngine *engine,
QScriptContext *ctxt)
: QObject(engine), m_engine(engine), m_network(0), m_reply(0), m_url(url), m_redirectCount(0)
{
@@ -115,8 +115,8 @@ void QDeclarativeInclude::finished()
QVariant redirect = m_reply->attribute(QNetworkRequest::RedirectionTargetAttribute);
if (redirect.isValid()) {
m_url = m_url.resolved(redirect.toUrl());
- delete m_reply;
-
+ delete m_reply;
+
QNetworkRequest request;
request.setUrl(m_url);
@@ -183,7 +183,7 @@ QScriptValue QDeclarativeInclude::include(QScriptContext *ctxt, QScriptEngine *e
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(engine);
QUrl contextUrl = ep->contextClass->urlFromValue(QScriptDeclarativeClass::scopeChainValue(ctxt, -3));
- if (contextUrl.isEmpty())
+ if (contextUrl.isEmpty())
return ctxt->throwError(QLatin1String("Qt.include(): Can only be called from JavaScript files"));
QString urlString = ctxt->argument(0).toString();
@@ -201,7 +201,7 @@ QScriptValue QDeclarativeInclude::include(QScriptContext *ctxt, QScriptEngine *e
QScriptValue result;
if (localFile.isEmpty()) {
- QDeclarativeInclude *i =
+ QDeclarativeInclude *i =
new QDeclarativeInclude(url, QDeclarativeEnginePrivate::getEngine(engine), ctxt);
if (func.isValid())
@@ -215,7 +215,7 @@ QScriptValue QDeclarativeInclude::include(QScriptContext *ctxt, QScriptEngine *e
QByteArray data = f.readAll();
QString code = QString::fromUtf8(data);
- QDeclarativeContextData *context =
+ QDeclarativeContextData *context =
ep->contextClass->contextFromValue(QScriptDeclarativeClass::scopeChainValue(ctxt, -3));
QScriptContext *scriptContext = QScriptDeclarativeClass::pushCleanContext(engine);
diff --git a/src/declarative/qml/qdeclarativeinfo.cpp b/src/declarative/qml/qdeclarativeinfo.cpp
index 960cc352..74905bc4 100644
--- a/src/declarative/qml/qdeclarativeinfo.cpp
+++ b/src/declarative/qml/qdeclarativeinfo.cpp
@@ -61,13 +61,13 @@ QT_BEGIN_NAMESPACE
When QML types display warning messages, it improves traceability
if they include the QML file and line number on which the
particular instance was instantiated.
-
+
To include the file and line number, an object must be passed. If
the file and line number is not available for that instance
(either it was not instantiated by the QML engine or location
information is disabled), "unknown location" will be used instead.
- For example,
+ For example,
\code
qmlInfo(object) << tr("component property is a write-once property");
diff --git a/src/declarative/qml/qdeclarativeinstruction_p.h b/src/declarative/qml/qdeclarativeinstruction_p.h
index 72876466..c6f584c9 100644
--- a/src/declarative/qml/qdeclarativeinstruction_p.h
+++ b/src/declarative/qml/qdeclarativeinstruction_p.h
@@ -61,11 +61,11 @@ class QDeclarativeCompiledData;
class Q_AUTOTEST_EXPORT QDeclarativeInstruction
{
public:
- enum Type {
+ enum Type {
//
// Object Creation
//
- // CreateObject - Create a new object instance and push it on the
+ // CreateObject - Create a new object instance and push it on the
// object stack
// SetId - Set the id of the object on the top of the object stack
// SetDefault - Sets the instance on the top of the object stack to
@@ -149,14 +149,14 @@ public:
//
// Stack manipulation
- //
+ //
// PopFetchedObject - Remove an object from the object stack
// PopQList - Remove a list from the list stack
PopFetchedObject,
PopQList,
PopValueType, /* fetchValue */
- //
+ //
// Deferred creation
//
Defer /* defer */
@@ -224,7 +224,7 @@ public:
};
struct BeginInstruction {
int castValue;
- };
+ };
struct StoreFloatInstruction {
int propertyIndex;
float value;
@@ -249,7 +249,7 @@ public:
int propertyIndex;
int value;
int scope;
- };
+ };
struct StoreScriptInstruction {
int value;
};
diff --git a/src/declarative/qml/qdeclarativeintegercache_p.h b/src/declarative/qml/qdeclarativeintegercache_p.h
index ee995d5b..9b7b7955 100644
--- a/src/declarative/qml/qdeclarativeintegercache_p.h
+++ b/src/declarative/qml/qdeclarativeintegercache_p.h
@@ -81,7 +81,7 @@ protected:
private:
struct Data : public QScriptDeclarativeClass::PersistentIdentifier {
- Data(const QScriptDeclarativeClass::PersistentIdentifier &i, int v)
+ Data(const QScriptDeclarativeClass::PersistentIdentifier &i, int v)
: QScriptDeclarativeClass::PersistentIdentifier(i), value(v) {}
int value;
@@ -101,7 +101,7 @@ int QDeclarativeIntegerCache::value(const QScriptDeclarativeClass::Identifier &i
return d?d->value:-1;
}
-int QDeclarativeIntegerCache::count() const
+int QDeclarativeIntegerCache::count() const
{
return stringCache.count();
}
diff --git a/src/declarative/qml/qdeclarativelist.cpp b/src/declarative/qml/qdeclarativelist.cpp
index b8e126ff..ececfca2 100644
--- a/src/declarative/qml/qdeclarativelist.cpp
+++ b/src/declarative/qml/qdeclarativelist.cpp
@@ -109,7 +109,7 @@ QML list properties are typesafe. Only QObject's that derive from the correct b
the list. The listElementType() method can be used to query the QMetaObject of the QObject type supported.
Attempting to add objects of the incorrect type to a list property will fail.
-Like with normal lists, when accessing a list element by index, it is the callers responsibility to ensure
+Like with normal lists, when accessing a list element by index, it is the callers responsibility to ensure
that it does not request an out of range element using the count() method before calling at().
*/
@@ -123,7 +123,7 @@ QDeclarativeListReference::QDeclarativeListReference()
/*!
Constructs a QDeclarativeListReference for \a object's \a property. If \a property is not a list
-property, an invalid QDeclarativeListReference is created. If \a object is destroyed after
+property, an invalid QDeclarativeListReference is created. If \a object is destroyed after
the reference is constructed, it will automatically become invalid. That is, it is safe to hold
QDeclarativeListReference instances even after \a object is deleted.
@@ -136,7 +136,7 @@ QDeclarativeListReference::QDeclarativeListReference(QObject *object, const char
if (!object || !property) return;
QDeclarativePropertyCache::Data local;
- QDeclarativePropertyCache::Data *data =
+ QDeclarativePropertyCache::Data *data =
QDeclarativePropertyCache::property(engine, object, QLatin1String(property), local);
if (!data || !(data->flags & QDeclarativePropertyCache::Data::IsQList)) return;
@@ -241,7 +241,7 @@ bool QDeclarativeListReference::canClear() const
}
/*!
-Returns true if the list property can be queried for its element count, otherwise false.
+Returns true if the list property can be queried for its element count, otherwise false.
Returns false if the reference is invalid.
\sa count()
@@ -307,7 +307,7 @@ int QDeclarativeListReference::count() const
/*!
\class QDeclarativeListProperty
\since 4.7
-\brief The QDeclarativeListProperty class allows applications to expose list-like
+\brief The QDeclarativeListProperty class allows applications to expose list-like
properties to QML.
QML has many list properties, where more than one object value can be assigned.
@@ -315,7 +315,7 @@ The use of a list property from QML looks like this:
\code
FruitBasket {
- fruit: [
+ fruit: [
Apple {},
Orange{},
Banana{}
@@ -325,10 +325,10 @@ FruitBasket {
The QDeclarativeListProperty encapsulates a group of function pointers that represet the
set of actions QML can perform on the list - adding items, retrieving items and
-clearing the list. In the future, additional operations may be supported. All
+clearing the list. In the future, additional operations may be supported. All
list properties must implement the append operation, but the rest are optional.
-To provide a list property, a C++ class must implement the operation callbacks,
+To provide a list property, a C++ class must implement the operation callbacks,
and then return an appropriate QDeclarativeListProperty value from the property getter.
List properties should have no setter. In the example above, the Q_PROPERTY()
declarative will look like this:
@@ -337,7 +337,7 @@ declarative will look like this:
Q_PROPERTY(QDeclarativeListProperty<Fruit> fruit READ fruit);
\endcode
-QML list properties are typesafe - in this case \c {Fruit} is a QObject type that
+QML list properties are typesafe - in this case \c {Fruit} is a QObject type that
\c {Apple}, \c {Orange} and \c {Banana} all derive from.
\note QDeclarativeListProperty can only be used for lists of QObject-derived object pointers.
@@ -347,7 +347,7 @@ QML list properties are typesafe - in this case \c {Fruit} is a QObject type tha
*/
/*!
-\fn QDeclarativeListProperty::QDeclarativeListProperty()
+\fn QDeclarativeListProperty::QDeclarativeListProperty()
\internal
*/
@@ -358,18 +358,18 @@ Convenience constructor for making a QDeclarativeListProperty value from an exis
QList \a list. The \a list reference must remain valid for as long as \a object
exists. \a object must be provided.
-Generally this constructor should not be used in production code, as a
+Generally this constructor should not be used in production code, as a
writable QList violates QML's memory management rules. However, this constructor
can very useful while prototyping.
*/
/*!
-\fn QDeclarativeListProperty::QDeclarativeListProperty(QObject *object, void *data, AppendFunction append,
- CountFunction count = 0, AtFunction at = 0,
+\fn QDeclarativeListProperty::QDeclarativeListProperty(QObject *object, void *data, AppendFunction append,
+ CountFunction count = 0, AtFunction at = 0,
ClearFunction clear = 0)
Construct a QDeclarativeListProperty from a set of operation functions. An opaque \a data handle
-may be passed which can be accessed from within the operation functions. The list property
+may be passed which can be accessed from within the operation functions. The list property
remains valid while \a object exists.
The \a append operation is compulsory and must be provided, while the \a count, \a at and
@@ -393,7 +393,7 @@ Return the number of elements in the list \a property.
*/
/*!
-\fn bool QDeclarativeListProperty::operator==(const QDeclarativeListProperty &other) const
+\fn bool QDeclarativeListProperty::operator==(const QDeclarativeListProperty &other) const
Returns true if this QDeclarativeListProperty is equal to \a other, otherwise false.
*/
diff --git a/src/declarative/qml/qdeclarativelistscriptclass.cpp b/src/declarative/qml/qdeclarativelistscriptclass.cpp
index fb84dffb..7b06ed53 100644
--- a/src/declarative/qml/qdeclarativelistscriptclass.cpp
+++ b/src/declarative/qml/qdeclarativelistscriptclass.cpp
@@ -94,8 +94,8 @@ QScriptValue QDeclarativeListScriptClass::newList(const QDeclarativeListProperty
return newObject(scriptEngine, this, data);
}
-QScriptClass::QueryFlags
-QDeclarativeListScriptClass::queryProperty(Object *object, const Identifier &name,
+QScriptClass::QueryFlags
+QDeclarativeListScriptClass::queryProperty(Object *object, const Identifier &name,
QScriptClass::QueryFlags flags)
{
Q_UNUSED(object);
@@ -120,7 +120,7 @@ QDeclarativeListScriptClass::Value QDeclarativeListScriptClass::property(Object
QDeclarativeEnginePrivate *enginePriv = QDeclarativeEnginePrivate::get(engine);
ListData *data = (ListData *)obj;
- if (!data->object)
+ if (!data->object)
return Value();
quint32 count = data->property.count?data->property.count(&data->property):0;
diff --git a/src/declarative/qml/qdeclarativelistscriptclass_p.h b/src/declarative/qml/qdeclarativelistscriptclass_p.h
index b5ff5997..929b2116 100644
--- a/src/declarative/qml/qdeclarativelistscriptclass_p.h
+++ b/src/declarative/qml/qdeclarativelistscriptclass_p.h
@@ -69,7 +69,7 @@ public:
QScriptValue newList(const QDeclarativeListProperty<QObject> &, int);
protected:
- virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
+ virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
QScriptClass::QueryFlags flags);
virtual Value property(Object *, const Identifier &);
virtual QVariant toVariant(Object *, bool *ok);
diff --git a/src/declarative/qml/qdeclarativemetatype.cpp b/src/declarative/qml/qdeclarativemetatype.cpp
index d90ccad8..81d2f45f 100644
--- a/src/declarative/qml/qdeclarativemetatype.cpp
+++ b/src/declarative/qml/qdeclarativemetatype.cpp
@@ -152,7 +152,7 @@ public:
QByteArray m_name;
int m_version_maj;
int m_version_min;
- int m_typeId; int m_listId;
+ int m_typeId; int m_listId;
int m_revision;
mutable bool m_containsRevisionedAttributes;
mutable QDeclarativeType *m_superType;
@@ -183,9 +183,9 @@ QHash<const QMetaObject *, int> QDeclarativeTypePrivate::m_attachedPropertyIds;
QDeclarativeTypePrivate::QDeclarativeTypePrivate()
: m_isInterface(false), m_iid(0), m_typeId(0), m_listId(0), m_revision(0), m_containsRevisionedAttributes(false),
- m_superType(0), m_allocationSize(0), m_newFunc(0), m_baseMetaObject(0), m_attachedPropertiesFunc(0),
- m_attachedPropertiesType(0), m_parserStatusCast(-1), m_propertyValueSourceCast(-1),
- m_propertyValueInterceptorCast(-1), m_extFunc(0), m_extMetaObject(0), m_index(-1), m_customParser(0),
+ m_superType(0), m_allocationSize(0), m_newFunc(0), m_baseMetaObject(0), m_attachedPropertiesFunc(0),
+ m_attachedPropertiesType(0), m_parserStatusCast(-1), m_propertyValueSourceCast(-1),
+ m_propertyValueInterceptorCast(-1), m_extFunc(0), m_extMetaObject(0), m_index(-1), m_customParser(0),
m_isSetup(false), m_haveSuperType(false)
{
}
@@ -291,7 +291,7 @@ QDeclarativeType *QDeclarativeType::superType() const
return d->m_superType;
}
-static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo,
+static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo,
const QMetaObject *ignoreStart, const QMetaObject *ignoreEnd)
{
// Clone Q_CLASSINFO
@@ -300,7 +300,7 @@ static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo,
int otherIndex = ignoreEnd->indexOfClassInfo(info.name());
if (otherIndex >= ignoreStart->classInfoOffset() + ignoreStart->classInfoCount()) {
- // Skip
+ // Skip
} else {
builder.addClassInfo(info.name(), info.value());
}
@@ -313,7 +313,7 @@ static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo,
int otherIndex = ignoreEnd->indexOfProperty(property.name());
if (otherIndex >= ignoreStart->propertyOffset() + ignoreStart->propertyCount()) {
builder.addProperty(QByteArray("__qml_ignore__") + property.name(), QByteArray("void"));
- // Skip
+ // Skip
} else {
builder.addProperty(property);
}
@@ -331,7 +331,7 @@ static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo,
bool found = false;
- for (int ii = ignoreStart->methodOffset() + ignoreStart->methodCount();
+ for (int ii = ignoreStart->methodOffset() + ignoreStart->methodCount();
!found && ii < ignoreEnd->methodOffset() + ignoreEnd->methodCount();
++ii) {
@@ -354,7 +354,7 @@ static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo,
int otherIndex = ignoreEnd->indexOfEnumerator(enumerator.name());
if (otherIndex >= ignoreStart->enumeratorOffset() + ignoreStart->enumeratorCount()) {
- // Skip
+ // Skip
} else {
builder.addEnumerator(enumerator);
}
@@ -404,7 +404,7 @@ void QDeclarativeTypePrivate::init() const
m_metaObjects[ii].methodOffset =
m_metaObjects.at(ii).metaObject->methodOffset();
}
-
+
// Check for revisioned details
{
const QMetaObject *mo = 0;
@@ -555,7 +555,7 @@ const QMetaObject *QDeclarativeType::attachedPropertiesType() const
/*
This is the id passed to qmlAttachedPropertiesById(). This is different from the index
-for the case that a single class is registered under two or more names (eg. Item in
+for the case that a single class is registered under two or more names (eg. Item in
Qt 4.7 and QtQuick 1.0).
*/
int QDeclarativeType::attachedPropertiesId() const
@@ -600,7 +600,7 @@ int registerAutoParentFunction(QDeclarativePrivate::RegisterAutoParent &autopare
int registerInterface(const QDeclarativePrivate::RegisterInterface &interface)
{
- if (interface.version > 0)
+ if (interface.version > 0)
qFatal("qmlRegisterType(): Cannot mix incompatible QML versions.");
QWriteLocker lock(metaTypeDataLock());
@@ -1020,7 +1020,7 @@ QDeclarativeType *QDeclarativeMetaType::qmlType(const QMetaObject *metaObject, c
}
/*!
- Returns the type (if any) that corresponds to the QVariant::Type \a userType.
+ Returns the type (if any) that corresponds to the QVariant::Type \a userType.
Returns null if no type is registered.
*/
QDeclarativeType *QDeclarativeMetaType::qmlType(int userType)
diff --git a/src/declarative/qml/qdeclarativemetatype_p.h b/src/declarative/qml/qdeclarativemetatype_p.h
index 2ba391a0..bc6346b1 100644
--- a/src/declarative/qml/qdeclarativemetatype_p.h
+++ b/src/declarative/qml/qdeclarativemetatype_p.h
@@ -97,7 +97,7 @@ public:
enum TypeCategory { Unknown, Object, List };
static TypeCategory typeCategory(int);
-
+
static bool isInterface(int);
static const char *interfaceIId(int);
static bool isList(int);
diff --git a/src/declarative/qml/qdeclarativenotifier.cpp b/src/declarative/qml/qdeclarativenotifier.cpp
index 0da3cffc..3a2ca643 100644
--- a/src/declarative/qml/qdeclarativenotifier.cpp
+++ b/src/declarative/qml/qdeclarativenotifier.cpp
@@ -57,12 +57,12 @@ void QDeclarativeNotifier::emitNotify(QDeclarativeNotifierEndpoint *endpoint)
if (endpoint) {
void *args[] = { 0 };
- QMetaObject::metacall(endpoint->target, QMetaObject::InvokeMetaMethod,
+ QMetaObject::metacall(endpoint->target, QMetaObject::InvokeMetaMethod,
endpoint->targetMethod, args);
if (endpoint)
endpoint->asNotifier()->disconnected = oldDisconnected;
- }
+ }
if (oldDisconnected) *oldDisconnected = endpoint;
}
@@ -70,7 +70,7 @@ void QDeclarativeNotifier::emitNotify(QDeclarativeNotifierEndpoint *endpoint)
void QDeclarativeNotifierEndpoint::connect(QObject *source, int sourceSignal)
{
Signal *s = toSignal();
-
+
if (s->source == source && s->sourceSignal == sourceSignal)
return;
@@ -118,7 +118,7 @@ void QDeclarativeNotifierEndpoint::copyAndClear(QDeclarativeNotifierEndpoint &ot
n->next = 0;
n->disconnected = 0;
n->notifier = 0;
- }
+ }
}
diff --git a/src/declarative/qml/qdeclarativenotifier_p.h b/src/declarative/qml/qdeclarativenotifier_p.h
index 155aa9cc..230651d9 100644
--- a/src/declarative/qml/qdeclarativenotifier_p.h
+++ b/src/declarative/qml/qdeclarativenotifier_p.h
@@ -122,7 +122,7 @@ QDeclarativeNotifier::QDeclarativeNotifier()
}
QDeclarativeNotifier::~QDeclarativeNotifier()
-{
+{
QDeclarativeNotifierEndpoint *endpoint = endpoints;
while (endpoint) {
QDeclarativeNotifierEndpoint::Notifier *n = endpoint->asNotifier();
@@ -143,12 +143,12 @@ void QDeclarativeNotifier::notify()
}
QDeclarativeNotifierEndpoint::QDeclarativeNotifierEndpoint()
-: target(0), targetMethod(0), type(InvalidType)
+: target(0), targetMethod(0), type(InvalidType)
{
}
QDeclarativeNotifierEndpoint::QDeclarativeNotifierEndpoint(QObject *t, int m)
-: target(t), targetMethod(m), type(InvalidType)
+: target(t), targetMethod(m), type(InvalidType)
{
}
@@ -185,7 +185,7 @@ bool QDeclarativeNotifierEndpoint::isConnected(QDeclarativeNotifier *notifier)
void QDeclarativeNotifierEndpoint::connect(QDeclarativeNotifier *notifier)
{
Notifier *n = toNotifier();
-
+
if (n->notifier == notifier)
return;
@@ -221,7 +221,7 @@ void QDeclarativeNotifierEndpoint::disconnect()
QDeclarativeNotifierEndpoint::Notifier *QDeclarativeNotifierEndpoint::toNotifier()
{
- if (NotifierType == type)
+ if (NotifierType == type)
return asNotifier();
if (SignalType == type) {
@@ -239,15 +239,15 @@ QDeclarativeNotifierEndpoint::Notifier *QDeclarativeNotifierEndpoint::toNotifier
return n;
}
-QDeclarativeNotifierEndpoint::Notifier *QDeclarativeNotifierEndpoint::asNotifier()
-{
+QDeclarativeNotifierEndpoint::Notifier *QDeclarativeNotifierEndpoint::asNotifier()
+{
Q_ASSERT(type == NotifierType);
return &notifier;
}
QDeclarativeNotifierEndpoint::Signal *QDeclarativeNotifierEndpoint::toSignal()
{
- if (SignalType == type)
+ if (SignalType == type)
return asSignal();
disconnect();
@@ -256,8 +256,8 @@ QDeclarativeNotifierEndpoint::Signal *QDeclarativeNotifierEndpoint::toSignal()
return signal.signal;
}
-QDeclarativeNotifierEndpoint::Signal *QDeclarativeNotifierEndpoint::asSignal()
-{
+QDeclarativeNotifierEndpoint::Signal *QDeclarativeNotifierEndpoint::asSignal()
+{
Q_ASSERT(type == SignalType);
return signal.signal;
}
diff --git a/src/declarative/qml/qdeclarativeobjectscriptclass.cpp b/src/declarative/qml/qdeclarativeobjectscriptclass.cpp
index 68072674..a3679123 100644
--- a/src/declarative/qml/qdeclarativeobjectscriptclass.cpp
+++ b/src/declarative/qml/qdeclarativeobjectscriptclass.cpp
@@ -77,7 +77,7 @@ struct ObjectData : public QScriptDeclarativeClass::Object {
virtual ~ObjectData() {
if (object && !object->parent()) {
QDeclarativeData *ddata = QDeclarativeData::get(object, false);
- if (ddata && !ddata->indestructible && 0 == --ddata->objectDataRefCount)
+ if (ddata && !ddata->indestructible && 0 == --ddata->objectDataRefCount)
object->deleteLater();
}
}
@@ -176,7 +176,7 @@ QDeclarativeObjectScriptClass::queryProperty(QObject *obj, const Identifier &nam
if ((hints & ImplicitObject) && lastData && lastData->revision != 0) {
QDeclarativeData *ddata = QDeclarativeData::get(obj);
- if (ddata && ddata->propertyCache && !ddata->propertyCache->isAllowedInRevision(lastData))
+ if (ddata && ddata->propertyCache && !ddata->propertyCache->isAllowedInRevision(lastData))
return 0;
}
@@ -343,7 +343,7 @@ void QDeclarativeObjectScriptClass::setProperty(QObject *obj,
return;
}
- if (!(lastData->flags & QDeclarativePropertyCache::Data::IsWritable) &&
+ if (!(lastData->flags & QDeclarativePropertyCache::Data::IsWritable) &&
!(lastData->flags & QDeclarativePropertyCache::Data::IsQList)) {
QString error = QLatin1String("Cannot assign to read-only property \"") +
toString(name) + QLatin1Char('\"');
@@ -725,7 +725,7 @@ void *MetaCallArgument::dataPtr()
{
if (type == -1)
return qvariantPtr->data();
- else
+ else
return (void *)&allocData;
}
@@ -803,7 +803,7 @@ void MetaCallArgument::fromScriptValue(int callType, QDeclarativeEngine *engine,
qvariantPtr = new (&allocData) QVariant(other);
type = callType;
} else if (callType == qMetaTypeId<QList<QObject*> >()) {
- qlistPtr = new (&allocData) QList<QObject *>();
+ qlistPtr = new (&allocData) QList<QObject *>();
if (value.isArray()) {
int length = value.property(QLatin1String("length")).toInt32();
for (int ii = 0; ii < length; ++ii) {
@@ -828,7 +828,7 @@ void MetaCallArgument::fromScriptValue(int callType, QDeclarativeEngine *engine,
qvariantPtr->convert((QVariant::Type)callType);
} else if (const QMetaObject *mo = priv->rawMetaObjectForType(callType)) {
QObject *obj = priv->toQObject(v);
-
+
if (obj) {
const QMetaObject *objMo = obj->metaObject();
while (objMo && objMo != mo) objMo = objMo->superClass();
@@ -898,7 +898,7 @@ int QDeclarativeObjectMethodScriptClass::enumType(const QMetaObject *meta, const
if (scopeIdx != -1) {
scope = str.left(scopeIdx);
name = str.mid(scopeIdx + 2);
- } else {
+ } else {
name = str;
}
for (int i = meta->enumeratorCount() - 1; i >= 0; --i) {
@@ -919,8 +919,8 @@ QDeclarativeObjectMethodScriptClass::Value QDeclarativeObjectMethodScriptClass::
return callOverloaded(method, ctxt);
}
-QDeclarativeObjectMethodScriptClass::Value
-QDeclarativeObjectMethodScriptClass::callPrecise(QObject *object, const QDeclarativePropertyCache::Data &data,
+QDeclarativeObjectMethodScriptClass::Value
+QDeclarativeObjectMethodScriptClass::callPrecise(QObject *object, const QDeclarativePropertyCache::Data &data,
QScriptContext *ctxt)
{
if (data.flags & QDeclarativePropertyCache::Data::HasArguments) {
@@ -932,9 +932,9 @@ QDeclarativeObjectMethodScriptClass::callPrecise(QObject *object, const QDeclara
// ### Cache
for (int ii = 0; ii < argTypeNames.count(); ++ii) {
argTypes[ii] = QMetaType::type(argTypeNames.at(ii));
- if (argTypes[ii] == QVariant::Invalid)
+ if (argTypes[ii] == QVariant::Invalid)
argTypes[ii] = enumType(object->metaObject(), QString::fromLatin1(argTypeNames.at(ii)));
- if (argTypes[ii] == QVariant::Invalid)
+ if (argTypes[ii] == QVariant::Invalid)
return Value(ctxt, ctxt->throwError(QString::fromLatin1("Unknown method parameter type: %1").arg(QLatin1String(argTypeNames.at(ii)))));
}
@@ -950,9 +950,9 @@ QDeclarativeObjectMethodScriptClass::callPrecise(QObject *object, const QDeclara
}
}
-QDeclarativeObjectMethodScriptClass::Value
-QDeclarativeObjectMethodScriptClass::callMethod(QObject *object, int index,
- int returnType, int argCount, int *argTypes,
+QDeclarativeObjectMethodScriptClass::Value
+QDeclarativeObjectMethodScriptClass::callMethod(QObject *object, int index,
+ int returnType, int argCount, int *argTypes,
QScriptContext *ctxt)
{
if (argCount > 0) {
@@ -972,7 +972,7 @@ QDeclarativeObjectMethodScriptClass::callMethod(QObject *object, int index,
return args[0].toValue(engine);
} else if (returnType != 0) {
-
+
MetaCallArgument arg;
arg.initAsType(returnType, engine);
@@ -994,13 +994,13 @@ QDeclarativeObjectMethodScriptClass::callMethod(QObject *object, int index,
/*!
Resolve the overloaded method to call. The algorithm works conceptually like this:
1. Resolve the set of overloads it is *possible* to call.
- Impossible overloads include those that have too many parameters or have parameters
- of unknown type.
- 2. Filter the set of overloads to only contain those with the closest number of
+ Impossible overloads include those that have too many parameters or have parameters
+ of unknown type.
+ 2. Filter the set of overloads to only contain those with the closest number of
parameters.
For example, if we are called with 3 parameters and there are 2 overloads that
take 2 parameters and one that takes 3, eliminate the 2 parameter overloads.
- 3. Find the best remaining overload based on its match score.
+ 3. Find the best remaining overload based on its match score.
If two or more overloads have the same match score, call the last one. The match
score is constructed by adding the matchScore() result for each of the parameters.
*/
@@ -1037,8 +1037,8 @@ QDeclarativeObjectMethodScriptClass::callOverloaded(MethodData *method, QScriptC
bool unknownArgument = false;
for (int ii = 0; ii < methodArgumentCount; ++ii) {
methodArgTypes[ii] = QMetaType::type(methodArgTypeNames.at(ii));
- if (methodArgTypes[ii] == QVariant::Invalid)
- methodArgTypes[ii] = enumType(method->object->metaObject(),
+ if (methodArgTypes[ii] == QVariant::Invalid)
+ methodArgTypes[ii] = enumType(method->object->metaObject(),
QString::fromLatin1(methodArgTypeNames.at(ii)));
if (methodArgTypes[ii] == QVariant::Invalid) {
unknownArgument = true;
@@ -1074,12 +1074,12 @@ QDeclarativeObjectMethodScriptClass::callOverloaded(MethodData *method, QScriptC
}
/*!
- Returns the match score for converting \a actual to be of type \a conversionType. A
+ Returns the match score for converting \a actual to be of type \a conversionType. A
zero score means "perfect match" whereas a higher score is worse.
The conversion table is copied out of the QtScript callQtMethod() function.
*/
-int QDeclarativeObjectMethodScriptClass::matchScore(const QScriptValue &actual, int conversionType,
+int QDeclarativeObjectMethodScriptClass::matchScore(const QScriptValue &actual, int conversionType,
const QByteArray &conversionTypeName)
{
if (actual.isNumber()) {
@@ -1204,7 +1204,7 @@ static QByteArray QMetaMethod_name(const QMetaMethod &m)
Returns the next related method, if one, or 0.
*/
QDeclarativePropertyCache::Data *
-QDeclarativeObjectMethodScriptClass::relatedMethod(QObject *object, QDeclarativePropertyCache::Data *current,
+QDeclarativeObjectMethodScriptClass::relatedMethod(QObject *object, QDeclarativePropertyCache::Data *current,
QDeclarativePropertyCache::Data &dummy)
{
QDeclarativePropertyCache *cache = QDeclarativeData::get(object)->propertyCache;
@@ -1224,7 +1224,7 @@ QDeclarativeObjectMethodScriptClass::relatedMethod(QObject *object, QDeclarative
QMetaMethod method = mo->method(current->relatedIndex);
dummy.load(method);
-
+
// Look for overloaded methods
QByteArray methodName = QMetaMethod_name(method);
for (int ii = current->relatedIndex - 1; ii >= methodOffset; --ii) {
diff --git a/src/declarative/qml/qdeclarativeobjectscriptclass_p.h b/src/declarative/qml/qdeclarativeobjectscriptclass_p.h
index ad6c70e4..c0ccafc6 100644
--- a/src/declarative/qml/qdeclarativeobjectscriptclass_p.h
+++ b/src/declarative/qml/qdeclarativeobjectscriptclass_p.h
@@ -88,7 +88,7 @@ private:
Value callMethod(QObject *, int index, int returnType, int argCount, int *argTypes, QScriptContext *ctxt);
int matchScore(const QScriptValue &, int, const QByteArray &);
- QDeclarativePropertyCache::Data *relatedMethod(QObject *, QDeclarativePropertyCache::Data *current,
+ QDeclarativePropertyCache::Data *relatedMethod(QObject *, QDeclarativePropertyCache::Data *current,
QDeclarativePropertyCache::Data &dummy);
PersistentIdentifier m_connectId;
@@ -119,8 +119,8 @@ public:
};
Q_DECLARE_FLAGS(QueryHints, QueryHint)
- QScriptClass::QueryFlags queryProperty(QObject *, const Identifier &,
- QScriptClass::QueryFlags flags,
+ QScriptClass::QueryFlags queryProperty(QObject *, const Identifier &,
+ QScriptClass::QueryFlags flags,
QDeclarativeContextData *evalContext,
QueryHints hints = 0);
@@ -132,7 +132,7 @@ public:
virtual bool compare(Object *, Object *);
protected:
- virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
+ virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
QScriptClass::QueryFlags flags);
virtual Value property(Object *, const Identifier &);
diff --git a/src/declarative/qml/qdeclarativeparser.cpp b/src/declarative/qml/qdeclarativeparser.cpp
index dc55e379..a581cc1a 100644
--- a/src/declarative/qml/qdeclarativeparser.cpp
+++ b/src/declarative/qml/qdeclarativeparser.cpp
@@ -70,8 +70,8 @@ QDeclarativeParser::Object::Object()
{
}
-QDeclarativeParser::Object::~Object()
-{
+QDeclarativeParser::Object::~Object()
+{
if (defaultProperty) defaultProperty->release();
if (synthCache) synthCache->release();
foreach(Property *prop, properties)
@@ -190,7 +190,7 @@ QDeclarativeParser::Object::DynamicSignal::DynamicSignal()
}
QDeclarativeParser::Object::DynamicSignal::DynamicSignal(const DynamicSignal &o)
-: name(o.name), parameterTypes(o.parameterTypes),
+: name(o.name), parameterTypes(o.parameterTypes),
parameterNames(o.parameterNames)
{
}
@@ -205,24 +205,24 @@ QDeclarativeParser::Object::DynamicSlot::DynamicSlot(const DynamicSlot &o)
}
QDeclarativeParser::Property::Property()
-: parent(0), type(0), index(-1), value(0), isDefault(true), isDeferred(false),
+: parent(0), type(0), index(-1), value(0), isDefault(true), isDeferred(false),
isValueTypeSubProperty(false), isAlias(false)
{
}
QDeclarativeParser::Property::Property(const QByteArray &n)
-: parent(0), type(0), index(-1), value(0), name(n), isDefault(false),
+: parent(0), type(0), index(-1), value(0), name(n), isDefault(false),
isDeferred(false), isValueTypeSubProperty(false), isAlias(false)
{
}
-QDeclarativeParser::Property::~Property()
-{
+QDeclarativeParser::Property::~Property()
+{
foreach(Value *value, values)
value->release();
foreach(Value *value, onValues)
value->release();
- if (value) value->release();
+ if (value) value->release();
}
QDeclarativeParser::Object *QDeclarativeParser::Property::getValue(const LocationSpan &l)
@@ -251,8 +251,8 @@ QDeclarativeParser::Value::Value()
{
}
-QDeclarativeParser::Value::~Value()
-{
+QDeclarativeParser::Value::~Value()
+{
if (object) object->release();
}
@@ -357,7 +357,7 @@ QString escapedString(const QString &string)
QString QDeclarativeParser::Variant::asScript() const
{
- switch(type()) {
+ switch (type()) {
default:
case Invalid:
return QString();
diff --git a/src/declarative/qml/qdeclarativeparser_p.h b/src/declarative/qml/qdeclarativeparser_p.h
index 7a968f1c..8aeb4b73 100644
--- a/src/declarative/qml/qdeclarativeparser_p.h
+++ b/src/declarative/qml/qdeclarativeparser_p.h
@@ -75,17 +75,17 @@ namespace QDeclarativeJS { namespace AST { class Node; } }
/*
XXX
- These types are created (and owned) by the QDeclarativeXmlParser and consumed by the
+ These types are created (and owned) by the QDeclarativeXmlParser and consumed by the
QDeclarativeCompiler. During the compilation phase the compiler will update some of
the fields for both its own use and for the use of the upcoming QDeclarativeDom API.
- The types are part of the generic sounding "QDeclarativeParser" namespace for legacy
+ The types are part of the generic sounding "QDeclarativeParser" namespace for legacy
reasons (there used to be more in this namespace) and will be cleaned up and
migrated into a more appropriate location shortly.
*/
namespace QDeclarativeParser
{
- struct Location
+ struct Location
{
Location() : line(-1), column(-1) {}
int line;
@@ -116,9 +116,9 @@ namespace QDeclarativeParser
{
public:
Object();
- virtual ~Object();
+ virtual ~Object();
- // Type of the object. The integer is an index into the
+ // Type of the object. The integer is an index into the
// QDeclarativeCompiledData::types array, or -1 if the object is a property
// group.
int type;
@@ -140,9 +140,9 @@ namespace QDeclarativeParser
// Custom parsed data
QByteArray custom;
// Bit mask of the properties assigned bindings
- QByteArray bindingBitmask;
+ QByteArray bindingBitmask;
void setBindingBit(int);
- // Returns the metaobject for this type, or 0 if not available.
+ // Returns the metaobject for this type, or 0 if not available.
// Internally selectd between the metatype and extObject variables
const QMetaObject *metaObject() const;
@@ -178,7 +178,7 @@ namespace QDeclarativeParser
// Script blocks that were nested under this object
struct ScriptBlock {
- enum Pragma {
+ enum Pragma {
None = 0x00000000,
Shared = 0x00000001
};
@@ -189,7 +189,7 @@ namespace QDeclarativeParser
Pragmas pragmas;
};
- // The bytes to cast instances by to get to the QDeclarativeParserStatus
+ // The bytes to cast instances by to get to the QDeclarativeParserStatus
// interface. -1 indicates the type doesn't support this interface.
// Set by the QDeclarativeCompiler.
int parserStatusCast;
@@ -332,7 +332,7 @@ namespace QDeclarativeParser
void addValue(Value *v);
void addOnValue(Value *v);
- // The QVariant::Type of the property, or 0 (QVariant::Invalid) if
+ // The QVariant::Type of the property, or 0 (QVariant::Invalid) if
// unknown.
int type;
// The metaobject index of this property, or -1 if unknown.
@@ -351,14 +351,14 @@ namespace QDeclarativeParser
Object *value;
// The property name
QByteArray name;
- // True if this property was accessed as the default property.
+ // True if this property was accessed as the default property.
bool isDefault;
// True if the setting of this property will be deferred. Set by the
// QDeclarativeCompiler
bool isDeferred;
// True if this property is a value-type pseudo-property
bool isValueTypeSubProperty;
- // True if this property is a property alias. Set by the
+ // True if this property is a property alias. Set by the
// QDeclarativeCompiler
bool isAlias;
diff --git a/src/declarative/qml/qdeclarativeparserstatus.cpp b/src/declarative/qml/qdeclarativeparserstatus.cpp
index d6c0abc7..32b20af6 100644
--- a/src/declarative/qml/qdeclarativeparserstatus.cpp
+++ b/src/declarative/qml/qdeclarativeparserstatus.cpp
@@ -99,7 +99,7 @@ QDeclarativeParserStatus::~QDeclarativeParserStatus()
/*!
\fn void QDeclarativeParserStatus::componentComplete()
- Invoked after the root component that caused this instantiation has
+ Invoked after the root component that caused this instantiation has
completed construction. At this point all static values and binding values
have been assigned to the class.
*/
diff --git a/src/declarative/qml/qdeclarativeprivate.h b/src/declarative/qml/qdeclarativeprivate.h
index 6f95dde7..a1bff9e9 100644
--- a/src/declarative/qml/qdeclarativeprivate.h
+++ b/src/declarative/qml/qdeclarativeprivate.h
@@ -81,8 +81,8 @@ namespace QDeclarativePrivate
class QDeclarativeElement : public T
{
public:
- virtual ~QDeclarativeElement() {
- QDeclarativePrivate::qdeclarativeelement_destructor(this);
+ virtual ~QDeclarativeElement() {
+ QDeclarativePrivate::qdeclarativeelement_destructor(this);
}
};
@@ -126,7 +126,7 @@ namespace QDeclarativePrivate
};
template <typename T, bool hasMember>
- class has_attachedPropertiesMethod
+ class has_attachedPropertiesMethod
{
public:
typedef int yes_type;
@@ -137,7 +137,7 @@ namespace QDeclarativePrivate
static no_type check(...);
static bool const value = sizeof(check(&T::qmlAttachedProperties)) == sizeof(yes_type);
- };
+ };
template <typename T>
class has_attachedPropertiesMethod<T, false>
@@ -241,7 +241,7 @@ namespace QDeclarativePrivate
};
enum RegistrationType {
- TypeRegistration = 0,
+ TypeRegistration = 0,
InterfaceRegistration = 1,
AutoParentRegistration = 2,
ComponentRegistration = 3
diff --git a/src/declarative/qml/qdeclarativeproperty.cpp b/src/declarative/qml/qdeclarativeproperty.cpp
index 219a8a29..faac4e20 100644
--- a/src/declarative/qml/qdeclarativeproperty.cpp
+++ b/src/declarative/qml/qdeclarativeproperty.cpp
@@ -68,12 +68,12 @@ QT_BEGIN_NAMESPACE
\brief The QDeclarativeProperty class abstracts accessing properties on objects created from QML.
As QML uses Qt's meta-type system all of the existing QMetaObject classes can be used to introspect
-and interact with objects created by QML. However, some of the new features provided by QML - such
-as type safety and attached properties - are most easily used through the QDeclarativeProperty class
+and interact with objects created by QML. However, some of the new features provided by QML - such
+as type safety and attached properties - are most easily used through the QDeclarativeProperty class
that simplifies some of their natural complexity.
-Unlike QMetaProperty which represents a property on a class type, QDeclarativeProperty encapsulates
-a property on a specific object instance. To read a property's value, programmers create a
+Unlike QMetaProperty which represents a property on a class type, QDeclarativeProperty encapsulates
+a property on a specific object instance. To read a property's value, programmers create a
QDeclarativeProperty instance and call the read() method. Likewise to write a property value the
write() method is used.
@@ -166,7 +166,7 @@ void QDeclarativePropertyPrivate::initDefault(QObject *obj)
QMetaProperty p = QDeclarativeMetaType::defaultProperty(obj);
core.load(p);
- if (core.isValid())
+ if (core.isValid())
object = obj;
}
@@ -184,7 +184,7 @@ QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name)
Creates a QDeclarativeProperty for the property \a name of \a obj
using the \l{QDeclarativeContext} {context} \a ctxt.
- Creating a QDeclarativeProperty without a context will render some
+ Creating a QDeclarativeProperty without a context will render some
properties - like attached properties - inaccessible.
*/
QDeclarativeProperty::QDeclarativeProperty(QObject *obj, const QString &name, QDeclarativeContext *ctxt)
@@ -237,9 +237,9 @@ void QDeclarativePropertyPrivate::initProperty(QObject *obj, const QString &name
} else {
Q_ASSERT(data->typeNamespace);
if ((ii + 1) == path.count()) return; // No type following the namespace
-
+
++ii; data = data->typeNamespace->data(path.at(ii));
- if (!data || !data->type) return; // Invalid type in namespace
+ if (!data || !data->type) return; // Invalid type in namespace
QDeclarativeAttachedPropertiesFunc func = data->type->attachedPropertiesFunction();
if (!func) return; // Not an attachable type
@@ -250,15 +250,15 @@ void QDeclarativePropertyPrivate::initProperty(QObject *obj, const QString &name
} else {
QDeclarativePropertyCache::Data local;
- QDeclarativePropertyCache::Data *property =
+ QDeclarativePropertyCache::Data *property =
QDeclarativePropertyCache::property(engine, obj, pathName, local);
if (!property) return; // Not a property
- if (property->flags & QDeclarativePropertyCache::Data::IsFunction)
- return; // Not an object property
+ if (property->flags & QDeclarativePropertyCache::Data::IsFunction)
+ return; // Not an object property
if (ii == (path.count() - 2) && QDeclarativeValueTypeFactory::isValueType(property->propType)) {
- // We're now at a value type property. We can use a global valuetypes array as we
+ // We're now at a value type property. We can use a global valuetypes array as we
// never actually use the objects, just look up their properties.
QObject *typeObject = (*qmlValueTypes())[property->propType];
if (!typeObject) return; // Not a value type
@@ -274,9 +274,9 @@ void QDeclarativePropertyPrivate::initProperty(QObject *obj, const QString &name
valueType.valueTypeCoreIdx = idx;
valueType.valueTypePropType = vtProp.userType();
- return;
+ return;
} else {
- if (!(property->flags & QDeclarativePropertyCache::Data::IsQObjectDerived))
+ if (!(property->flags & QDeclarativePropertyCache::Data::IsQObjectDerived))
return; // Not an object property
void *args[] = { &currentObject, 0 };
@@ -308,7 +308,7 @@ void QDeclarativePropertyPrivate::initProperty(QObject *obj, const QString &name
// Property
QDeclarativePropertyCache::Data local;
- QDeclarativePropertyCache::Data *property =
+ QDeclarativePropertyCache::Data *property =
QDeclarativePropertyCache::property(engine, currentObject, terminal, local);
if (property && !(property->flags & QDeclarativePropertyCache::Data::IsFunction)) {
object = currentObject;
@@ -357,7 +357,7 @@ QDeclarativeProperty::PropertyTypeCategory QDeclarativeProperty::propertyTypeCat
return d ? d->propertyTypeCategory() : InvalidCategory;
}
-QDeclarativeProperty::PropertyTypeCategory
+QDeclarativeProperty::PropertyTypeCategory
QDeclarativePropertyPrivate::propertyTypeCategory() const
{
uint type = this->type();
@@ -374,7 +374,7 @@ QDeclarativePropertyPrivate::propertyTypeCategory() const
return QDeclarativeProperty::Object;
else if (core.flags & QDeclarativePropertyCache::Data::IsQList)
return QDeclarativeProperty::List;
- else
+ else
return QDeclarativeProperty::Normal;
} else {
return QDeclarativeProperty::InvalidCategory;
@@ -410,14 +410,14 @@ const char *QDeclarativeProperty::propertyTypeName() const
}
/*!
- Returns true if \a other and this QDeclarativeProperty represent the same
+ Returns true if \a other and this QDeclarativeProperty represent the same
property.
*/
bool QDeclarativeProperty::operator==(const QDeclarativeProperty &other) const
{
if (!d || !other.d)
return false;
- // category is intentially omitted here as it is generated
+ // category is intentially omitted here as it is generated
// from the other members
return d->object == other.d->object &&
d->core == other.d->core &&
@@ -425,7 +425,7 @@ bool QDeclarativeProperty::operator==(const QDeclarativeProperty &other) const
}
/*!
- Returns the QVariant type of the property, or QVariant::Invalid if the
+ Returns the QVariant type of the property, or QVariant::Invalid if the
property has no QVariant type.
*/
int QDeclarativeProperty::propertyType() const
@@ -614,7 +614,7 @@ QMetaProperty QDeclarativeProperty::property() const
}
/*!
- Return the QMetaMethod for this property if it is a SignalProperty,
+ Return the QMetaMethod for this property if it is a SignalProperty,
otherwise returns an invalid QMetaMethod.
*/
QMetaMethod QDeclarativeProperty::method() const
@@ -628,11 +628,11 @@ QMetaMethod QDeclarativeProperty::method() const
}
/*!
- Returns the binding associated with this property, or 0 if no binding
+ Returns the binding associated with this property, or 0 if no binding
exists.
*/
QDeclarativeAbstractBinding *
-QDeclarativePropertyPrivate::binding(const QDeclarativeProperty &that)
+QDeclarativePropertyPrivate::binding(const QDeclarativeProperty &that)
{
if (!that.d || !that.isProperty() || !that.d->object)
return 0;
@@ -655,8 +655,8 @@ QDeclarativePropertyPrivate::binding(const QDeclarativeProperty &that)
*/
QDeclarativeAbstractBinding *
QDeclarativePropertyPrivate::setBinding(const QDeclarativeProperty &that,
- QDeclarativeAbstractBinding *newBinding,
- WriteFlags flags)
+ QDeclarativeAbstractBinding *newBinding,
+ WriteFlags flags)
{
if (!that.d || !that.isProperty() || !that.d->object) {
if (newBinding)
@@ -664,7 +664,7 @@ QDeclarativePropertyPrivate::setBinding(const QDeclarativeProperty &that,
return 0;
}
- return that.d->setBinding(that.d->object, that.d->core.coreIndex,
+ return that.d->setBinding(that.d->object, that.d->core.coreIndex,
that.d->valueType.valueTypeCoreIdx, newBinding, flags);
}
@@ -675,10 +675,10 @@ QDeclarativePropertyPrivate::binding(QObject *object, int coreIndex, int valueTy
if (!data)
return 0;
- QDeclarativePropertyCache::Data *propertyData =
+ QDeclarativePropertyCache::Data *propertyData =
data->propertyCache?data->propertyCache->property(coreIndex):0;
if (propertyData && propertyData->flags & QDeclarativePropertyCache::Data::IsAlias) {
- const QDeclarativeVMEMetaObject *vme =
+ const QDeclarativeVMEMetaObject *vme =
static_cast<const QDeclarativeVMEMetaObject *>(metaObjectForProperty(object->metaObject(), coreIndex));
QObject *aObject = 0; int aCoreIndex = -1; int aValueTypeIndex = -1;
@@ -707,7 +707,7 @@ QDeclarativePropertyPrivate::binding(QObject *object, int coreIndex, int valueTy
return binding;
}
-void QDeclarativePropertyPrivate::findAliasTarget(QObject *object, int bindingIndex,
+void QDeclarativePropertyPrivate::findAliasTarget(QObject *object, int bindingIndex,
QObject **targetObject, int *targetBindingIndex)
{
int coreIndex = bindingIndex & 0xFFFFFF;
@@ -716,10 +716,10 @@ void QDeclarativePropertyPrivate::findAliasTarget(QObject *object, int bindingIn
QDeclarativeData *data = QDeclarativeData::get(object, false);
if (data) {
- QDeclarativePropertyCache::Data *propertyData =
+ QDeclarativePropertyCache::Data *propertyData =
data->propertyCache?data->propertyCache->property(coreIndex):0;
if (propertyData && propertyData->flags & QDeclarativePropertyCache::Data::IsAlias) {
- const QDeclarativeVMEMetaObject *vme =
+ const QDeclarativeVMEMetaObject *vme =
static_cast<const QDeclarativeVMEMetaObject *>(metaObjectForProperty(object->metaObject(), coreIndex));
QObject *aObject = 0; int aCoreIndex = -1; int aValueTypeIndex = -1;
if (vme->aliasTarget(coreIndex, &aObject, &aCoreIndex, &aValueTypeIndex)) {
@@ -727,7 +727,7 @@ void QDeclarativePropertyPrivate::findAliasTarget(QObject *object, int bindingIn
Q_ASSERT(valueTypeIndex == -1 || aValueTypeIndex == -1);
int aBindingIndex = aCoreIndex;
- if (aValueTypeIndex != -1)
+ if (aValueTypeIndex != -1)
aBindingIndex |= aValueTypeIndex << 24;
else if (valueTypeIndex != -1)
aBindingIndex |= valueTypeIndex << 24;
@@ -738,7 +738,7 @@ void QDeclarativePropertyPrivate::findAliasTarget(QObject *object, int bindingIn
}
}
- *targetObject = object;
+ *targetObject = object;
*targetBindingIndex = bindingIndex;
}
@@ -750,10 +750,10 @@ QDeclarativePropertyPrivate::setBinding(QObject *object, int coreIndex, int valu
QDeclarativeAbstractBinding *binding = 0;
if (data) {
- QDeclarativePropertyCache::Data *propertyData =
+ QDeclarativePropertyCache::Data *propertyData =
data->propertyCache?data->propertyCache->property(coreIndex):0;
if (propertyData && propertyData->flags & QDeclarativePropertyCache::Data::IsAlias) {
- const QDeclarativeVMEMetaObject *vme =
+ const QDeclarativeVMEMetaObject *vme =
static_cast<const QDeclarativeVMEMetaObject *>(metaObjectForProperty(object->metaObject(), coreIndex));
QObject *aObject = 0; int aCoreIndex = -1; int aValueTypeIndex = -1;
@@ -772,7 +772,7 @@ QDeclarativePropertyPrivate::setBinding(QObject *object, int coreIndex, int valu
if (data && data->hasBindingBit(coreIndex)) {
binding = data->bindings;
- while (binding && binding->propertyIndex() != coreIndex)
+ while (binding && binding->propertyIndex() != coreIndex)
binding = binding->m_nextBinding;
}
@@ -780,7 +780,7 @@ QDeclarativePropertyPrivate::setBinding(QObject *object, int coreIndex, int valu
if (valueTypeIndex != -1)
index |= (valueTypeIndex << 24);
- if (binding && valueTypeIndex != -1 && binding->bindingType() == QDeclarativeAbstractBinding::ValueTypeProxy)
+ if (binding && valueTypeIndex != -1 && binding->bindingType() == QDeclarativeAbstractBinding::ValueTypeProxy)
binding = static_cast<QDeclarativeValueTypeProxyBinding *>(binding)->binding(index);
if (binding) {
@@ -804,10 +804,10 @@ QDeclarativePropertyPrivate::setBindingNoEnable(QObject *object, int coreIndex,
QDeclarativeAbstractBinding *binding = 0;
if (data) {
- QDeclarativePropertyCache::Data *propertyData =
+ QDeclarativePropertyCache::Data *propertyData =
data->propertyCache?data->propertyCache->property(coreIndex):0;
if (propertyData && propertyData->flags & QDeclarativePropertyCache::Data::IsAlias) {
- const QDeclarativeVMEMetaObject *vme =
+ const QDeclarativeVMEMetaObject *vme =
static_cast<const QDeclarativeVMEMetaObject *>(metaObjectForProperty(object->metaObject(), coreIndex));
QObject *aObject = 0; int aCoreIndex = -1; int aValueTypeIndex = -1;
@@ -826,7 +826,7 @@ QDeclarativePropertyPrivate::setBindingNoEnable(QObject *object, int coreIndex,
if (data && data->hasBindingBit(coreIndex)) {
binding = data->bindings;
- while (binding && binding->propertyIndex() != coreIndex)
+ while (binding && binding->propertyIndex() != coreIndex)
binding = binding->m_nextBinding;
}
@@ -834,20 +834,20 @@ QDeclarativePropertyPrivate::setBindingNoEnable(QObject *object, int coreIndex,
if (valueTypeIndex != -1)
index |= (valueTypeIndex << 24);
- if (binding && valueTypeIndex != -1 && binding->bindingType() == QDeclarativeAbstractBinding::ValueTypeProxy)
+ if (binding && valueTypeIndex != -1 && binding->bindingType() == QDeclarativeAbstractBinding::ValueTypeProxy)
binding = static_cast<QDeclarativeValueTypeProxyBinding *>(binding)->binding(index);
- if (binding)
+ if (binding)
binding->removeFromObject();
- if (newBinding)
+ if (newBinding)
newBinding->addToObject(object, index);
return binding;
}
/*!
- Returns the expression associated with this signal property, or 0 if no
+ Returns the expression associated with this signal property, or 0 if no
signal expression exists.
*/
QDeclarativeExpression *
@@ -857,12 +857,12 @@ QDeclarativePropertyPrivate::signalExpression(const QDeclarativeProperty &that)
return 0;
const QObjectList &children = that.d->object->children();
-
+
for (int ii = 0; ii < children.count(); ++ii) {
QObject *child = children.at(ii);
QDeclarativeBoundSignal *signal = QDeclarativeBoundSignal::cast(child);
- if (signal && signal->index() == that.index())
+ if (signal && signal->index() == that.index())
return signal->expression();
}
@@ -878,7 +878,7 @@ QDeclarativePropertyPrivate::signalExpression(const QDeclarativeProperty &that)
*/
QDeclarativeExpression *
QDeclarativePropertyPrivate::setSignalExpression(const QDeclarativeProperty &that,
- QDeclarativeExpression *expr)
+ QDeclarativeExpression *expr)
{
if (!(that.type() & QDeclarativeProperty::SignalProperty)) {
delete expr;
@@ -886,12 +886,12 @@ QDeclarativePropertyPrivate::setSignalExpression(const QDeclarativeProperty &tha
}
const QObjectList &children = that.d->object->children();
-
+
for (int ii = 0; ii < children.count(); ++ii) {
QObject *child = children.at(ii);
QDeclarativeBoundSignal *signal = QDeclarativeBoundSignal::cast(child);
- if (signal && signal->index() == that.index())
+ if (signal && signal->index() == that.index())
return signal->setExpression(expr);
}
@@ -955,7 +955,7 @@ QVariant QDeclarativeProperty::read(QObject *object, const QString &name, QDecla
}
/*!
-
+
Return the \a name property value of \a object using the environment
for instantiating QML components that is provided by \a engine. .
This method is equivalent to:
@@ -994,7 +994,7 @@ QVariant QDeclarativePropertyPrivate::readValueProperty()
QDeclarativeListProperty<QObject> prop;
void *args[] = { &prop, 0 };
QMetaObject::metacall(object, QMetaObject::ReadProperty, core.coreIndex, args);
- return QVariant::fromValue(QDeclarativeListReferencePrivate::init(prop, core.propType, engine));
+ return QVariant::fromValue(QDeclarativeListReferencePrivate::init(prop, core.propType, engine));
} else if (core.flags & QDeclarativePropertyCache::Data::IsQObjectDerived) {
@@ -1089,8 +1089,8 @@ bool QDeclarativePropertyPrivate::writeValueProperty(const QVariant &value, Writ
return rv;
}
-bool QDeclarativePropertyPrivate::write(QObject *object, const QDeclarativePropertyCache::Data &property,
- const QVariant &value, QDeclarativeContextData *context,
+bool QDeclarativePropertyPrivate::write(QObject *object, const QDeclarativePropertyCache::Data &property,
+ const QVariant &value, QDeclarativeContextData *context,
WriteFlags flags)
{
int coreIdx = property.coreIndex;
@@ -1100,7 +1100,7 @@ bool QDeclarativePropertyPrivate::write(QObject *object, const QDeclarativePrope
QMetaProperty prop = object->metaObject()->property(property.coreIndex);
QVariant v = value;
// Enum values come through the script engine as doubles
- if (value.userType() == QVariant::Double) {
+ if (value.userType() == QVariant::Double) {
double integral;
double fractional = modf(value.toDouble(), &integral);
if (qFuzzyIsNull(fractional))
@@ -1151,7 +1151,7 @@ bool QDeclarativePropertyPrivate::write(QObject *object, const QDeclarativePrope
} else if (property.flags & QDeclarativePropertyCache::Data::IsQObjectDerived) {
const QMetaObject *valMo = rawMetaObjectForType(enginePriv, value.userType());
-
+
if (!valMo)
return false;
@@ -1162,14 +1162,14 @@ bool QDeclarativePropertyPrivate::write(QObject *object, const QDeclarativePrope
if (canConvert(valMo, propMo)) {
void *args[] = { &o, 0, &status, &flags };
- QMetaObject::metacall(object, QMetaObject::WriteProperty, coreIdx,
+ QMetaObject::metacall(object, QMetaObject::WriteProperty, coreIdx,
args);
} else if (!o && canConvert(propMo, valMo)) {
- // In the case of a null QObject, we assign the null if there is
- // any change that the null variant type could be up or down cast to
+ // In the case of a null QObject, we assign the null if there is
+ // any change that the null variant type could be up or down cast to
// the property type.
void *args[] = { &o, 0, &status, &flags };
- QMetaObject::metacall(object, QMetaObject::WriteProperty, coreIdx,
+ QMetaObject::metacall(object, QMetaObject::WriteProperty, coreIdx,
args);
} else {
return false;
@@ -1289,7 +1289,7 @@ bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVa
*/
bool QDeclarativeProperty::write(QObject *object,
const QString &name,
- const QVariant &value,
+ const QVariant &value,
QDeclarativeContext *ctxt)
{
QDeclarativeProperty p(object, name, ctxt);
@@ -1297,7 +1297,7 @@ bool QDeclarativeProperty::write(QObject *object,
}
/*!
-
+
Writes \a value to the \a name property of \a object using the
environment for instantiating QML components that is provided by
\a engine. This method is equivalent to:
@@ -1307,7 +1307,7 @@ bool QDeclarativeProperty::write(QObject *object,
p.write(value);
\endcode
*/
-bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVariant &value,
+bool QDeclarativeProperty::write(QObject *object, const QString &name, const QVariant &value,
QDeclarativeEngine *engine)
{
QDeclarativeProperty p(object, name, engine);
@@ -1331,14 +1331,14 @@ bool QDeclarativeProperty::reset() const
}
bool QDeclarativePropertyPrivate::write(const QDeclarativeProperty &that,
- const QVariant &value, WriteFlags flags)
+ const QVariant &value, WriteFlags flags)
{
if (!that.d)
return false;
- if (that.d->object && that.type() & QDeclarativeProperty::Property &&
- that.d->core.isValid() && that.isWritable())
+ if (that.d->object && that.type() & QDeclarativeProperty::Property &&
+ that.d->core.isValid() && that.isWritable())
return that.d->writeValueProperty(value, flags);
- else
+ else
return false;
}
@@ -1357,7 +1357,7 @@ bool QDeclarativeProperty::hasNotifySignal() const
Returns true if the property needs a change notifier signal for bindings
to remain upto date, false otherwise.
- Some properties, such as attached properties or those whose value never
+ Some properties, such as attached properties or those whose value never
changes, do not require a change notifier.
*/
bool QDeclarativeProperty::needsNotifySignal() const
@@ -1444,7 +1444,7 @@ struct ValueTypeSerializedData : public SerializedData {
QDeclarativePropertyCache::ValueTypeData valueType;
};
-QByteArray QDeclarativePropertyPrivate::saveValueType(const QMetaObject *metaObject, int index,
+QByteArray QDeclarativePropertyPrivate::saveValueType(const QMetaObject *metaObject, int index,
const QMetaObject *subObject, int subIndex)
{
QMetaProperty subProp = subObject->property(subIndex);
@@ -1473,7 +1473,7 @@ QByteArray QDeclarativePropertyPrivate::saveProperty(const QMetaObject *metaObje
return rv;
}
-QDeclarativeProperty
+QDeclarativeProperty
QDeclarativePropertyPrivate::restore(const QByteArray &data, QObject *object, QDeclarativeContextData *ctxt)
{
QDeclarativeProperty prop;
@@ -1528,7 +1528,7 @@ bool QDeclarativePropertyPrivate::canConvert(const QMetaObject *from, const QMet
return true;
from = from->superClass();
}
-
+
return false;
}
@@ -1607,7 +1607,7 @@ static inline void flush_vme_signal(const QObject *object, int index)
methodOffset -= QMetaObject_methods(metaObject);
}
- QDeclarativeVMEMetaObject *vme =
+ QDeclarativeVMEMetaObject *vme =
static_cast<QDeclarativeVMEMetaObject *>(const_cast<QMetaObject *>(metaObject));
vme->connectAliasSignal(index);
@@ -1616,7 +1616,7 @@ static inline void flush_vme_signal(const QObject *object, int index)
}
/*!
-Connect \a sender \a signal_index to \a receiver \a method_index with the specified
+Connect \a sender \a signal_index to \a receiver \a method_index with the specified
\a type and \a types. This behaves identically to QMetaObject::connect() except that
it connects any lazy "proxy" signal connections set up by QML.
diff --git a/src/declarative/qml/qdeclarativeproperty.h b/src/declarative/qml/qdeclarativeproperty.h
index a6ae48d5..15424247 100644
--- a/src/declarative/qml/qdeclarativeproperty.h
+++ b/src/declarative/qml/qdeclarativeproperty.h
@@ -65,7 +65,7 @@ public:
Normal
};
- enum Type {
+ enum Type {
Invalid,
Property,
SignalProperty
diff --git a/src/declarative/qml/qdeclarativeproperty_p.h b/src/declarative/qml/qdeclarativeproperty_p.h
index 6817023a..1091d386 100644
--- a/src/declarative/qml/qdeclarativeproperty_p.h
+++ b/src/declarative/qml/qdeclarativeproperty_p.h
@@ -82,7 +82,7 @@ public:
QDeclarativePropertyCache::Data core;
QString nameCache;
- // Describes the "virtual" value-type sub-property.
+ // Describes the "virtual" value-type sub-property.
QDeclarativePropertyCache::ValueTypeData valueType;
void initProperty(QObject *obj, const QString &name);
@@ -97,9 +97,9 @@ public:
bool writeValueProperty(const QVariant &, WriteFlags);
static const QMetaObject *rawMetaObjectForType(QDeclarativeEnginePrivate *, int);
- static bool writeEnumProperty(const QMetaProperty &prop, int idx, QObject *object,
+ static bool writeEnumProperty(const QMetaProperty &prop, int idx, QObject *object,
const QVariant &value, int flags);
- static bool write(QObject *, const QDeclarativePropertyCache::Data &, const QVariant &,
+ static bool write(QObject *, const QDeclarativePropertyCache::Data &, const QVariant &,
QDeclarativeContextData *, WriteFlags flags = 0);
static void findAliasTarget(QObject *, int, QObject **, int *);
static QDeclarativeAbstractBinding *setBinding(QObject *, int coreIndex, int valueTypeIndex /* -1 */,
@@ -109,7 +109,7 @@ public:
QDeclarativeAbstractBinding *);
static QDeclarativeAbstractBinding *binding(QObject *, int coreIndex, int valueTypeIndex /* -1 */);
- static QByteArray saveValueType(const QMetaObject *, int,
+ static QByteArray saveValueType(const QMetaObject *, int,
const QMetaObject *, int);
static QByteArray saveProperty(const QMetaObject *, int);
@@ -128,7 +128,7 @@ public:
QDeclarativeAbstractBinding *,
WriteFlags flags = DontRemoveBinding);
static QDeclarativeExpression *signalExpression(const QDeclarativeProperty &that);
- static QDeclarativeExpression *setSignalExpression(const QDeclarativeProperty &that,
+ static QDeclarativeExpression *setSignalExpression(const QDeclarativeProperty &that,
QDeclarativeExpression *) ;
static bool write(const QDeclarativeProperty &that, const QVariant &, WriteFlags);
static int valueTypeCoreIndex(const QDeclarativeProperty &that);
diff --git a/src/declarative/qml/qdeclarativepropertycache.cpp b/src/declarative/qml/qdeclarativepropertycache.cpp
index 79fbbe03..106bfb3a 100644
--- a/src/declarative/qml/qdeclarativepropertycache.cpp
+++ b/src/declarative/qml/qdeclarativepropertycache.cpp
@@ -49,7 +49,7 @@ Q_DECLARE_METATYPE(QScriptValue)
QT_BEGIN_NAMESPACE
-QDeclarativePropertyCache::Data::Flags QDeclarativePropertyCache::Data::flagsForProperty(const QMetaProperty &p, QDeclarativeEngine *engine)
+QDeclarativePropertyCache::Data::Flags QDeclarativePropertyCache::Data::flagsForProperty(const QMetaProperty &p, QDeclarativeEngine *engine)
{
int propType = p.userType();
@@ -139,19 +139,19 @@ void QDeclarativePropertyCache::clear()
for (int ii = 0; ii < methodIndexCache.count(); ++ii) {
RData *data = methodIndexCache.at(ii);
- if (data) data->release();
+ if (data) data->release();
}
- for (StringCache::ConstIterator iter = stringCache.begin();
+ for (StringCache::ConstIterator iter = stringCache.begin();
iter != stringCache.end(); ++iter) {
RData *data = (*iter);
- data->release();
+ data->release();
}
- for (IdentifierCache::ConstIterator iter = identifierCache.begin();
+ for (IdentifierCache::ConstIterator iter = identifierCache.begin();
iter != identifierCache.end(); ++iter) {
RData *data = (*iter);
- data->release();
+ data->release();
}
indexCache.clear();
@@ -160,7 +160,7 @@ void QDeclarativePropertyCache::clear()
identifierCache.clear();
}
-QDeclarativePropertyCache::Data QDeclarativePropertyCache::create(const QMetaObject *metaObject,
+QDeclarativePropertyCache::Data QDeclarativePropertyCache::create(const QMetaObject *metaObject,
const QString &property)
{
Q_ASSERT(metaObject);
@@ -230,14 +230,14 @@ QDeclarativePropertyCache *QDeclarativePropertyCache::copy() const
return cache;
}
-void QDeclarativePropertyCache::append(QDeclarativeEngine *engine, const QMetaObject *metaObject,
+void QDeclarativePropertyCache::append(QDeclarativeEngine *engine, const QMetaObject *metaObject,
Data::Flag propertyFlags, Data::Flag methodFlags, Data::Flag signalFlags)
{
append(engine, metaObject, -1, propertyFlags, methodFlags, signalFlags);
}
-void QDeclarativePropertyCache::append(QDeclarativeEngine *engine, const QMetaObject *metaObject,
- int revision,
+void QDeclarativePropertyCache::append(QDeclarativeEngine *engine, const QMetaObject *metaObject,
+ int revision,
Data::Flag propertyFlags, Data::Flag methodFlags, Data::Flag signalFlags)
{
Q_UNUSED(revision);
@@ -252,7 +252,7 @@ void QDeclarativePropertyCache::append(QDeclarativeEngine *engine, const QMetaOb
methodIndexCache.resize(methodCount);
for (int ii = methodOffset; ii < methodCount; ++ii) {
QMetaMethod m = metaObject->method(ii);
- if (m.access() == QMetaMethod::Private)
+ if (m.access() == QMetaMethod::Private)
continue;
QString methodName = QString::fromUtf8(m.methodSignature());
@@ -262,10 +262,10 @@ void QDeclarativePropertyCache::append(QDeclarativeEngine *engine, const QMetaOb
RData *data = new RData;
data->identifier = enginePriv->objectClass->createPersistentIdentifier(methodName);
- methodIndexCache[ii] = data;
+ methodIndexCache[ii] = data;
data->load(m);
- if (m.methodType() == QMetaMethod::Slot || m.methodType() == QMetaMethod::Method)
+ if (m.methodType() == QMetaMethod::Slot || m.methodType() == QMetaMethod::Method)
data->flags |= methodFlags;
else if (m.methodType() == QMetaMethod::Signal)
data->flags |= signalFlags;
@@ -404,7 +404,7 @@ QStringList QDeclarativePropertyCache::propertyNames() const
return stringCache.keys();
}
-QDeclarativePropertyCache::Data *QDeclarativePropertyCache::property(QDeclarativeEngine *engine, QObject *obj,
+QDeclarativePropertyCache::Data *QDeclarativePropertyCache::property(QDeclarativeEngine *engine, QObject *obj,
const QScriptDeclarativeClass::Identifier &name, Data &local)
{
QDeclarativePropertyCache::Data *rv = 0;
@@ -431,7 +431,7 @@ QDeclarativePropertyCache::Data *QDeclarativePropertyCache::property(QDeclarativ
return rv;
}
-QDeclarativePropertyCache::Data *QDeclarativePropertyCache::property(QDeclarativeEngine *engine, QObject *obj,
+QDeclarativePropertyCache::Data *QDeclarativePropertyCache::property(QDeclarativeEngine *engine, QObject *obj,
const QString &name, Data &local)
{
QDeclarativePropertyCache::Data *rv = 0;
diff --git a/src/declarative/qml/qdeclarativepropertycache_p.h b/src/declarative/qml/qdeclarativepropertycache_p.h
index 4cddc371..ff231f57 100644
--- a/src/declarative/qml/qdeclarativepropertycache_p.h
+++ b/src/declarative/qml/qdeclarativepropertycache_p.h
@@ -73,10 +73,10 @@ public:
virtual ~QDeclarativePropertyCache();
struct Data {
- inline Data();
+ inline Data();
inline bool operator==(const Data &);
- enum Flag {
+ enum Flag {
NoFlags = 0x00000000,
// Can apply to all properties, except IsFunction
@@ -101,7 +101,7 @@ public:
};
Q_DECLARE_FLAGS(Flags, Flag)
- bool isValid() const { return coreIndex != -1; }
+ bool isValid() const { return coreIndex != -1; }
Flags flags;
int propType;
@@ -112,7 +112,7 @@ public:
};
uint overrideIndexIsProperty : 1;
signed int overrideIndex : 31;
- int revision;
+ int revision;
int metaObjectOffset;
static Flags flagsForProperty(const QMetaProperty &, QDeclarativeEngine *engine = 0);
@@ -159,7 +159,7 @@ protected:
private:
friend class QDeclarativeEnginePrivate;
- struct RData : public Data, public QDeclarativeRefCount {
+ struct RData : public Data, public QDeclarativeRefCount {
QScriptDeclarativeClass::PersistentIdentifier identifier;
};
@@ -178,7 +178,7 @@ private:
AllowedRevisionCache allowedRevisionCache;
};
Q_DECLARE_OPERATORS_FOR_FLAGS(QDeclarativePropertyCache::Data::Flags);
-
+
QDeclarativePropertyCache::Data::Data()
: flags(0), propType(0), coreIndex(-1), notifyIndex(-1), overrideIndexIsProperty(false), overrideIndex(-1),
revision(0), metaObjectOffset(-1)
@@ -207,21 +207,21 @@ QDeclarativePropertyCache::overrideData(Data *data) const
}
QDeclarativePropertyCache::Data *
-QDeclarativePropertyCache::property(const QScriptDeclarativeClass::Identifier &id) const
+QDeclarativePropertyCache::property(const QScriptDeclarativeClass::Identifier &id) const
{
return identifierCache.value(id);
}
QDeclarativePropertyCache::ValueTypeData::ValueTypeData()
-: flags(QDeclarativePropertyCache::Data::NoFlags), valueTypeCoreIdx(-1), valueTypePropType(0)
+: flags(QDeclarativePropertyCache::Data::NoFlags), valueTypeCoreIdx(-1), valueTypePropType(0)
{
}
-bool QDeclarativePropertyCache::ValueTypeData::operator==(const ValueTypeData &o)
-{
+bool QDeclarativePropertyCache::ValueTypeData::operator==(const ValueTypeData &o)
+{
return flags == o.flags &&
valueTypeCoreIdx == o.valueTypeCoreIdx &&
- valueTypePropType == o.valueTypePropType;
+ valueTypePropType == o.valueTypePropType;
}
bool QDeclarativePropertyCache::isAllowedInRevision(Data *data) const
diff --git a/src/declarative/qml/qdeclarativeproxymetaobject.cpp b/src/declarative/qml/qdeclarativeproxymetaobject.cpp
index 144f1559..44950bf4 100644
--- a/src/declarative/qml/qdeclarativeproxymetaobject.cpp
+++ b/src/declarative/qml/qdeclarativeproxymetaobject.cpp
@@ -78,7 +78,7 @@ int QDeclarativeProxyMetaObject::metaCall(QMetaObject::Call c, int id, void **a)
if (id >= data.propertyOffset) {
if (!proxies) {
proxies = new QObject*[metaObjects->count()];
- ::memset(proxies, 0,
+ ::memset(proxies, 0,
sizeof(QObject *) * metaObjects->count());
}
@@ -93,7 +93,7 @@ int QDeclarativeProxyMetaObject::metaCall(QMetaObject::Call c, int id, void **a)
// ### - Can this be done more optimally?
for (int jj = 0; jj < methods; ++jj) {
- QMetaMethod method =
+ QMetaMethod method =
metaObject->method(jj + methodOffset);
if (method.methodType() == QMetaMethod::Signal)
QDeclarativePropertyPrivate::connect(proxy, methodOffset + jj, object, localOffset + jj);
diff --git a/src/declarative/qml/qdeclarativerewrite.cpp b/src/declarative/qml/qdeclarativerewrite.cpp
index b9303cf5..148ada11 100644
--- a/src/declarative/qml/qdeclarativerewrite.cpp
+++ b/src/declarative/qml/qdeclarativerewrite.cpp
@@ -59,7 +59,7 @@ bool SharedBindingTester::isSharable(const QString &code)
Parser parser(&engine);
lexer.setCode(code, 0);
parser.parseStatement();
- if (!parser.statement())
+ if (!parser.statement())
return false;
return isSharable(parser.statement());
diff --git a/src/declarative/qml/qdeclarativerewrite_p.h b/src/declarative/qml/qdeclarativerewrite_p.h
index d66016df..e3da88c0 100644
--- a/src/declarative/qml/qdeclarativerewrite_p.h
+++ b/src/declarative/qml/qdeclarativerewrite_p.h
@@ -69,7 +69,7 @@ class SharedBindingTester : protected AST::Visitor
public:
bool isSharable(const QString &code);
bool isSharable(AST::Node *Node);
-
+
virtual bool visit(AST::FunctionDeclaration *) { _sharable = false; return false; }
virtual bool visit(AST::FunctionExpression *) { _sharable = false; return false; }
virtual bool visit(AST::CallExpression *) { _sharable = false; return false; }
diff --git a/src/declarative/qml/qdeclarativescriptparser.cpp b/src/declarative/qml/qdeclarativescriptparser.cpp
index 9a087e0b..8012bd9e 100644
--- a/src/declarative/qml/qdeclarativescriptparser.cpp
+++ b/src/declarative/qml/qdeclarativescriptparser.cpp
@@ -286,7 +286,7 @@ ProcessAST::defineObjectBinding(AST::UiQualifiedId *propertyName,
if (lastTypeDot >= 0)
resolvableObjectType.replace(QLatin1Char('.'),QLatin1Char('/'));
- QDeclarativeParser::Object *obj = new QDeclarativeParser::Object;
+ QDeclarativeParser::Object *obj = new QDeclarativeParser::Object;
QDeclarativeScriptParser::TypeReference *typeRef = _parser->findOrCreateType(resolvableObjectType);
obj->type = typeRef->id;
@@ -505,7 +505,7 @@ bool ProcessAST::visit(AST::UiPublicMember *node)
_parser->_errors << error;
return false;
}
-
+
signal.parameterTypes << qtType;
signal.parameterNames << p->name->asString().toUtf8();
p = p->finish();
@@ -636,7 +636,7 @@ bool ProcessAST::visit(AST::UiObjectBinding *node)
const QString objectType = asString(node->qualifiedTypeNameId);
const AST::SourceLocation typeLocation = node->qualifiedTypeNameId->identifierToken;
- defineObjectBinding(node->qualifiedId, node->hasOnToken, objectType,
+ defineObjectBinding(node->qualifiedId, node->hasOnToken, objectType,
typeLocation, l, node->initializer);
return false;
@@ -888,7 +888,7 @@ QList<QDeclarativeError> QDeclarativeScriptParser::errors() const
return _errors;
}
-static void replaceWithSpace(QString &str, int idx, int n)
+static void replaceWithSpace(QString &str, int idx, int n)
{
QChar *data = str.data() + idx;
const QChar space(QLatin1Char(' '));
@@ -954,42 +954,42 @@ QDeclarativeParser::Object::ScriptBlock::Pragmas QDeclarativeScriptParser::extra
#define CHECK_TOKEN(t) if (token != QDeclarativeJSGrammar:: t) return rv;
static const int uriTokens[] = {
- QDeclarativeJSGrammar::T_IDENTIFIER,
- QDeclarativeJSGrammar::T_PROPERTY,
- QDeclarativeJSGrammar::T_SIGNAL,
- QDeclarativeJSGrammar::T_READONLY,
- QDeclarativeJSGrammar::T_ON,
- QDeclarativeJSGrammar::T_BREAK,
- QDeclarativeJSGrammar::T_CASE,
- QDeclarativeJSGrammar::T_CATCH,
- QDeclarativeJSGrammar::T_CONTINUE,
- QDeclarativeJSGrammar::T_DEFAULT,
- QDeclarativeJSGrammar::T_DELETE,
- QDeclarativeJSGrammar::T_DO,
- QDeclarativeJSGrammar::T_ELSE,
- QDeclarativeJSGrammar::T_FALSE,
- QDeclarativeJSGrammar::T_FINALLY,
- QDeclarativeJSGrammar::T_FOR,
- QDeclarativeJSGrammar::T_FUNCTION,
- QDeclarativeJSGrammar::T_IF,
- QDeclarativeJSGrammar::T_IN,
- QDeclarativeJSGrammar::T_INSTANCEOF,
- QDeclarativeJSGrammar::T_NEW,
- QDeclarativeJSGrammar::T_NULL,
- QDeclarativeJSGrammar::T_RETURN,
- QDeclarativeJSGrammar::T_SWITCH,
- QDeclarativeJSGrammar::T_THIS,
- QDeclarativeJSGrammar::T_THROW,
- QDeclarativeJSGrammar::T_TRUE,
- QDeclarativeJSGrammar::T_TRY,
- QDeclarativeJSGrammar::T_TYPEOF,
- QDeclarativeJSGrammar::T_VAR,
- QDeclarativeJSGrammar::T_VOID,
- QDeclarativeJSGrammar::T_WHILE,
- QDeclarativeJSGrammar::T_CONST,
- QDeclarativeJSGrammar::T_DEBUGGER,
- QDeclarativeJSGrammar::T_RESERVED_WORD,
- QDeclarativeJSGrammar::T_WITH,
+ QDeclarativeJSGrammar::T_IDENTIFIER,
+ QDeclarativeJSGrammar::T_PROPERTY,
+ QDeclarativeJSGrammar::T_SIGNAL,
+ QDeclarativeJSGrammar::T_READONLY,
+ QDeclarativeJSGrammar::T_ON,
+ QDeclarativeJSGrammar::T_BREAK,
+ QDeclarativeJSGrammar::T_CASE,
+ QDeclarativeJSGrammar::T_CATCH,
+ QDeclarativeJSGrammar::T_CONTINUE,
+ QDeclarativeJSGrammar::T_DEFAULT,
+ QDeclarativeJSGrammar::T_DELETE,
+ QDeclarativeJSGrammar::T_DO,
+ QDeclarativeJSGrammar::T_ELSE,
+ QDeclarativeJSGrammar::T_FALSE,
+ QDeclarativeJSGrammar::T_FINALLY,
+ QDeclarativeJSGrammar::T_FOR,
+ QDeclarativeJSGrammar::T_FUNCTION,
+ QDeclarativeJSGrammar::T_IF,
+ QDeclarativeJSGrammar::T_IN,
+ QDeclarativeJSGrammar::T_INSTANCEOF,
+ QDeclarativeJSGrammar::T_NEW,
+ QDeclarativeJSGrammar::T_NULL,
+ QDeclarativeJSGrammar::T_RETURN,
+ QDeclarativeJSGrammar::T_SWITCH,
+ QDeclarativeJSGrammar::T_THIS,
+ QDeclarativeJSGrammar::T_THROW,
+ QDeclarativeJSGrammar::T_TRUE,
+ QDeclarativeJSGrammar::T_TRY,
+ QDeclarativeJSGrammar::T_TYPEOF,
+ QDeclarativeJSGrammar::T_VAR,
+ QDeclarativeJSGrammar::T_VOID,
+ QDeclarativeJSGrammar::T_WHILE,
+ QDeclarativeJSGrammar::T_CONST,
+ QDeclarativeJSGrammar::T_DEBUGGER,
+ QDeclarativeJSGrammar::T_RESERVED_WORD,
+ QDeclarativeJSGrammar::T_WITH,
QDeclarativeJSGrammar::EOF_SYMBOL
};
diff --git a/src/declarative/qml/qdeclarativescriptparser_p.h b/src/declarative/qml/qdeclarativescriptparser_p.h
index 42a29752..40725652 100644
--- a/src/declarative/qml/qdeclarativescriptparser_p.h
+++ b/src/declarative/qml/qdeclarativescriptparser_p.h
@@ -111,7 +111,7 @@ public:
class JavaScriptMetaData {
public:
- JavaScriptMetaData()
+ JavaScriptMetaData()
: pragmas(QDeclarativeParser::Object::ScriptBlock::None) {}
QDeclarativeParser::Object::ScriptBlock::Pragmas pragmas;
diff --git a/src/declarative/qml/qdeclarativetypeloader.cpp b/src/declarative/qml/qdeclarativetypeloader.cpp
index 42847ea9..1d8da8f2 100644
--- a/src/declarative/qml/qdeclarativetypeloader.cpp
+++ b/src/declarative/qml/qdeclarativetypeloader.cpp
@@ -246,8 +246,8 @@ QList<QDeclarativeError> QDeclarativeDataBlob::errors() const
/*!
Mark this blob as having \a errors.
-All outstanding dependencies will be cancelled. Requests to add new dependencies
-will be ignored. Entry into the Error state is irreversable, although you can change the
+All outstanding dependencies will be cancelled. Requests to add new dependencies
+will be ignored. Entry into the Error state is irreversable, although you can change the
specific errors by additional calls to setError.
*/
void QDeclarativeDataBlob::setError(const QDeclarativeError &errors)
@@ -271,8 +271,8 @@ void QDeclarativeDataBlob::setError(const QList<QDeclarativeError> &errors)
tryDone();
}
-/*!
-Wait for \a blob to become complete or to error. If \a blob is already
+/*!
+Wait for \a blob to become complete or to error. If \a blob is already
complete or in error, or this blob is already complete, this has no effect.
*/
void QDeclarativeDataBlob::addDependency(QDeclarativeDataBlob *blob)
@@ -300,7 +300,7 @@ or addDependency().
*/
/*!
-Invoked once data has either been received or a network error occurred, and all
+Invoked once data has either been received or a network error occurred, and all
dependencies are complete.
You can set an error in this method, but you cannot add new dependencies. Implementors
@@ -365,7 +365,7 @@ void QDeclarativeDataBlob::networkError(QNetworkReply::NetworkError networkError
setError(error);
}
-/*!
+/*!
Called if \a blob, which was previously waited for, has an error.
The default implementation does nothing.
@@ -385,9 +385,9 @@ void QDeclarativeDataBlob::dependencyComplete(QDeclarativeDataBlob *blob)
Q_UNUSED(blob);
}
-/*!
-Called when all blobs waited for have completed. This occurs regardless of
-whether they are in error, or complete state.
+/*!
+Called when all blobs waited for have completed. This occurs regardless of
+whether they are in error, or complete state.
The default implementation does nothing.
*/
@@ -456,7 +456,7 @@ void QDeclarativeDataBlob::notifyComplete(QDeclarativeDataBlob *blob)
m_waitingFor.removeOne(blob);
blob->release();
- if (!isError() && m_waitingFor.isEmpty())
+ if (!isError() && m_waitingFor.isEmpty())
allDependenciesDone();
m_inCallback = false;
@@ -477,7 +477,7 @@ The loader then fetches the data over the network or from the local file system
QDeclarativeDataBlob is an abstract class, so should always be specialized.
Once data is received, the QDeclarativeDataBlob::dataReceived() method is invoked on the blob. The
-derived class should use this callback to process the received data. Processing of the data can
+derived class should use this callback to process the received data. Processing of the data can
result in an error being set (QDeclarativeDataBlob::setError()), or one or more dependencies being
created (QDeclarativeDataBlob::addDependency()). Dependencies are other QDeclarativeDataBlob's that
are required before processing can fully complete.
@@ -505,7 +505,7 @@ QDeclarativeDataLoader::QDeclarativeDataLoader(QDeclarativeEngine *engine)
/*! \internal */
QDeclarativeDataLoader::~QDeclarativeDataLoader()
{
- for (NetworkReplies::Iterator iter = m_networkReplies.begin(); iter != m_networkReplies.end(); ++iter)
+ for (NetworkReplies::Iterator iter = m_networkReplies.begin(); iter != m_networkReplies.end(); ++iter)
(*iter)->release();
}
@@ -636,7 +636,7 @@ void QDeclarativeDataLoader::loadWithStaticData(QDeclarativeDataBlob *blob, cons
{
Q_ASSERT(blob->status() == QDeclarativeDataBlob::Null);
Q_ASSERT(blob->m_manager == 0);
-
+
blob->m_status = QDeclarativeDataBlob::Loading;
setData(blob, data);
@@ -659,7 +659,7 @@ void QDeclarativeDataLoader::setData(QDeclarativeDataBlob *blob, const QByteArra
if (!blob->isError() && !blob->isWaiting())
blob->allDependenciesDone();
- if (blob->status() != QDeclarativeDataBlob::Error)
+ if (blob->status() != QDeclarativeDataBlob::Error)
blob->m_status = QDeclarativeDataBlob::WaitingForDependencies;
blob->m_inCallback = false;
@@ -700,8 +700,8 @@ Returns a QDeclarativeTypeData for the specified \a url. The QDeclarativeTypeDa
*/
QDeclarativeTypeData *QDeclarativeTypeLoader::get(const QUrl &url)
{
- Q_ASSERT(!url.isRelative() &&
- (QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url).isEmpty() ||
+ Q_ASSERT(!url.isRelative() &&
+ (QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url).isEmpty() ||
!QDir::isRelativePath(QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url))));
QDeclarativeTypeData *typeData = m_typeCache.value(url);
@@ -717,7 +717,7 @@ QDeclarativeTypeData *QDeclarativeTypeLoader::get(const QUrl &url)
}
/*!
-Returns a QDeclarativeTypeData for the given \a data with the provided base \a url. The
+Returns a QDeclarativeTypeData for the given \a data with the provided base \a url. The
QDeclarativeTypeData will not be cached.
The specified \a options control how the loader handles type data.
@@ -734,8 +734,8 @@ Returns a QDeclarativeScriptData for \a url. The QDeclarativeScriptData may be
*/
QDeclarativeScriptData *QDeclarativeTypeLoader::getScript(const QUrl &url)
{
- Q_ASSERT(!url.isRelative() &&
- (QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url).isEmpty() ||
+ Q_ASSERT(!url.isRelative() &&
+ (QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url).isEmpty() ||
!QDir::isRelativePath(QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url))));
QDeclarativeScriptData *scriptData = m_scriptCache.value(url);
@@ -755,8 +755,8 @@ Returns a QDeclarativeQmldirData for \a url. The QDeclarativeQmldirData may be
*/
QDeclarativeQmldirData *QDeclarativeTypeLoader::getQmldir(const QUrl &url)
{
- Q_ASSERT(!url.isRelative() &&
- (QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url).isEmpty() ||
+ Q_ASSERT(!url.isRelative() &&
+ (QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url).isEmpty() ||
!QDir::isRelativePath(QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url))));
QDeclarativeQmldirData *qmldirData = m_qmldirCache.value(url);
@@ -838,11 +838,11 @@ and qmldir information.
*/
void QDeclarativeTypeLoader::clearCache()
{
- for (TypeCache::Iterator iter = m_typeCache.begin(); iter != m_typeCache.end(); ++iter)
+ for (TypeCache::Iterator iter = m_typeCache.begin(); iter != m_typeCache.end(); ++iter)
(*iter)->release();
- for (ScriptCache::Iterator iter = m_scriptCache.begin(); iter != m_scriptCache.end(); ++iter)
+ for (ScriptCache::Iterator iter = m_scriptCache.begin(); iter != m_scriptCache.end(); ++iter)
(*iter)->release();
- for (QmldirCache::Iterator iter = m_qmldirCache.begin(); iter != m_qmldirCache.end(); ++iter)
+ for (QmldirCache::Iterator iter = m_qmldirCache.begin(); iter != m_qmldirCache.end(); ++iter)
(*iter)->release();
qDeleteAll(m_importDirCache);
qDeleteAll(m_importQmlDirCache);
@@ -855,7 +855,7 @@ void QDeclarativeTypeLoader::clearCache()
}
-QDeclarativeTypeData::QDeclarativeTypeData(const QUrl &url, QDeclarativeTypeLoader::Options options,
+QDeclarativeTypeData::QDeclarativeTypeData(const QUrl &url, QDeclarativeTypeLoader::Options options,
QDeclarativeTypeLoader *manager)
: QDeclarativeDataBlob(url, QmlFile), m_options(options), m_imports(manager), m_typesResolved(false),
m_compiledData(0), m_typeLoader(manager)
@@ -864,11 +864,11 @@ QDeclarativeTypeData::QDeclarativeTypeData(const QUrl &url, QDeclarativeTypeLoad
QDeclarativeTypeData::~QDeclarativeTypeData()
{
- for (int ii = 0; ii < m_scripts.count(); ++ii)
+ for (int ii = 0; ii < m_scripts.count(); ++ii)
m_scripts.at(ii).script->release();
- for (int ii = 0; ii < m_qmldirs.count(); ++ii)
+ for (int ii = 0; ii < m_qmldirs.count(); ++ii)
m_qmldirs.at(ii)->release();
- for (int ii = 0; ii < m_types.count(); ++ii)
+ for (int ii = 0; ii < m_types.count(); ++ii)
if (m_types.at(ii).typeData) m_types.at(ii).typeData->release();
if (m_compiledData)
m_compiledData->release();
@@ -901,7 +901,7 @@ const QList<QDeclarativeTypeData::ScriptReference> &QDeclarativeTypeData::resolv
QDeclarativeCompiledData *QDeclarativeTypeData::compiledData() const
{
- if (m_compiledData)
+ if (m_compiledData)
m_compiledData->addref();
return m_compiledData;
@@ -959,7 +959,7 @@ void QDeclarativeTypeData::done()
}
// Compile component
- if (!isError())
+ if (!isError())
compile();
if (!(m_options & QDeclarativeTypeLoader::PreserveParser))
@@ -1062,7 +1062,7 @@ void QDeclarativeTypeData::resolveTypes()
if (import.type == QDeclarativeScriptParser::Import::File && import.qualifier.isEmpty()) {
QUrl qmldirUrl = finalUrl().resolved(QUrl(import.uri + QLatin1String("/qmldir")));
- if (QDeclarativeQmldirData *qmldir = qmldirForUrl(qmldirUrl))
+ if (QDeclarativeQmldirData *qmldir = qmldirForUrl(qmldirUrl))
qmldircomponentsnetwork = qmldir->dirComponents();
}
diff --git a/src/declarative/qml/qdeclarativetypeloader_p.h b/src/declarative/qml/qdeclarativetypeloader_p.h
index 9759cc39..35591504 100644
--- a/src/declarative/qml/qdeclarativetypeloader_p.h
+++ b/src/declarative/qml/qdeclarativetypeloader_p.h
@@ -122,7 +122,7 @@ protected:
virtual void dependencyError(QDeclarativeDataBlob *);
virtual void dependencyComplete(QDeclarativeDataBlob *);
virtual void allDependenciesDone();
-
+
virtual void downloadProgressChanged(qreal);
private:
@@ -140,7 +140,7 @@ private:
QUrl m_finalUrl;
// List of QDeclarativeDataBlob's that are waiting for me to complete.
- QList<QDeclarativeDataBlob *> m_waitingOnMe;
+ QList<QDeclarativeDataBlob *> m_waitingOnMe;
// List of QDeclarativeDataBlob's that I am waiting for to complete.
QList<QDeclarativeDataBlob *> m_waitingFor;
@@ -292,7 +292,7 @@ private:
QDeclarativeCompiledData *m_compiledData;
QList<TypeDataCallback *> m_callbacks;
-
+
QDeclarativeTypeLoader *m_typeLoader;
};
diff --git a/src/declarative/qml/qdeclarativetypenamecache_p.h b/src/declarative/qml/qdeclarativetypenamecache_p.h
index 94744a0f..0af8e5a3 100644
--- a/src/declarative/qml/qdeclarativetypenamecache_p.h
+++ b/src/declarative/qml/qdeclarativetypenamecache_p.h
@@ -87,7 +87,7 @@ protected:
virtual void clear();
private:
- struct RData : public Data {
+ struct RData : public Data {
QScriptDeclarativeClass::PersistentIdentifier identifier;
};
typedef QHash<QString, RData *> StringCache;
diff --git a/src/declarative/qml/qdeclarativetypenamescriptclass.cpp b/src/declarative/qml/qdeclarativetypenamescriptclass.cpp
index f4a93037..9ace854b 100644
--- a/src/declarative/qml/qdeclarativetypenamescriptclass.cpp
+++ b/src/declarative/qml/qdeclarativetypenamescriptclass.cpp
@@ -62,7 +62,7 @@ struct TypeNameData : public QScriptDeclarativeClass::Object {
};
QDeclarativeTypeNameScriptClass::QDeclarativeTypeNameScriptClass(QDeclarativeEngine *bindEngine)
-: QScriptDeclarativeClass(QDeclarativeEnginePrivate::getScriptEngine(bindEngine)),
+: QScriptDeclarativeClass(QDeclarativeEnginePrivate::getScriptEngine(bindEngine)),
engine(bindEngine), object(0), type(0)
{
}
@@ -85,8 +85,8 @@ QScriptValue QDeclarativeTypeNameScriptClass::newObject(QObject *object, QDeclar
return QScriptDeclarativeClass::newObject(scriptEngine, this, new TypeNameData(object, ns, mode));
}
-QScriptClass::QueryFlags
-QDeclarativeTypeNameScriptClass::queryProperty(Object *obj, const Identifier &name,
+QScriptClass::QueryFlags
+QDeclarativeTypeNameScriptClass::queryProperty(Object *obj, const Identifier &name,
QScriptClass::QueryFlags flags)
{
Q_UNUSED(flags);
@@ -138,7 +138,7 @@ QDeclarativeTypeNameScriptClass::queryProperty(Object *obj, const Identifier &na
return 0;
}
-QDeclarativeTypeNameScriptClass::Value
+QDeclarativeTypeNameScriptClass::Value
QDeclarativeTypeNameScriptClass::property(Object *obj, const Identifier &name)
{
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(engine);
diff --git a/src/declarative/qml/qdeclarativetypenamescriptclass_p.h b/src/declarative/qml/qdeclarativetypenamescriptclass_p.h
index e1f04fb3..233ca44e 100644
--- a/src/declarative/qml/qdeclarativetypenamescriptclass_p.h
+++ b/src/declarative/qml/qdeclarativetypenamescriptclass_p.h
@@ -73,7 +73,7 @@ public:
QScriptValue newObject(QObject *, QDeclarativeTypeNameCache *, TypeNameMode = IncludeEnums);
protected:
- virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
+ virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
QScriptClass::QueryFlags flags);
virtual Value property(Object *, const Identifier &);
diff --git a/src/declarative/qml/qdeclarativevaluetype_p.h b/src/declarative/qml/qdeclarativevaluetype_p.h
index c939e061..f1682d2f 100644
--- a/src/declarative/qml/qdeclarativevaluetype_p.h
+++ b/src/declarative/qml/qdeclarativevaluetype_p.h
@@ -98,7 +98,7 @@ public:
}
private:
- QDeclarativeValueType *valueTypes[QVariant::UserType - 1];
+ QDeclarativeValueType *valueTypes[QVariant::UserType - 1];
};
class Q_AUTOTEST_EXPORT QDeclarativePointFValueType : public QDeclarativeValueType
@@ -208,7 +208,7 @@ public:
qreal y() const;
void setX(qreal);
void setY(qreal);
-
+
qreal width() const;
qreal height() const;
void setWidth(qreal);
@@ -237,7 +237,7 @@ public:
int y() const;
void setX(int);
void setY(int);
-
+
int width() const;
int height() const;
void setWidth(int);
diff --git a/src/declarative/qml/qdeclarativevaluetypescriptclass.cpp b/src/declarative/qml/qdeclarativevaluetypescriptclass.cpp
index fa446e5d..7e1e59ca 100644
--- a/src/declarative/qml/qdeclarativevaluetypescriptclass.cpp
+++ b/src/declarative/qml/qdeclarativevaluetypescriptclass.cpp
@@ -96,8 +96,8 @@ QScriptValue QDeclarativeValueTypeScriptClass::newObject(const QVariant &v, QDec
return QScriptDeclarativeClass::newObject(scriptEngine, this, copy);
}
-QScriptClass::QueryFlags
-QDeclarativeValueTypeScriptClass::queryProperty(Object *obj, const Identifier &name,
+QScriptClass::QueryFlags
+QDeclarativeValueTypeScriptClass::queryProperty(Object *obj, const Identifier &name,
QScriptClass::QueryFlags)
{
QDeclarativeValueTypeObject *o = static_cast<QDeclarativeValueTypeObject *>(obj);
@@ -153,7 +153,7 @@ QDeclarativeValueTypeScriptClass::Value QDeclarativeValueTypeScriptClass::proper
return Value(scriptEngine, static_cast<QDeclarativeEnginePrivate *>(QObjectPrivate::get(engine))->scriptValueFromVariant(rv));
}
-void QDeclarativeValueTypeScriptClass::setProperty(Object *obj, const Identifier &,
+void QDeclarativeValueTypeScriptClass::setProperty(Object *obj, const Identifier &,
const QScriptValue &value)
{
QDeclarativeValueTypeObject *o = static_cast<QDeclarativeValueTypeObject *>(obj);
@@ -188,12 +188,12 @@ void QDeclarativeValueTypeScriptClass::setProperty(Object *obj, const Identifier
newBinding->setEvaluateFlags(newBinding->evaluateFlags() | QDeclarativeBinding::RequiresThisObject);
}
- QDeclarativeAbstractBinding *delBinding =
+ QDeclarativeAbstractBinding *delBinding =
QDeclarativePropertyPrivate::setBinding(ref->object, ref->property, m_lastIndex, newBinding);
- if (delBinding)
+ if (delBinding)
delBinding->destroy();
- if (p.isEnumType() && (QMetaType::Type)v.type() == QMetaType::Double)
+ if (p.isEnumType() && (QMetaType::Type)v.type() == QMetaType::Double)
v = v.toInt();
p.write(ref->type, v);
ref->type->write(ref->object, ref->property, 0);
@@ -222,7 +222,7 @@ QVariant QDeclarativeValueTypeScriptClass::toVariant(Object *obj, bool *ok)
}
} else {
QDeclarativeValueTypeCopy *copy = static_cast<QDeclarativeValueTypeCopy *>(obj);
-
+
if (ok) *ok = true;
return copy->value;
diff --git a/src/declarative/qml/qdeclarativevaluetypescriptclass_p.h b/src/declarative/qml/qdeclarativevaluetypescriptclass_p.h
index 8e13628f..eb2bd525 100644
--- a/src/declarative/qml/qdeclarativevaluetypescriptclass_p.h
+++ b/src/declarative/qml/qdeclarativevaluetypescriptclass_p.h
@@ -69,7 +69,7 @@ public:
QScriptValue newObject(QObject *object, int coreIndex, QDeclarativeValueType *);
QScriptValue newObject(const QVariant &, QDeclarativeValueType *);
- virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
+ virtual QScriptClass::QueryFlags queryProperty(Object *, const Identifier &,
QScriptClass::QueryFlags flags);
virtual Value property(Object *, const Identifier &);
virtual void setProperty(Object *, const Identifier &name, const QScriptValue &);
diff --git a/src/declarative/qml/qdeclarativevme.cpp b/src/declarative/qml/qdeclarativevme.cpp
index 45c3f1b5..918ac061 100644
--- a/src/declarative/qml/qdeclarativevme.cpp
+++ b/src/declarative/qml/qdeclarativevme.cpp
@@ -79,7 +79,7 @@ template<typename T>
class QDeclarativeVMEStack : private QVarLengthArray<T, 128>
{
private:
- typedef QVarLengthArray<T, 128> VLA;
+ typedef QVarLengthArray<T, 128> VLA;
int _index;
public:
@@ -111,9 +111,9 @@ QDeclarativeVME::QDeclarativeVME()
struct ListInstance
{
- ListInstance()
+ ListInstance()
: type(0) {}
- ListInstance(int t)
+ ListInstance(int t)
: type(t) {}
int type;
@@ -122,7 +122,7 @@ struct ListInstance
Q_DECLARE_TYPEINFO(ListInstance, Q_PRIMITIVE_TYPE | Q_MOVABLE_TYPE);
-QObject *QDeclarativeVME::run(QDeclarativeContextData *ctxt, QDeclarativeCompiledData *comp,
+QObject *QDeclarativeVME::run(QDeclarativeContextData *ctxt, QDeclarativeCompiledData *comp,
int start, int count, const QBitField &bindingSkipList)
{
QDeclarativeVMEObjectStack stack;
@@ -150,11 +150,11 @@ void QDeclarativeVME::runDeferred(QObject *object)
run(stack, ctxt, comp, start, count, QBitField());
}
-inline bool fastHasBinding(QObject *o, int index)
+inline bool fastHasBinding(QObject *o, int index)
{
QDeclarativeData *ddata = static_cast<QDeclarativeData *>(QObjectPrivate::get(o)->declarativeData);
- return ddata && (ddata->bindingBitsSize > index) &&
+ return ddata && (ddata->bindingBitsSize > index) &&
(ddata->bindingBits[index / 32] & (1 << (index % 32)));
}
@@ -166,10 +166,10 @@ static void removeBindingOnProperty(QObject *o, int index)
#define CLEAN_PROPERTY(o, index) if (fastHasBinding(o, index)) removeBindingOnProperty(o, index)
-QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
- QDeclarativeContextData *ctxt,
- QDeclarativeCompiledData *comp,
- int start, int count,
+QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
+ QDeclarativeContextData *ctxt,
+ QDeclarativeCompiledData *comp,
+ int start, int count,
const QBitField &bindingSkipList)
{
Q_ASSERT(comp);
@@ -202,13 +202,13 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
switch(instr.type) {
case QDeclarativeInstruction::Init:
{
- if (instr.init.bindingsSize)
+ if (instr.init.bindingsSize)
bindValues = QDeclarativeEnginePrivate::SimpleList<QDeclarativeAbstractBinding>(instr.init.bindingsSize);
if (instr.init.parserStatusSize)
parserStatus = QDeclarativeEnginePrivate::SimpleList<QDeclarativeParserStatus>(instr.init.parserStatusSize);
- if (instr.init.contextCache != -1)
+ if (instr.init.contextCache != -1)
ctxt->setIdPropertyData(comp->contextCaches.at(instr.init.contextCache));
- if (instr.init.compiledBinding != -1)
+ if (instr.init.compiledBinding != -1)
ctxt->optimizedBindings = new QDeclarativeCompiledBindings(datas.at(instr.init.compiledBinding).constData(), ctxt, comp);
}
break;
@@ -224,7 +224,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
if (stack.isEmpty())
bindings = bindings.united(bindingSkipList);
- QObject *o =
+ QObject *o =
types.at(instr.create.type).createInstance(ctxt, bindings, &vmeErrors);
if (!o) {
@@ -263,17 +263,17 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
}
if (!stack.isEmpty()) {
QObject *parent = stack.top();
- if (o->isWidgetType()) {
- QWidget *widget = static_cast<QWidget*>(o);
- if (parent->isWidgetType()) {
- QWidget *parentWidget = static_cast<QWidget*>(parent);
- widget->setParent(parentWidget);
- } else {
- // TODO: parent might be a layout
- }
- } else {
- QDeclarative_setParent_noEvent(o, parent);
- }
+ if (o->isWidgetType()) {
+ QWidget *widget = static_cast<QWidget*>(o);
+ if (parent->isWidgetType()) {
+ QWidget *parentWidget = static_cast<QWidget*>(parent);
+ widget->setParent(parentWidget);
+ } else {
+ // TODO: parent might be a layout
+ }
+ } else {
+ QDeclarative_setParent_noEvent(o, parent);
+ }
}
stack.push(o);
}
@@ -281,8 +281,8 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
case QDeclarativeInstruction::CreateSimpleObject:
{
- QObject *o = (QObject *)operator new(instr.createSimple.typeSize +
- sizeof(QDeclarativeData));
+ QObject *o = (QObject *)operator new(instr.createSimple.typeSize +
+ sizeof(QDeclarativeData));
::memset(static_cast<void *>(o), 0, instr.createSimple.typeSize + sizeof(QDeclarativeData));
instr.createSimple.create(o);
@@ -296,16 +296,16 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
ddata->lineNumber = instr.line;
ddata->columnNumber = instr.createSimple.column;
- QObjectPrivate::get(o)->declarativeData = ddata;
+ QObjectPrivate::get(o)->declarativeData = ddata;
ddata->context = ddata->outerContext = ctxt;
- ddata->nextContextObject = ctxt->contextObjects;
- if (ddata->nextContextObject)
- ddata->nextContextObject->prevContextObject = &ddata->nextContextObject;
- ddata->prevContextObject = &ctxt->contextObjects;
- ctxt->contextObjects = ddata;
+ ddata->nextContextObject = ctxt->contextObjects;
+ if (ddata->nextContextObject)
+ ddata->nextContextObject->prevContextObject = &ddata->nextContextObject;
+ ddata->prevContextObject = &ctxt->contextObjects;
+ ctxt->contextObjects = ddata;
- QObject *parent = stack.top();
- QDeclarative_setParent_noEvent(o, parent);
+ QObject *parent = stack.top();
+ QDeclarative_setParent_noEvent(o, parent);
stack.push(o);
}
@@ -327,7 +327,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
case QDeclarativeInstruction::CreateComponent:
{
- QDeclarativeComponent *qcomp =
+ QDeclarativeComponent *qcomp =
new QDeclarativeComponent(ctxt->engine, comp, ii + 1, instr.createComponent.count,
stack.isEmpty() ? 0 : stack.top());
@@ -336,7 +336,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
ctxt->addObject(qcomp);
- if (stack.isEmpty())
+ if (stack.isEmpty())
ddata->ownContext = true;
ddata->setImplicitDestructible();
@@ -359,7 +359,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
const QByteArray &metadata = datas.at(instr.storeMeta.data);
QMetaObjectBuilder::fromRelocatableData(&mo, 0, metadata);
- const QDeclarativeVMEMetaData *data =
+ const QDeclarativeVMEMetaData *data =
(const QDeclarativeVMEMetaData *)datas.at(instr.storeMeta.aliasData).constData();
(void)new QDeclarativeVMEMetaObject(target, &mo, data, comp);
@@ -381,7 +381,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
// XXX - can be more efficient
QVariant v = QDeclarativeStringConverters::variantFromString(primitives.at(instr.storeString.value));
void *a[] = { &v, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeString.propertyIndex, a);
}
break;
@@ -393,7 +393,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QVariant v(instr.storeInteger.value);
void *a[] = { &v, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeString.propertyIndex, a);
}
break;
@@ -405,7 +405,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QVariant v(instr.storeDouble.value);
void *a[] = { &v, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeString.propertyIndex, a);
}
break;
@@ -417,7 +417,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QVariant v(instr.storeBool.value);
void *a[] = { &v, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeString.propertyIndex, a);
}
break;
@@ -428,7 +428,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
CLEAN_PROPERTY(target, instr.storeString.propertyIndex);
void *a[] = { (void *)&primitives.at(instr.storeString.value), 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeString.propertyIndex, a);
}
break;
@@ -439,7 +439,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
CLEAN_PROPERTY(target, instr.storeUrl.propertyIndex);
void *a[] = { (void *)&urls.at(instr.storeUrl.value), 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeUrl.propertyIndex, a);
}
break;
@@ -474,7 +474,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
CLEAN_PROPERTY(target, instr.storeBool.propertyIndex);
void *a[] = { (void *)&instr.storeBool.value, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeBool.propertyIndex, a);
}
break;
@@ -485,7 +485,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
CLEAN_PROPERTY(target, instr.storeInteger.propertyIndex);
void *a[] = { (void *)&instr.storeInteger.value, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeInteger.propertyIndex, a);
}
break;
@@ -497,7 +497,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QColor c = QColor::fromRgba(instr.storeColor.value);
void *a[] = { &c, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeColor.propertyIndex, a);
}
break;
@@ -509,7 +509,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QDate d = QDate::fromJulianDay(instr.storeDate.value);
void *a[] = { &d, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeDate.propertyIndex, a);
}
break;
@@ -525,7 +525,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
intData.at(instr.storeTime.valueIndex+2),
intData.at(instr.storeTime.valueIndex+3));
void *a[] = { &t, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeTime.propertyIndex, a);
}
break;
@@ -556,7 +556,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QPoint p = QPointF(floatData.at(instr.storeRealPair.valueIndex),
floatData.at(instr.storeRealPair.valueIndex+1)).toPoint();
void *a[] = { &p, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeRealPair.propertyIndex, a);
}
break;
@@ -569,7 +569,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QPointF p(floatData.at(instr.storeRealPair.valueIndex),
floatData.at(instr.storeRealPair.valueIndex+1));
void *a[] = { &p, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeRealPair.propertyIndex, a);
}
break;
@@ -582,7 +582,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QSize p = QSizeF(floatData.at(instr.storeRealPair.valueIndex),
floatData.at(instr.storeRealPair.valueIndex+1)).toSize();
void *a[] = { &p, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeRealPair.propertyIndex, a);
}
break;
@@ -595,7 +595,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QSizeF s(floatData.at(instr.storeRealPair.valueIndex),
floatData.at(instr.storeRealPair.valueIndex+1));
void *a[] = { &s, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeRealPair.propertyIndex, a);
}
break;
@@ -610,7 +610,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
floatData.at(instr.storeRect.valueIndex+2),
floatData.at(instr.storeRect.valueIndex+3)).toRect();
void *a[] = { &r, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeRect.propertyIndex, a);
}
break;
@@ -625,7 +625,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
floatData.at(instr.storeRect.valueIndex+2),
floatData.at(instr.storeRect.valueIndex+3));
void *a[] = { &r, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeRect.propertyIndex, a);
}
break;
@@ -639,7 +639,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
floatData.at(instr.storeVector3D.valueIndex+1),
floatData.at(instr.storeVector3D.valueIndex+2));
void *a[] = { &p, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeVector3D.propertyIndex, a);
}
break;
@@ -651,7 +651,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
CLEAN_PROPERTY(target, instr.storeObject.propertyIndex);
void *a[] = { (void *)&assignObj, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeObject.propertyIndex, a);
}
break;
@@ -664,17 +664,17 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QDeclarativeCompiledData::CustomTypeData data = customTypeData.at(instr.assignCustomType.valueIndex);
const QString &primitive = primitives.at(data.index);
- QDeclarativeMetaType::StringConverter converter =
+ QDeclarativeMetaType::StringConverter converter =
QDeclarativeMetaType::customStringConverter(data.type);
QVariant v = (*converter)(primitive);
- QMetaProperty prop =
+ QMetaProperty prop =
target->metaObject()->property(instr.assignCustomType.propertyIndex);
- if (v.isNull() || ((int)prop.type() != data.type && prop.userType() != data.type))
+ if (v.isNull() || ((int)prop.type() != data.type && prop.userType() != data.type))
VME_EXCEPTION(QCoreApplication::translate("QDeclarativeVME","Cannot assign value %1 to property %2").arg(primitive).arg(QString::fromUtf8(prop.name())));
void *a[] = { (void *)v.data(), 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.assignCustomType.propertyIndex, a);
}
break;
@@ -719,7 +719,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QMetaMethod signal = target->metaObject()->method(instr.storeSignal.signalIndex);
QDeclarativeBoundSignal *bs = new QDeclarativeBoundSignal(target, signal, target);
- QDeclarativeExpression *expr =
+ QDeclarativeExpression *expr =
new QDeclarativeExpression(ctxt, context, primitives.at(instr.storeSignal.value));
expr->setSourceLocation(comp->name, instr.line);
static_cast<QDeclarativeExpressionPrivate *>(QObjectPrivate::get(expr))->name = datas.at(instr.storeSignal.name);
@@ -743,7 +743,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
ss.setScript(primitives.at(instr.storeScriptString.value));
void *a[] = { &ss, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeScriptString.propertyIndex, a);
}
break;
@@ -762,17 +762,17 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
case QDeclarativeInstruction::StoreBinding:
case QDeclarativeInstruction::StoreBindingOnAlias:
{
- QObject *target =
+ QObject *target =
stack.at(stack.count() - 1 - instr.assignBinding.owner);
- QObject *context =
+ QObject *context =
stack.at(stack.count() - 1 - instr.assignBinding.context);
- QDeclarativeProperty mp =
+ QDeclarativeProperty mp =
QDeclarativePropertyPrivate::restore(datas.at(instr.assignBinding.property), target, ctxt);
int coreIndex = mp.index();
- if ((stack.count() - instr.assignBinding.owner) == 1 && bindingSkipList.testBit(coreIndex))
+ if ((stack.count() - instr.assignBinding.owner) == 1 && bindingSkipList.testBit(coreIndex))
break;
QDeclarativeBinding *bind = new QDeclarativeBinding((void *)datas.at(instr.assignBinding.value).constData(), comp, context, ctxt, comp->name, instr.line, 0);
@@ -791,16 +791,16 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
case QDeclarativeInstruction::StoreCompiledBinding:
{
- QObject *target =
+ QObject *target =
stack.at(stack.count() - 1 - instr.assignBinding.owner);
- QObject *scope =
+ QObject *scope =
stack.at(stack.count() - 1 - instr.assignBinding.context);
int property = instr.assignBinding.property;
- if (stack.count() == 1 && bindingSkipList.testBit(property & 0xFFFF))
+ if (stack.count() == 1 && bindingSkipList.testBit(property & 0xFFFF))
break;
- QDeclarativeAbstractBinding *binding =
+ QDeclarativeAbstractBinding *binding =
ctxt->optimizedBindings->configBinding(instr.assignBinding.value, target, scope, property);
bindValues.append(binding);
binding->m_mePtr = &bindValues.values[bindValues.count - 1];
@@ -814,7 +814,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QDeclarativePropertyValueSource *vs = reinterpret_cast<QDeclarativePropertyValueSource *>(reinterpret_cast<char *>(obj) + instr.assignValueSource.castValue);
QObject *target = stack.at(stack.count() - 1 - instr.assignValueSource.owner);
- QDeclarativeProperty prop =
+ QDeclarativeProperty prop =
QDeclarativePropertyPrivate::restore(datas.at(instr.assignValueSource.property), target, ctxt);
obj->setParent(target);
vs->setTarget(prop);
@@ -826,7 +826,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QObject *obj = stack.pop();
QDeclarativePropertyValueInterceptor *vi = reinterpret_cast<QDeclarativePropertyValueInterceptor *>(reinterpret_cast<char *>(obj) + instr.assignValueInterceptor.castValue);
QObject *target = stack.at(stack.count() - 1 - instr.assignValueInterceptor.owner);
- QDeclarativeProperty prop =
+ QDeclarativeProperty prop =
QDeclarativePropertyPrivate::restore(datas.at(instr.assignValueInterceptor.property), target, ctxt);
obj->setParent(target);
vi->setTarget(prop);
@@ -855,9 +855,9 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
void *ptr = 0;
const char *iid = QDeclarativeMetaType::interfaceIId(type);
- if (iid)
+ if (iid)
ptr = assign->qt_metacast(iid);
- if (!ptr)
+ if (!ptr)
VME_EXCEPTION(QCoreApplication::translate("QDeclarativeVME","Cannot assign object to list"));
@@ -873,7 +873,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QVariant v = QVariant::fromValue(assign);
void *a[] = { &v, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.storeObject.propertyIndex, a);
}
break;
@@ -893,18 +893,18 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
void *ptr = assign->qt_metacast(iid);
if (ptr) {
void *a[] = { &ptr, 0, &status, &flags };
- QMetaObject::metacall(target,
+ QMetaObject::metacall(target,
QMetaObject::WriteProperty,
coreIdx, a);
ok = true;
}
- }
+ }
- if (!ok)
+ if (!ok)
VME_EXCEPTION(QCoreApplication::translate("QDeclarativeVME","Cannot assign object to interface property"));
}
break;
-
+
case QDeclarativeInstruction::FetchAttached:
{
QObject *target = stack.top();
@@ -926,7 +926,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
void *a[1];
a[0] = (void *)&(qliststack.top().qListProperty);
- QMetaObject::metacall(target, QMetaObject::ReadProperty,
+ QMetaObject::metacall(target, QMetaObject::ReadProperty,
instr.fetchQmlList.property, a);
}
break;
@@ -936,11 +936,11 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
QObject *target = stack.top();
QObject *obj = 0;
- // NOTE: This assumes a cast to QObject does not alter the
+ // NOTE: This assumes a cast to QObject does not alter the
// object pointer
void *a[1];
a[0] = &obj;
- QMetaObject::metacall(target, QMetaObject::ReadProperty,
+ QMetaObject::metacall(target, QMetaObject::ReadProperty,
instr.fetch.property, a);
if (!obj)
@@ -960,7 +960,7 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
{
if (instr.defer.deferCount) {
QObject *target = stack.top();
- QDeclarativeData *data =
+ QDeclarativeData *data =
QDeclarativeData::get(target, true);
comp->addref();
data->deferredComponent = comp;
@@ -984,14 +984,14 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
// Possibly need to clear bindings
QDeclarativeData *targetData = QDeclarativeData::get(target);
if (targetData) {
- QDeclarativeAbstractBinding *binding =
+ QDeclarativeAbstractBinding *binding =
QDeclarativePropertyPrivate::binding(target, instr.fetchValue.property, -1);
if (binding && binding->bindingType() != QDeclarativeAbstractBinding::ValueTypeProxy) {
QDeclarativePropertyPrivate::setBinding(target, instr.fetchValue.property, -1, 0);
binding->destroy();
} else if (binding) {
- QDeclarativeValueTypeProxyBinding *proxy =
+ QDeclarativeValueTypeProxyBinding *proxy =
static_cast<QDeclarativeValueTypeProxyBinding *>(binding);
proxy->removeBindings(instr.fetchValue.bindingSkipList);
}
@@ -1006,10 +1006,10 @@ QObject *QDeclarativeVME::run(QDeclarativeVMEObjectStack &stack,
case QDeclarativeInstruction::PopValueType:
{
- QDeclarativeValueType *valueHandler =
+ QDeclarativeValueType *valueHandler =
static_cast<QDeclarativeValueType *>(stack.pop());
QObject *target = stack.top();
- valueHandler->write(target, instr.fetchValue.property,
+ valueHandler->write(target, instr.fetchValue.property,
QDeclarativePropertyPrivate::BypassInterceptor);
}
break;
@@ -1079,7 +1079,7 @@ QDeclarativeCompiledData::TypeReference::createInstance(QDeclarativeContextData
} else {
Q_ASSERT(component);
return QDeclarativeComponentPrivate::begin(ctxt, 0, component, -1, -1, 0, errors, bindings);
- }
+ }
}
template<typename T>
diff --git a/src/declarative/qml/qdeclarativevme_p.h b/src/declarative/qml/qdeclarativevme_p.h
index a52ba14a..5ef049f1 100644
--- a/src/declarative/qml/qdeclarativevme_p.h
+++ b/src/declarative/qml/qdeclarativevme_p.h
@@ -74,8 +74,8 @@ class QDeclarativeVME
public:
QDeclarativeVME();
- QObject *run(QDeclarativeContextData *, QDeclarativeCompiledData *,
- int start = -1, int count = -1,
+ QObject *run(QDeclarativeContextData *, QDeclarativeCompiledData *,
+ int start = -1, int count = -1,
const QBitField & = QBitField());
void runDeferred(QObject *);
@@ -83,9 +83,9 @@ public:
QList<QDeclarativeError> errors() const;
private:
- QObject *run(QDeclarativeVMEObjectStack &,
- QDeclarativeContextData *, QDeclarativeCompiledData *,
- int start, int count,
+ QObject *run(QDeclarativeVMEObjectStack &,
+ QDeclarativeContextData *, QDeclarativeCompiledData *,
+ int start, int count,
const QBitField &);
QList<QDeclarativeError> vmeErrors;
};
diff --git a/src/declarative/qml/qdeclarativevmemetaobject.cpp b/src/declarative/qml/qdeclarativevmemetaobject.cpp
index 45c7cf02..3ac2546a 100644
--- a/src/declarative/qml/qdeclarativevmemetaobject.cpp
+++ b/src/declarative/qml/qdeclarativevmemetaobject.cpp
@@ -152,20 +152,20 @@ const void *QDeclarativeVMEVariant::dataPtr() const
return &data;
}
-void *QDeclarativeVMEVariant::dataPtr()
+void *QDeclarativeVMEVariant::dataPtr()
{
return &data;
}
-QObject *QDeclarativeVMEVariant::asQObject()
+QObject *QDeclarativeVMEVariant::asQObject()
{
- if (type != QMetaType::QObjectStar)
+ if (type != QMetaType::QObjectStar)
setValue((QObject *)0);
return *(QDeclarativeGuard<QObject> *)(dataPtr());
}
-const QVariant &QDeclarativeVMEVariant::asQVariant()
+const QVariant &QDeclarativeVMEVariant::asQVariant()
{
if (type != QMetaType::QVariant)
setValue(QVariant());
@@ -173,7 +173,7 @@ const QVariant &QDeclarativeVMEVariant::asQVariant()
return *(QVariant *)(dataPtr());
}
-int QDeclarativeVMEVariant::asInt()
+int QDeclarativeVMEVariant::asInt()
{
if (type != QMetaType::Int)
setValue(int(0));
@@ -181,7 +181,7 @@ int QDeclarativeVMEVariant::asInt()
return *(int *)(dataPtr());
}
-bool QDeclarativeVMEVariant::asBool()
+bool QDeclarativeVMEVariant::asBool()
{
if (type != QMetaType::Bool)
setValue(bool(false));
@@ -189,7 +189,7 @@ bool QDeclarativeVMEVariant::asBool()
return *(bool *)(dataPtr());
}
-double QDeclarativeVMEVariant::asDouble()
+double QDeclarativeVMEVariant::asDouble()
{
if (type != QMetaType::Double)
setValue(double(0));
@@ -197,7 +197,7 @@ double QDeclarativeVMEVariant::asDouble()
return *(double *)(dataPtr());
}
-const QString &QDeclarativeVMEVariant::asQString()
+const QString &QDeclarativeVMEVariant::asQString()
{
if (type != QMetaType::QString)
setValue(QString());
@@ -205,7 +205,7 @@ const QString &QDeclarativeVMEVariant::asQString()
return *(QString *)(dataPtr());
}
-const QUrl &QDeclarativeVMEVariant::asQUrl()
+const QUrl &QDeclarativeVMEVariant::asQUrl()
{
if (type != QMetaType::QUrl)
setValue(QUrl());
@@ -213,7 +213,7 @@ const QUrl &QDeclarativeVMEVariant::asQUrl()
return *(QUrl *)(dataPtr());
}
-const QColor &QDeclarativeVMEVariant::asQColor()
+const QColor &QDeclarativeVMEVariant::asQColor()
{
if (type != QMetaType::QColor)
setValue(QColor());
@@ -221,7 +221,7 @@ const QColor &QDeclarativeVMEVariant::asQColor()
return *(QColor *)(dataPtr());
}
-const QTime &QDeclarativeVMEVariant::asQTime()
+const QTime &QDeclarativeVMEVariant::asQTime()
{
if (type != QMetaType::QTime)
setValue(QTime());
@@ -229,7 +229,7 @@ const QTime &QDeclarativeVMEVariant::asQTime()
return *(QTime *)(dataPtr());
}
-const QDate &QDeclarativeVMEVariant::asQDate()
+const QDate &QDeclarativeVMEVariant::asQDate()
{
if (type != QMetaType::QDate)
setValue(QDate());
@@ -237,7 +237,7 @@ const QDate &QDeclarativeVMEVariant::asQDate()
return *(QDate *)(dataPtr());
}
-const QDateTime &QDeclarativeVMEVariant::asQDateTime()
+const QDateTime &QDeclarativeVMEVariant::asQDateTime()
{
if (type != QMetaType::QDateTime)
setValue(QDateTime());
@@ -245,7 +245,7 @@ const QDateTime &QDeclarativeVMEVariant::asQDateTime()
return *(QDateTime *)(dataPtr());
}
-const QScriptValue &QDeclarativeVMEVariant::asQScriptValue()
+const QScriptValue &QDeclarativeVMEVariant::asQScriptValue()
{
if (type != qMetaTypeId<QScriptValue>())
setValue(QScriptValue());
@@ -379,7 +379,7 @@ void QDeclarativeVMEVariant::setValue(const QScriptValue &v)
}
QDeclarativeVMEMetaObject::QDeclarativeVMEMetaObject(QObject *obj,
- const QMetaObject *other,
+ const QMetaObject *other,
const QDeclarativeVMEMetaData *meta,
QDeclarativeCompiledData *cdata)
: object(obj), compiledData(cdata), ctxt(QDeclarativeData::get(obj, true)->outerContext),
@@ -409,7 +409,7 @@ QDeclarativeVMEMetaObject::QDeclarativeVMEMetaObject(QObject *obj,
if (t == list_type) {
listProperties.append(List(methodOffset + ii));
data[ii].setValue(listProperties.count() - 1);
- }
+ }
}
}
@@ -568,7 +568,7 @@ int QDeclarativeVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
QDeclarativeVMEMetaData::AliasData *d = metaData->aliasData() + id;
- if (d->flags & QML_ALIAS_FLAG_PTR && c == QMetaObject::ReadProperty)
+ if (d->flags & QML_ALIAS_FLAG_PTR && c == QMetaObject::ReadProperty)
*reinterpret_cast<void **>(a[0]) = 0;
if (!ctxt) return -1;
@@ -577,7 +577,7 @@ int QDeclarativeVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
QDeclarativeContextPrivate *ctxtPriv = QDeclarativeContextPrivate::get(context);
QObject *target = ctxtPriv->data->idValues[d->contextIdx].data();
- if (!target)
+ if (!target)
return -1;
connectAlias(id);
@@ -585,8 +585,8 @@ int QDeclarativeVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
if (d->isObjectAlias()) {
*reinterpret_cast<QObject **>(a[0]) = target;
return -1;
- }
-
+ }
+
// Remove binding (if any) on write
if(c == QMetaObject::WriteProperty) {
int flags = *reinterpret_cast<int*>(a[3]);
@@ -598,7 +598,7 @@ int QDeclarativeVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
}
}
}
-
+
if (d->isValueTypeAlias()) {
// Value type property
QDeclarativeEnginePrivate *ep = QDeclarativeEnginePrivate::get(ctxt->engine);
@@ -608,7 +608,7 @@ int QDeclarativeVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
valueType->read(target, d->propertyIndex());
int rv = QMetaObject::metacall(valueType, c, d->valueTypeIndex(), a);
-
+
if (c == QMetaObject::WriteProperty)
valueType->write(target, d->propertyIndex(), 0x00);
@@ -670,19 +670,19 @@ int QDeclarativeVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
QScriptValue QDeclarativeVMEMetaObject::method(int index)
{
- if (!methods)
+ if (!methods)
methods = new QScriptValue[metaData->methodCount];
if (!methods[index].isValid()) {
QDeclarativeVMEMetaData::MethodData *data = metaData->methodData() + index;
- const QChar *body =
+ const QChar *body =
(const QChar *)(((const char*)metaData) + data->bodyOffset);
QString code = QString::fromRawData(body, data->bodyLength);
// XXX Use QScriptProgram
- // XXX We should evaluate all methods in a single big script block to
+ // XXX We should evaluate all methods in a single big script block to
// improve the call time between dynamic methods defined on the same
// object
methods[index] = QDeclarativeExpressionPrivate::evalInObjectScope(ctxt, object, code, ctxt->url.toString(),
@@ -696,7 +696,7 @@ QScriptValue QDeclarativeVMEMetaObject::readVarProperty(int id)
{
if (data[id].dataType() == qMetaTypeId<QScriptValue>())
return data[id].asQScriptValue();
- else if (data[id].dataType() == QMetaType::QObjectStar)
+ else if (data[id].dataType() == QMetaType::QObjectStar)
return QDeclarativeEnginePrivate::get(ctxt->engine)->objectClass->newQObject(data[id].asQObject());
else
return QDeclarativeEnginePrivate::get(ctxt->engine)->scriptValueFromVariant(data[id].asQVariant());
@@ -706,9 +706,9 @@ QVariant QDeclarativeVMEMetaObject::readVarPropertyAsVariant(int id)
{
if (data[id].dataType() == qMetaTypeId<QScriptValue>())
return QDeclarativeEnginePrivate::get(ctxt->engine)->scriptValueToVariant(data[id].asQScriptValue());
- else if (data[id].dataType() == QMetaType::QObjectStar)
+ else if (data[id].dataType() == QMetaType::QObjectStar)
return QVariant::fromValue(data[id].asQObject());
- else
+ else
return data[id].asQVariant();
}
@@ -726,8 +726,8 @@ void QDeclarativeVMEMetaObject::writeVarProperty(int id, const QVariant &value)
needActivate = (data[id].dataType() != QMetaType::QObjectStar || data[id].asQObject() != o);
data[id].setValue(qvariant_cast<QObject *>(value));
} else {
- needActivate = (data[id].dataType() != qMetaTypeId<QVariant>() ||
- data[id].asQVariant().userType() != value.userType() ||
+ needActivate = (data[id].dataType() != qMetaTypeId<QVariant>() ||
+ data[id].asQVariant().userType() != value.userType() ||
data[id].asQVariant() != value);
data[id].setValue(value);
}
@@ -808,7 +808,7 @@ void QDeclarativeVMEMetaObject::setVmeMethod(int index, const QScriptValue &valu
int plainSignals = metaData->signalCount + metaData->propertyCount + metaData->aliasCount;
Q_ASSERT(index >= (methodOffset + plainSignals) && index < (methodOffset + plainSignals + metaData->methodCount));
- if (!methods)
+ if (!methods)
methods = new QScriptValue[metaData->methodCount];
methods[index - methodOffset - plainSignals] = value;
}
@@ -872,7 +872,7 @@ void QDeclarativeVMEMetaObject::connectAlias(int aliasId)
QDeclarativeVMEMetaData::AliasData *d = metaData->aliasData() + aliasId;
QObject *target = ctxtPriv->data->idValues[d->contextIdx].data();
- if (!target)
+ if (!target)
return;
int sigIdx = methodOffset + aliasId + metaData->propertyCount;
diff --git a/src/declarative/qml/qdeclarativevmemetaobject_p.h b/src/declarative/qml/qdeclarativevmemetaobject_p.h
index 418a5bc4..acef34f2 100644
--- a/src/declarative/qml/qdeclarativevmemetaobject_p.h
+++ b/src/declarative/qml/qdeclarativevmemetaobject_p.h
@@ -104,7 +104,7 @@ struct QDeclarativeVMEMetaData
return ((unsigned int)propertyIdx) >> 24;
}
};
-
+
struct PropertyData {
int propertyType;
};
diff --git a/src/declarative/qml/qdeclarativeworkerscript.cpp b/src/declarative/qml/qdeclarativeworkerscript.cpp
index 4439f896..1ad039f6 100644
--- a/src/declarative/qml/qdeclarativeworkerscript.cpp
+++ b/src/declarative/qml/qdeclarativeworkerscript.cpp
@@ -206,7 +206,7 @@ QScriptValue QDeclarativeWorkerScriptEnginePrivate::onMessage(QScriptContext *ct
if (!script)
return engine->undefinedValue();
- if (ctxt->argumentCount() >= 1)
+ if (ctxt->argumentCount() >= 1)
script->callback = ctxt->argument(0);
return script->callback;
diff --git a/src/declarative/qml/qdeclarativexmlhttprequest.cpp b/src/declarative/qml/qdeclarativexmlhttprequest.cpp
index 5fd23600..409d3aa9 100644
--- a/src/declarative/qml/qdeclarativexmlhttprequest.cpp
+++ b/src/declarative/qml/qdeclarativexmlhttprequest.cpp
@@ -87,7 +87,7 @@
QScriptValue errorValue = context->throwError(QLatin1String(desc)); \
errorValue.setProperty(QLatin1String("code"), error); \
return errorValue; \
-}
+}
#define THROW_SYNTAX(desc) \
return context->throwError(QScriptContext::SyntaxError, QLatin1String(desc));
@@ -102,11 +102,11 @@ QT_BEGIN_NAMESPACE
DEFINE_BOOL_CONFIG_OPTION(xhrDump, QML_XHR_DUMP);
class DocumentImpl;
-class NodeImpl
+class NodeImpl
{
public:
NodeImpl() : type(Element), document(0), parent(0) {}
- virtual ~NodeImpl() {
+ virtual ~NodeImpl() {
for (int ii = 0; ii < children.count(); ++ii)
delete children.at(ii);
for (int ii = 0; ii < attributes.count(); ++ii)
@@ -114,18 +114,18 @@ public:
}
// These numbers are copied from the Node IDL definition
- enum Type {
- Attr = 2,
- CDATA = 4,
- Comment = 8,
- Document = 9,
- DocumentFragment = 11,
+ enum Type {
+ Attr = 2,
+ CDATA = 4,
+ Comment = 8,
+ Document = 9,
+ DocumentFragment = 11,
DocumentType = 10,
- Element = 1,
- Entity = 6,
+ Element = 1,
+ Entity = 6,
EntityReference = 5,
- Notation = 12,
- ProcessingInstruction = 7,
+ Notation = 12,
+ ProcessingInstruction = 7,
Text = 3
};
Type type;
@@ -193,7 +193,7 @@ public:
virtual QScriptValue property(const QScriptValue &object, const QScriptString &name, uint id);
};
-class NodeList
+class NodeList
{
public:
// JS API
@@ -331,7 +331,7 @@ Q_DECLARE_METATYPE(NamedNodeMap)
QT_BEGIN_NAMESPACE
-void NodeImpl::addref()
+void NodeImpl::addref()
{
A(document);
}
@@ -444,7 +444,7 @@ QScriptValue Node::nextSibling(QScriptContext *context, QScriptEngine *engine)
for (int ii = 0; ii < node.d->parent->children.count(); ++ii) {
if (node.d->parent->children.at(ii) == node.d) {
if ((ii + 1) == node.d->parent->children.count()) return engine->nullValue();
- else return Node::create(engine, node.d->parent->children.at(ii + 1));
+ else return Node::create(engine, node.d->parent->children.at(ii + 1));
}
}
@@ -652,7 +652,7 @@ QScriptValue Document::load(QScriptEngine *engine, const QByteArray &data)
break;
case QXmlStreamReader::EndDocument:
break;
- case QXmlStreamReader::StartElement:
+ case QXmlStreamReader::StartElement:
{
Q_ASSERT(document);
NodeImpl *node = new NodeImpl;
@@ -677,7 +677,7 @@ QScriptValue Document::load(QScriptEngine *engine, const QByteArray &data)
attr->parent = node;
node->attributes.append(attr);
}
- }
+ }
break;
case QXmlStreamReader::EndElement:
nodeStack.pop();
@@ -946,7 +946,7 @@ class QDeclarativeXMLHttpRequest : public QObject
{
Q_OBJECT
public:
- enum State { Unsent = 0,
+ enum State { Unsent = 0,
Opened = 1, HeadersReceived = 2,
Loading = 3, Done = 4 };
@@ -1142,7 +1142,7 @@ void QDeclarativeXMLHttpRequest::requestFromUrl(const QUrl &url)
}
request.setHeader(QNetworkRequest::ContentTypeHeader, str);
} else {
- request.setHeader(QNetworkRequest::ContentTypeHeader,
+ request.setHeader(QNetworkRequest::ContentTypeHeader,
QLatin1String("text/plain;charset=UTF-8"));
}
}
@@ -1150,7 +1150,7 @@ void QDeclarativeXMLHttpRequest::requestFromUrl(const QUrl &url)
if (xhrDump()) {
qWarning().nospace() << "XMLHttpRequest: " << qPrintable(m_method) << " " << qPrintable(url.toString());
if (!m_data.isEmpty()) {
- qWarning().nospace() << " "
+ qWarning().nospace() << " "
<< qPrintable(QString::fromUtf8(m_data));
}
}
@@ -1192,7 +1192,7 @@ QScriptValue QDeclarativeXMLHttpRequest::abort(QScriptValue *me)
m_errorFlag = true;
m_request = QNetworkRequest();
- if (!(m_state == Unsent ||
+ if (!(m_state == Unsent ||
(m_state == Opened && !m_sendFlag) ||
m_state == Done)) {
@@ -1208,7 +1208,7 @@ QScriptValue QDeclarativeXMLHttpRequest::abort(QScriptValue *me)
void QDeclarativeXMLHttpRequest::readyRead()
{
- m_status =
+ m_status =
m_network->attribute(QNetworkRequest::HttpStatusCodeAttribute).toInt();
m_statusText =
QString::fromUtf8(m_network->attribute(QNetworkRequest::HttpReasonPhraseAttribute).toByteArray());
@@ -1254,7 +1254,7 @@ void QDeclarativeXMLHttpRequest::error(QNetworkReply::NetworkError error)
if (cbv.isError()) printError(cbv);
} else {
m_errorFlag = true;
- }
+ }
m_state = Done;
QScriptValue cbv = dispatchCallback(&m_me);
@@ -1299,7 +1299,7 @@ void QDeclarativeXMLHttpRequest::finished()
if (xhrDump()) {
qWarning().nospace() << "XMLHttpRequest: RESPONSE " << qPrintable(m_url.toString());
if (!m_responseEntityBody.isEmpty()) {
- qWarning().nospace() << " "
+ qWarning().nospace() << " "
<< qPrintable(QString::fromUtf8(m_responseEntityBody));
}
}
@@ -1340,7 +1340,7 @@ void QDeclarativeXMLHttpRequest::readEncoding()
}
}
- if (m_mime.isEmpty() || m_mime == "text/xml" || m_mime == "application/xml" || m_mime.endsWith("+xml"))
+ if (m_mime.isEmpty() || m_mime == "text/xml" || m_mime == "application/xml" || m_mime.endsWith("+xml"))
m_gotXml = true;
}
@@ -1355,7 +1355,7 @@ QTextCodec* QDeclarativeXMLHttpRequest::findTextCodec() const
{
QTextCodec *codec = 0;
- if (!m_charset.isEmpty())
+ if (!m_charset.isEmpty())
codec = QTextCodec::codecForName(m_charset);
if (!codec && m_gotXml) {
@@ -1364,7 +1364,7 @@ QTextCodec* QDeclarativeXMLHttpRequest::findTextCodec() const
codec = QTextCodec::codecForName(reader.documentEncoding().toString().toUtf8());
}
- if (!codec && m_mime == "text/html")
+ if (!codec && m_mime == "text/html")
codec = QTextCodec::codecForHtml(m_responseEntityBody, 0);
if (!codec)
@@ -1421,7 +1421,7 @@ static QScriptValue qmlxmlhttprequest_open(QScriptContext *context, QScriptEngin
{
QScriptValue dataObject = context->thisObject().data();
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(dataObject.toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (context->argumentCount() < 2 || context->argumentCount() > 5)
@@ -1429,7 +1429,7 @@ static QScriptValue qmlxmlhttprequest_open(QScriptContext *context, QScriptEngin
// Argument 0 - Method
QString method = context->argument(0).toString().toUpper();
- if (method != QLatin1String("GET") &&
+ if (method != QLatin1String("GET") &&
method != QLatin1String("PUT") &&
method != QLatin1String("HEAD") &&
method != QLatin1String("POST"))
@@ -1468,7 +1468,7 @@ static QScriptValue qmlxmlhttprequest_open(QScriptContext *context, QScriptEngin
static QScriptValue qmlxmlhttprequest_setRequestHeader(QScriptContext *context, QScriptEngine *engine)
{
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(context->thisObject().data().toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (context->argumentCount() != 2)
@@ -1505,7 +1505,7 @@ static QScriptValue qmlxmlhttprequest_setRequestHeader(QScriptContext *context,
nameUpper == QLatin1String("USER-AGENT") ||
nameUpper == QLatin1String("VIA") ||
nameUpper.startsWith(QLatin1String("PROXY-")) ||
- nameUpper.startsWith(QLatin1String("SEC-")))
+ nameUpper.startsWith(QLatin1String("SEC-")))
return engine->undefinedValue();
request->addHeader(nameUpper, value);
@@ -1517,7 +1517,7 @@ static QScriptValue qmlxmlhttprequest_send(QScriptContext *context, QScriptEngin
{
QScriptValue dataObject = context->thisObject().data();
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(dataObject.toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (request->readyState() != QDeclarativeXMLHttpRequest::Opened)
@@ -1537,7 +1537,7 @@ static QScriptValue qmlxmlhttprequest_abort(QScriptContext *context, QScriptEngi
{
QScriptValue dataObject = context->thisObject().data();
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(dataObject.toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
return request->abort(&dataObject);
@@ -1547,7 +1547,7 @@ static QScriptValue qmlxmlhttprequest_getResponseHeader(QScriptContext *context,
{
Q_UNUSED(engine)
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(context->thisObject().data().toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (context->argumentCount() != 1)
@@ -1567,7 +1567,7 @@ static QScriptValue qmlxmlhttprequest_getAllResponseHeaders(QScriptContext *cont
{
Q_UNUSED(engine)
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(context->thisObject().data().toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (context->argumentCount() != 0)
@@ -1586,7 +1586,7 @@ static QScriptValue qmlxmlhttprequest_readyState(QScriptContext *context, QScrip
{
Q_UNUSED(engine)
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(context->thisObject().data().toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
return QScriptValue(request->readyState());
@@ -1596,7 +1596,7 @@ static QScriptValue qmlxmlhttprequest_status(QScriptContext *context, QScriptEng
{
Q_UNUSED(engine)
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(context->thisObject().data().toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (request->readyState() == QDeclarativeXMLHttpRequest::Unsent ||
@@ -1613,7 +1613,7 @@ static QScriptValue qmlxmlhttprequest_statusText(QScriptContext *context, QScrip
{
Q_UNUSED(engine)
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(context->thisObject().data().toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (request->readyState() == QDeclarativeXMLHttpRequest::Unsent ||
@@ -1630,27 +1630,27 @@ static QScriptValue qmlxmlhttprequest_responseText(QScriptContext *context, QScr
{
Q_UNUSED(engine)
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(context->thisObject().data().toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (request->readyState() != QDeclarativeXMLHttpRequest::Loading &&
request->readyState() != QDeclarativeXMLHttpRequest::Done)
return QScriptValue(QString());
- else
+ else
return QScriptValue(request->responseBody());
}
static QScriptValue qmlxmlhttprequest_responseXML(QScriptContext *context, QScriptEngine *engine)
{
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(context->thisObject().data().toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (!request->receivedXml() ||
(request->readyState() != QDeclarativeXMLHttpRequest::Loading &&
request->readyState() != QDeclarativeXMLHttpRequest::Done))
return engine->nullValue();
- else
+ else
return Document::load(engine, request->rawResponseBody());
}
@@ -1659,7 +1659,7 @@ static QScriptValue qmlxmlhttprequest_onreadystatechange(QScriptContext *context
Q_UNUSED(engine);
QScriptValue dataObject = context->thisObject().data();
QDeclarativeXMLHttpRequest *request = qobject_cast<QDeclarativeXMLHttpRequest *>(dataObject.toQObject());
- if (!request)
+ if (!request)
THROW_REFERENCE("Not an XMLHttpRequest object");
if (context->argumentCount()) {
diff --git a/src/declarative/qml/qpodvector_p.h b/src/declarative/qml/qpodvector_p.h
index 0ba070d2..e2eb0310 100644
--- a/src/declarative/qml/qpodvector_p.h
+++ b/src/declarative/qml/qpodvector_p.h
@@ -59,12 +59,12 @@
QT_BEGIN_NAMESPACE
template<class T, int Increment=1024>
-class QPODVector
+class QPODVector
{
public:
QPODVector()
: m_count(0), m_capacity(0), m_data(0) {}
- ~QPODVector() { if (m_data) ::free(m_data); }
+ ~QPODVector() { if (m_data) ::free(m_data); }
const T &at(int idx) const {
return m_data[idx];
@@ -109,8 +109,8 @@ public:
int newSize = m_count + count;
reserve(newSize);
int moveCount = m_count - idx;
- if (moveCount)
- ::memmove(m_data + idx + count, m_data + idx,
+ if (moveCount)
+ ::memmove(m_data + idx + count, m_data + idx,
moveCount * sizeof(T));
m_count = newSize;
}
@@ -118,7 +118,7 @@ public:
void remove(int idx, int count = 1) {
int moveCount = m_count - (idx + count);
if (moveCount)
- ::memmove(m_data + idx, m_data + idx + count,
+ ::memmove(m_data + idx, m_data + idx + count,
moveCount * sizeof(T));
m_count -= count;
}
diff --git a/src/declarative/qml/rewriter/textwriter_p.h b/src/declarative/qml/rewriter/textwriter_p.h
index 38b81f6a..56b4f6e5 100644
--- a/src/declarative/qml/rewriter/textwriter_p.h
+++ b/src/declarative/qml/rewriter/textwriter_p.h
@@ -54,41 +54,41 @@ namespace QDeclarativeJS {
class TextWriter
{
- QString *string;
- QTextCursor *cursor;
+ QString *string;
+ QTextCursor *cursor;
- struct Replace {
- int pos;
- int length;
- QString replacement;
- };
+ struct Replace {
+ int pos;
+ int length;
+ QString replacement;
+ };
- QList<Replace> replaceList;
+ QList<Replace> replaceList;
- struct Move {
- int pos;
- int length;
- int to;
- };
+ struct Move {
+ int pos;
+ int length;
+ int to;
+ };
- QList<Move> moveList;
+ QList<Move> moveList;
- bool hasOverlap(int pos, int length);
- bool hasMoveInto(int pos, int length);
+ bool hasOverlap(int pos, int length);
+ bool hasMoveInto(int pos, int length);
- void doReplace(const Replace &replace);
- void doMove(const Move &move);
+ void doReplace(const Replace &replace);
+ void doMove(const Move &move);
- void write_helper();
+ void write_helper();
public:
- TextWriter();
+ TextWriter();
- void replace(int pos, int length, const QString &replacement);
- void move(int pos, int length, int to);
+ void replace(int pos, int length, const QString &replacement);
+ void move(int pos, int length, int to);
- void write(QString *s);
- void write(QTextCursor *textCursor);
+ void write(QString *s);
+ void write(QTextCursor *textCursor);
};
diff --git a/src/declarative/util/qdeclarativeanimation_p_p.h b/src/declarative/util/qdeclarativeanimation_p_p.h
index bbd4a34e..9dceb5f8 100644
--- a/src/declarative/util/qdeclarativeanimation_p_p.h
+++ b/src/declarative/util/qdeclarativeanimation_p_p.h
@@ -172,7 +172,7 @@ protected:
animValue->setValue(value.toReal());
}
virtual void updateState(State newState, State oldState)
- {
+ {
QVariantAnimation::updateState(newState, oldState);
if (newState == Running) {
//check for new from every loop
diff --git a/src/declarative/util/qdeclarativeconnections.cpp b/src/declarative/util/qdeclarativeconnections.cpp
index c1ee8d41..4d8fc55b 100644
--- a/src/declarative/util/qdeclarativeconnections.cpp
+++ b/src/declarative/util/qdeclarativeconnections.cpp
@@ -88,7 +88,7 @@ public:
}
\endqml
- However, it is not possible to connect to a signal in this way in some
+ However, it is not possible to connect to a signal in this way in some
cases, such as when:
\list
diff --git a/src/declarative/util/qdeclarativefontloader.cpp b/src/declarative/util/qdeclarativefontloader.cpp
index 764257dd..1626cfeb 100644
--- a/src/declarative/util/qdeclarativefontloader.cpp
+++ b/src/declarative/util/qdeclarativefontloader.cpp
@@ -152,16 +152,16 @@ QHash<QUrl, QDeclarativeFontObject*> QDeclarativeFontLoaderPrivate::fonts;
\since 4.7
\brief The FontLoader element allows fonts to be loaded by name or URL.
- The FontLoader element is used to load fonts by name or URL.
-
- The \l status indicates when the font has been loaded, which is useful
+ The FontLoader element is used to load fonts by name or URL.
+
+ The \l status indicates when the font has been loaded, which is useful
for fonts loaded from remote sources.
For example:
\qml
import QtQuick 1.0
- Column {
+ Column {
FontLoader { id: fixedFont; name: "Courier" }
FontLoader { id: webFont; source: "http://www.mysite.com/myfont.ttf" }
diff --git a/src/declarative/util/qdeclarativelistmodel.cpp b/src/declarative/util/qdeclarativelistmodel.cpp
index c9441a0c..cb3f62ef 100644
--- a/src/declarative/util/qdeclarativelistmodel.cpp
+++ b/src/declarative/util/qdeclarativelistmodel.cpp
@@ -210,7 +210,7 @@ QDeclarativeListModelParser::ListInstruction *QDeclarativeListModelParser::ListM
when retrieved from get() is accessible as a list model within the list
model) whereas a FlatListModel cannot.
- ListModel uses a NestedListModel to begin with, and if the model is later
+ ListModel uses a NestedListModel to begin with, and if the model is later
used from a WorkerScript, it changes to use a FlatListModel instead. This
is because ModelNode (which abstracts the nested list model data) needs
access to the declarative engine and script engine, which cannot be
@@ -351,7 +351,7 @@ void QDeclarativeListModel::clear()
QDeclarativeListModel *ModelNode::model(const NestedListModel *model)
{
- if (!modelCache) {
+ if (!modelCache) {
modelCache = new QDeclarativeListModel;
QDeclarativeEngine::setContextForObject(modelCache,QDeclarativeEngine::contextForObject(model->m_listModel));
modelCache->m_nested->_root = this; // ListModel defaults to nestable model
@@ -368,8 +368,8 @@ QDeclarativeListModel *ModelNode::model(const NestedListModel *model)
ModelObject *ModelNode::object(const NestedListModel *model)
{
if (!objectCache) {
- objectCache = new ModelObject(this,
- const_cast<NestedListModel*>(model),
+ objectCache = new ModelObject(this,
+ const_cast<NestedListModel*>(model),
QDeclarativeEnginePrivate::getScriptEngine(qmlEngine(model->m_listModel)));
QHash<QString, ModelNode *>::iterator it;
for (it = properties.begin(); it != properties.end(); ++it) {
@@ -984,7 +984,7 @@ QScriptValue FlatListModel::get(int index) const
{
QScriptEngine *scriptEngine = m_scriptEngine ? m_scriptEngine : QDeclarativeEnginePrivate::getScriptEngine(qmlEngine(m_listModel));
- if (!scriptEngine)
+ if (!scriptEngine)
return 0;
if (index < 0 || index >= m_values.count())
@@ -1101,7 +1101,7 @@ void FlatListModel::moveNodes(int from, int to, int n)
qdeclarativelistmodel_move<QList<FlatNodeData *> >(from, to, n, &m_nodeData);
for (int i=from; i<from + (to-from); i++) {
- if (m_nodeData[i])
+ if (m_nodeData[i])
m_nodeData[i]->index = i;
}
}
@@ -1116,7 +1116,7 @@ FlatNodeData::~FlatNodeData()
}
}
-void FlatNodeData::addData(FlatNodeObjectData *data)
+void FlatNodeData::addData(FlatNodeObjectData *data)
{
objects.insert(data);
}
@@ -1343,9 +1343,9 @@ void NestedListModel::move(int from, int to, int n)
}
QScriptValue NestedListModel::get(int index) const
-{
+{
QDeclarativeEngine *eng = qmlEngine(m_listModel);
- if (!eng)
+ if (!eng)
return 0;
if (index < 0 || index >= count()) {
@@ -1358,7 +1358,7 @@ QScriptValue NestedListModel::get(int index) const
ModelNode *node = qvariant_cast<ModelNode *>(_root->values.at(index));
if (!node)
return 0;
-
+
return QDeclarativeEnginePrivate::qmlScriptObject(node->object(this), eng);
}
diff --git a/src/declarative/util/qdeclarativelistmodel_p_p.h b/src/declarative/util/qdeclarativelistmodel_p_p.h
index 5b204a9a..90d267b9 100644
--- a/src/declarative/util/qdeclarativelistmodel_p_p.h
+++ b/src/declarative/util/qdeclarativelistmodel_p_p.h
@@ -91,7 +91,7 @@ public:
void setProperty(int index, const QString& property, const QVariant& value, QList<int> *roles);
void move(int from, int to, int count);
-private:
+private:
friend class QDeclarativeListModelWorkerAgent;
friend class QDeclarativeListModel;
friend class FlatListScriptClass;
diff --git a/src/declarative/util/qdeclarativelistmodelworkeragent.cpp b/src/declarative/util/qdeclarativelistmodelworkeragent.cpp
index 6020a261..842de7f4 100644
--- a/src/declarative/util/qdeclarativelistmodelworkeragent.cpp
+++ b/src/declarative/util/qdeclarativelistmodelworkeragent.cpp
@@ -53,18 +53,18 @@
QT_BEGIN_NAMESPACE
-void QDeclarativeListModelWorkerAgent::Data::clearChange()
-{
- changes.clear();
+void QDeclarativeListModelWorkerAgent::Data::clearChange()
+{
+ changes.clear();
}
-void QDeclarativeListModelWorkerAgent::Data::insertChange(int index, int count)
+void QDeclarativeListModelWorkerAgent::Data::insertChange(int index, int count)
{
Change c = { Change::Inserted, index, count, 0, QList<int>() };
changes << c;
}
-void QDeclarativeListModelWorkerAgent::Data::removeChange(int index, int count)
+void QDeclarativeListModelWorkerAgent::Data::removeChange(int index, int count)
{
Change c = { Change::Removed, index, count, 0, QList<int>() };
changes << c;
@@ -83,9 +83,9 @@ void QDeclarativeListModelWorkerAgent::Data::changedChange(int index, int count,
}
QDeclarativeListModelWorkerAgent::QDeclarativeListModelWorkerAgent(QDeclarativeListModel *model)
- : m_engine(0),
- m_ref(1),
- m_orig(model),
+ : m_engine(0),
+ m_ref(1),
+ m_orig(model),
m_copy(new QDeclarativeListModel(model, this))
{
}
diff --git a/src/declarative/util/qdeclarativelistmodelworkeragent_p.h b/src/declarative/util/qdeclarativelistmodelworkeragent_p.h
index b076a855..eeb47432 100644
--- a/src/declarative/util/qdeclarativelistmodelworkeragent_p.h
+++ b/src/declarative/util/qdeclarativelistmodelworkeragent_p.h
@@ -101,10 +101,10 @@ public:
VariantRef(QDeclarativeListModelWorkerAgent *_a) : a(_a) { if (a) a->addref(); }
~VariantRef() { if (a) a->release(); }
- VariantRef &operator=(const VariantRef &o) {
- if (o.a) o.a->addref();
- if (a) a->release(); a = o.a;
- return *this;
+ VariantRef &operator=(const VariantRef &o) {
+ if (o.a) o.a->addref();
+ if (a) a->release(); a = o.a;
+ return *this;
}
QDeclarativeListModelWorkerAgent *a;
diff --git a/src/declarative/util/qdeclarativenullablevalue_p_p.h b/src/declarative/util/qdeclarativenullablevalue_p_p.h
index 7773ed8f..8e6360f0 100644
--- a/src/declarative/util/qdeclarativenullablevalue_p_p.h
+++ b/src/declarative/util/qdeclarativenullablevalue_p_p.h
@@ -56,7 +56,7 @@
QT_BEGIN_NAMESPACE
template<typename T>
-struct QDeclarativeNullableValue
+struct QDeclarativeNullableValue
{
QDeclarativeNullableValue()
: isNull(true), value(T()) {}
diff --git a/src/declarative/util/qdeclarativeopenmetaobject.cpp b/src/declarative/util/qdeclarativeopenmetaobject.cpp
index b1c01394..c346c1a4 100644
--- a/src/declarative/util/qdeclarativeopenmetaobject.cpp
+++ b/src/declarative/util/qdeclarativeopenmetaobject.cpp
@@ -235,7 +235,7 @@ int QDeclarativeOpenMetaObject::metaCall(QMetaObject::Call c, int id, void **a)
propertyWritten(propId);
activate(d->object, d->type->d->signalOffset + propId, 0);
}
- }
+ }
return -1;
} else {
if (d->parent)
diff --git a/src/declarative/util/qdeclarativepackage.cpp b/src/declarative/util/qdeclarativepackage.cpp
index c0098c32..59c08986 100644
--- a/src/declarative/util/qdeclarativepackage.cpp
+++ b/src/declarative/util/qdeclarativepackage.cpp
@@ -128,14 +128,14 @@ QDeclarativePackageAttached::~QDeclarativePackageAttached()
attached.remove(parent());
}
-QString QDeclarativePackageAttached::name() const
-{
- return _name;
+QString QDeclarativePackageAttached::name() const
+{
+ return _name;
}
-void QDeclarativePackageAttached::setName(const QString &n)
-{
- _name = n;
+void QDeclarativePackageAttached::setName(const QString &n)
+{
+ _name = n;
}
QDeclarativePackage::QDeclarativePackage(QObject *parent)
@@ -155,9 +155,9 @@ QDeclarativePackage::~QDeclarativePackage()
QDeclarativeListProperty<QObject> QDeclarativePackage::data()
{
Q_D(QDeclarativePackage);
- return QDeclarativeListProperty<QObject>(this, &d->dataList, QDeclarativePackagePrivate::data_append,
- QDeclarativePackagePrivate::data_count,
- QDeclarativePackagePrivate::data_at,
+ return QDeclarativeListProperty<QObject>(this, &d->dataList, QDeclarativePackagePrivate::data_append,
+ QDeclarativePackagePrivate::data_count,
+ QDeclarativePackagePrivate::data_at,
QDeclarativePackagePrivate::data_clear);
}
diff --git a/src/declarative/util/qdeclarativepixmapcache.cpp b/src/declarative/util/qdeclarativepixmapcache.cpp
index 0c660ad9..5438cea1 100644
--- a/src/declarative/util/qdeclarativepixmapcache.cpp
+++ b/src/declarative/util/qdeclarativepixmapcache.cpp
@@ -186,21 +186,21 @@ class QDeclarativePixmapData
{
public:
QDeclarativePixmapData(const QUrl &u, const QSize &s, const QString &e)
- : refCount(1), inCache(false), pixmapStatus(QDeclarativePixmap::Error),
+ : refCount(1), inCache(false), pixmapStatus(QDeclarativePixmap::Error),
url(u), errorString(e), requestSize(s), reply(0), prevUnreferenced(0),
prevUnreferencedPtr(0), nextUnreferenced(0)
{
}
QDeclarativePixmapData(const QUrl &u, const QSize &r)
- : refCount(1), inCache(false), pixmapStatus(QDeclarativePixmap::Loading),
- url(u), requestSize(r), reply(0), prevUnreferenced(0), prevUnreferencedPtr(0),
+ : refCount(1), inCache(false), pixmapStatus(QDeclarativePixmap::Loading),
+ url(u), requestSize(r), reply(0), prevUnreferenced(0), prevUnreferencedPtr(0),
nextUnreferenced(0)
{
}
QDeclarativePixmapData(const QUrl &u, const QPixmap &p, const QSize &s, const QSize &r)
- : refCount(1), inCache(false), privatePixmap(false), pixmapStatus(QDeclarativePixmap::Ready),
+ : refCount(1), inCache(false), privatePixmap(false), pixmapStatus(QDeclarativePixmap::Ready),
url(u), pixmap(p), implicitSize(s), requestSize(r), reply(0), prevUnreferenced(0),
prevUnreferencedPtr(0), nextUnreferenced(0)
{
@@ -223,7 +223,7 @@ public:
bool inCache:1;
bool privatePixmap:1;
-
+
QDeclarativePixmap::Status pixmapStatus;
QUrl url;
QString errorString;
@@ -251,7 +251,7 @@ int QDeclarativePixmapReader::downloadProgress = -1;
int QDeclarativePixmapReader::threadNetworkRequestDone = -1;
-void QDeclarativePixmapReply::postReply(ReadError error, const QString &errorString,
+void QDeclarativePixmapReply::postReply(ReadError error, const QString &errorString,
const QSize &implicitSize, const QImage &image)
{
loading = false;
@@ -272,7 +272,7 @@ QNetworkAccessManager *QDeclarativePixmapReader::networkAccessManager()
return accessManager;
}
-static bool readImage(const QUrl& url, QIODevice *dev, QImage *image, QString *errorString, QSize *impsize,
+static bool readImage(const QUrl& url, QIODevice *dev, QImage *image, QString *errorString, QSize *impsize,
const QSize &requestSize)
{
QImageReader imgio(dev);
@@ -404,17 +404,17 @@ QDeclarativePixmapReaderThreadObject::QDeclarativePixmapReaderThreadObject(QDecl
{
}
-void QDeclarativePixmapReaderThreadObject::processJobs()
-{
- QCoreApplication::postEvent(this, new QEvent(QEvent::User));
+void QDeclarativePixmapReaderThreadObject::processJobs()
+{
+ QCoreApplication::postEvent(this, new QEvent(QEvent::User));
}
-bool QDeclarativePixmapReaderThreadObject::event(QEvent *e)
+bool QDeclarativePixmapReaderThreadObject::event(QEvent *e)
{
- if (e->type() == QEvent::User) {
- reader->processJobs();
- return true;
- } else {
+ if (e->type() == QEvent::User) {
+ reader->processJobs();
+ return true;
+ } else {
return QObject::event(e);
}
}
@@ -430,7 +430,7 @@ void QDeclarativePixmapReader::processJobs()
QMutexLocker locker(&mutex);
while (true) {
- if (cancelled.isEmpty() && (jobs.isEmpty() || replies.count() >= IMAGEREQUEST_MAX_REQUEST_COUNT))
+ if (cancelled.isEmpty() && (jobs.isEmpty() || replies.count() >= IMAGEREQUEST_MAX_REQUEST_COUNT))
return; // Nothing else to do
// Clean cancelled jobs
@@ -461,7 +461,7 @@ void QDeclarativePixmapReader::processJobs()
}
}
-void QDeclarativePixmapReader::processJob(QDeclarativePixmapReply *runningJob, const QUrl &url,
+void QDeclarativePixmapReader::processJob(QDeclarativePixmapReply *runningJob, const QUrl &url,
const QSize &requestSize)
{
// fetch
@@ -535,7 +535,7 @@ QDeclarativePixmapReply *QDeclarativePixmapReader::getImage(QDeclarativePixmapDa
QDeclarativePixmapReply *reply = new QDeclarativePixmapReply(data);
reply->engineForReader = engine;
jobs.append(reply);
- // XXX
+ // XXX
if (threadObject) threadObject->processJobs();
mutex.unlock();
return reply;
@@ -547,7 +547,7 @@ void QDeclarativePixmapReader::cancel(QDeclarativePixmapReply *reply)
if (reply->loading) {
cancelled.append(reply);
reply->data = 0;
- // XXX
+ // XXX
if (threadObject) threadObject->processJobs();
} else {
jobs.removeAll(reply);
@@ -650,7 +650,7 @@ void QDeclarativePixmapStore::unreferencePixmap(QDeclarativePixmapData *data)
shrinkCache(-1); // Shrink the cache incase it has become larger than cache_limit
- if (m_timerId == -1 && m_unreferencedPixmaps)
+ if (m_timerId == -1 && m_unreferencedPixmaps)
m_timerId = startTimer(CACHE_EXPIRE_TIME * 1000);
}
@@ -659,7 +659,7 @@ void QDeclarativePixmapStore::referencePixmap(QDeclarativePixmapData *data)
Q_ASSERT(data->prevUnreferencedPtr);
*data->prevUnreferencedPtr = data->nextUnreferenced;
- if (data->nextUnreferenced) {
+ if (data->nextUnreferenced) {
data->nextUnreferenced->prevUnreferencedPtr = data->prevUnreferencedPtr;
data->nextUnreferenced->prevUnreferenced = data->prevUnreferenced;
}
@@ -731,7 +731,7 @@ bool QDeclarativePixmapReply::event(QEvent *event)
if (data) {
Event *de = static_cast<Event *>(event);
data->pixmapStatus = (de->error == NoError) ? QDeclarativePixmap::Ready : QDeclarativePixmap::Error;
-
+
if (data->pixmapStatus == QDeclarativePixmap::Ready) {
data->pixmap = QPixmap::fromImage(de->image);
data->implicitSize = de->implicitSize;
@@ -759,7 +759,7 @@ int QDeclarativePixmapData::cost() const
void QDeclarativePixmapData::addref()
{
++refCount;
- if (prevUnreferencedPtr)
+ if (prevUnreferencedPtr)
pixmapStore()->referencePixmap(this);
}
@@ -839,7 +839,7 @@ static QDeclarativePixmapData* createPixmapDataSync(QDeclarativeEngine *engine,
}
QString localFile = QDeclarativeEnginePrivate::urlToLocalFileOrQrc(url);
- if (localFile.isEmpty())
+ if (localFile.isEmpty())
return 0;
QFile f(localFile);
@@ -937,7 +937,7 @@ const QUrl &QDeclarativePixmap::url() const
const QSize &QDeclarativePixmap::implicitSize() const
{
- if (d)
+ if (d)
return d->implicitSize;
else
return nullPixmap()->size;
@@ -953,13 +953,13 @@ const QSize &QDeclarativePixmap::requestSize() const
const QPixmap &QDeclarativePixmap::pixmap() const
{
- if (d)
+ if (d)
return d->pixmap;
else
return nullPixmap()->pixmap;
}
-void QDeclarativePixmap::setPixmap(const QPixmap &p)
+void QDeclarativePixmap::setPixmap(const QPixmap &p)
{
clear();
@@ -969,7 +969,7 @@ void QDeclarativePixmap::setPixmap(const QPixmap &p)
int QDeclarativePixmap::width() const
{
- if (d)
+ if (d)
return d->pixmap.width();
else
return 0;
@@ -977,7 +977,7 @@ int QDeclarativePixmap::width() const
int QDeclarativePixmap::height() const
{
- if (d)
+ if (d)
return d->pixmap.height();
else
return 0;
@@ -1018,7 +1018,7 @@ void QDeclarativePixmap::load(QDeclarativeEngine *engine, const QUrl &url, const
if (iter == store->m_cache.end()) {
if (options & QDeclarativePixmap::Asynchronous) {
// pixmaps can only be loaded synchronously
- if (url.scheme() == QLatin1String("image")
+ if (url.scheme() == QLatin1String("image")
&& QDeclarativeEnginePrivate::get(engine)->getImageProviderType(url) == QDeclarativeImageProvider::Pixmap) {
options &= ~QDeclarativePixmap::Asynchronous;
}
@@ -1034,7 +1034,7 @@ void QDeclarativePixmap::load(QDeclarativeEngine *engine, const QUrl &url, const
}
if (d) // loadable, but encountered error while loading
return;
- }
+ }
if (!engine)
return;
@@ -1062,7 +1062,7 @@ void QDeclarativePixmap::clear()
void QDeclarativePixmap::clear(QObject *obj)
{
if (d) {
- if (d->reply)
+ if (d->reply)
QObject::disconnect(d->reply, 0, obj, 0);
d->release();
d = 0;
diff --git a/src/declarative/util/qdeclarativepropertychanges.cpp b/src/declarative/util/qdeclarativepropertychanges.cpp
index cb41ff15..96024fe9 100644
--- a/src/declarative/util/qdeclarativepropertychanges.cpp
+++ b/src/declarative/util/qdeclarativepropertychanges.cpp
@@ -70,28 +70,28 @@ QT_BEGIN_NAMESPACE
\since 4.7
\brief The PropertyChanges element describes new property bindings or values for a state.
- PropertyChanges is used to define the property values or bindings in a
+ PropertyChanges is used to define the property values or bindings in a
\l State. This enables an item's property values to be changed when it
\l {QML States}{changes between states}.
- To create a PropertyChanges object, specify the \l target item whose
+ To create a PropertyChanges object, specify the \l target item whose
properties are to be modified, and define the new property values or
bindings. For example:
-
- \snippet doc/src/snippets/declarative/propertychanges.qml import
+
+ \snippet doc/src/snippets/declarative/propertychanges.qml import
\codeline
\snippet doc/src/snippets/declarative/propertychanges.qml 0
When the mouse is pressed, the \l Rectangle changes to the \e resized
- state. In this state, the PropertyChanges object sets the rectangle's
+ state. In this state, the PropertyChanges object sets the rectangle's
color to blue and the \c height value to that of \c container.height.
- Note this automatically binds \c rect.height to \c container.height
+ Note this automatically binds \c rect.height to \c container.height
in the \e resized state. If a property binding should not be
established, and the height should just be set to the value of
\c container.height at the time of the state change, set the \l explicit
property to \c true.
-
+
A PropertyChanges object can also override the default signal handler
for an object to implement a signal handler specific to the new state:
@@ -191,7 +191,7 @@ public:
if (ownedExpression == rewindExpression)
ownedExpression = 0;
}
- virtual void saveCurrentValues() {
+ virtual void saveCurrentValues() {
rewindExpression = QDeclarativePropertyPrivate::signalExpression(property);
}
@@ -399,7 +399,7 @@ void QDeclarativePropertyChanges::setObject(QObject *o)
\qmlproperty bool PropertyChanges::restoreEntryValues
This property holds whether the previous values should be restored when
- leaving the state.
+ leaving the state.
The default value is \c true. Setting this value to \c false creates a
temporary state that has permanent effects on property values.
diff --git a/src/declarative/util/qdeclarativepropertychanges_p.h b/src/declarative/util/qdeclarativepropertychanges_p.h
index fc7295bd..b385284c 100644
--- a/src/declarative/util/qdeclarativepropertychanges_p.h
+++ b/src/declarative/util/qdeclarativepropertychanges_p.h
@@ -48,7 +48,7 @@
QT_BEGIN_NAMESPACE
QT_MODULE(Declarative)
-
+
class QDeclarativePropertyChangesPrivate;
class Q_DECLARATIVE_PRIVATE_EXPORT QDeclarativePropertyChanges : public QDeclarativeStateOperation
{
diff --git a/src/declarative/util/qdeclarativestate.cpp b/src/declarative/util/qdeclarativestate.cpp
index c6185b7f..fc01ad46 100644
--- a/src/declarative/util/qdeclarativestate.cpp
+++ b/src/declarative/util/qdeclarativestate.cpp
@@ -65,7 +65,7 @@ QDeclarativeAction::QDeclarativeAction()
QDeclarativeAction::QDeclarativeAction(QObject *target, const QString &propertyName,
const QVariant &value)
-: restore(true), actionDone(false), reverseEvent(false), deletableToBinding(false),
+: restore(true), actionDone(false), reverseEvent(false), deletableToBinding(false),
property(target, propertyName, qmlEngine(target)), toValue(value),
fromBinding(0), event(0),
specifiedObject(target), specifiedProperty(propertyName)
@@ -682,7 +682,7 @@ void QDeclarativeState::apply(QDeclarativeStateGroup *group, QDeclarativeTransit
}
if (!found) {
QVariant cur = d->revertList.at(ii).property().read();
- QDeclarativeAbstractBinding *delBinding =
+ QDeclarativeAbstractBinding *delBinding =
QDeclarativePropertyPrivate::setBinding(d->revertList.at(ii).property(), 0);
if (delBinding)
delBinding->destroy();
@@ -714,7 +714,7 @@ void QDeclarativeState::apply(QDeclarativeStateGroup *group, QDeclarativeTransit
qWarning() << " QDeclarativeAction event:" << action.event->typeName();
else
qWarning() << " QDeclarativeAction:" << action.property.object()
- << action.property.name() << "From:" << action.fromValue
+ << action.property.name() << "From:" << action.fromValue
<< "To:" << action.toValue;
}
}
diff --git a/src/declarative/util/qdeclarativestate_p_p.h b/src/declarative/util/qdeclarativestate_p_p.h
index c25c0402..a01c6d0e 100644
--- a/src/declarative/util/qdeclarativestate_p_p.h
+++ b/src/declarative/util/qdeclarativestate_p_p.h
@@ -206,7 +206,7 @@ public:
struct OperationGuard : public QDeclarativeGuard<QDeclarativeStateOperation>
{
- OperationGuard(QObject *obj, QList<OperationGuard> *l) : list(l) {
+ OperationGuard(QObject *obj, QList<OperationGuard> *l) : list(l) {
setObject(static_cast<QDeclarativeStateOperation *>(obj));
}
QList<OperationGuard> *list;
diff --git a/src/declarative/util/qdeclarativestategroup.cpp b/src/declarative/util/qdeclarativestategroup.cpp
index 341e708e..c6a70c85 100644
--- a/src/declarative/util/qdeclarativestategroup.cpp
+++ b/src/declarative/util/qdeclarativestategroup.cpp
@@ -340,8 +340,8 @@ bool QDeclarativeStateGroupPrivate::updateAutoState()
if (state->isWhenKnown()) {
if (state->isNamed()) {
if (state->when() && state->when()->evaluate().toBool()) {
- if (stateChangeDebug())
- qWarning() << "Setting auto state due to:"
+ if (stateChangeDebug())
+ qWarning() << "Setting auto state due to:"
<< state->when()->expression();
if (currentState != state->name()) {
q->setState(state->name());
@@ -376,7 +376,7 @@ QDeclarativeTransition *QDeclarativeStateGroupPrivate::findTransition(const QStr
for (int ii = 0; ii < 2; ++ii)
{
if (ii && (!t->reversible() ||
- (t->fromState() == QLatin1String("*") &&
+ (t->fromState() == QLatin1String("*") &&
t->toState() == QLatin1String("*"))))
break;
QStringList fromState;
@@ -423,7 +423,7 @@ QDeclarativeTransition *QDeclarativeStateGroupPrivate::findTransition(const QStr
return highest;
}
-void QDeclarativeStateGroupPrivate::setCurrentStateInternal(const QString &state,
+void QDeclarativeStateGroupPrivate::setCurrentStateInternal(const QString &state,
bool ignoreTrans)
{
Q_Q(QDeclarativeStateGroup);
@@ -443,7 +443,7 @@ void QDeclarativeStateGroupPrivate::setCurrentStateInternal(const QString &state
if (stateChangeDebug()) {
qWarning() << this << "Changing state. From" << currentState << ". To" << state;
if (transition)
- qWarning() << " using transition" << transition->fromState()
+ qWarning() << " using transition" << transition->fromState()
<< transition->toState();
}
diff --git a/src/declarative/util/qdeclarativestateoperations.cpp b/src/declarative/util/qdeclarativestateoperations.cpp
index 4137de50..62d0e689 100644
--- a/src/declarative/util/qdeclarativestateoperations.cpp
+++ b/src/declarative/util/qdeclarativestateoperations.cpp
@@ -183,8 +183,8 @@ void QDeclarativeParentChangePrivate::doChange(QDeclarativeItem *targetParent, Q
items involved in the reparenting (i.e. items in the common ancestor tree
for the original and new parent).
- The example below displays a large red rectangle and a small blue rectangle, side by side.
- When the \c blueRect is clicked, it changes to the "reparented" state: its parent is changed to \c redRect and it is
+ The example below displays a large red rectangle and a small blue rectangle, side by side.
+ When the \c blueRect is clicked, it changes to the "reparented" state: its parent is changed to \c redRect and it is
positioned at (10, 10) within the red rectangle, as specified in the ParentChange.
\snippet doc/src/snippets/declarative/parentchange.qml 0
diff --git a/src/declarative/util/qdeclarativestateoperations_p.h b/src/declarative/util/qdeclarativestateoperations_p.h
index 01b3e1d8..68a2bef6 100644
--- a/src/declarative/util/qdeclarativestateoperations_p.h
+++ b/src/declarative/util/qdeclarativestateoperations_p.h
@@ -134,7 +134,7 @@ public:
QDeclarativeScriptString script() const;
void setScript(const QDeclarativeScriptString &);
-
+
QString name() const;
void setName(const QString &);
diff --git a/src/declarative/util/qdeclarativesystempalette.cpp b/src/declarative/util/qdeclarativesystempalette.cpp
index 8ebda247..1febf865 100644
--- a/src/declarative/util/qdeclarativesystempalette.cpp
+++ b/src/declarative/util/qdeclarativesystempalette.cpp
@@ -64,7 +64,7 @@ public:
\brief The SystemPalette element provides access to the Qt palettes.
The SystemPalette element provides access to the Qt application
- palettes. This provides information about the standard colors used
+ palettes. This provides information about the standard colors used
for application windows, buttons and other features. These colors
are grouped into three \e {color groups}: \c Active, \c Inactive,
and \c Disabled. See the QPalette documentation for details about
diff --git a/src/declarative/util/qdeclarativetimeline.cpp b/src/declarative/util/qdeclarativetimeline.cpp
index d4045ef3..078cdd6a 100644
--- a/src/declarative/util/qdeclarativetimeline.cpp
+++ b/src/declarative/util/qdeclarativetimeline.cpp
@@ -80,7 +80,7 @@ struct QDeclarativeTimeLinePrivate
Execute
};
Op() {}
- Op(Type t, int l, qreal v, qreal v2, int o,
+ Op(Type t, int l, qreal v, qreal v2, int o,
const QDeclarativeTimeLineCallback &ev = QDeclarativeTimeLineCallback(), const QEasingCurve &es = QEasingCurve())
: type(t), length(l), value(v), value2(v2), order(o), event(ev),
easing(es) {}
@@ -88,8 +88,8 @@ struct QDeclarativeTimeLinePrivate
: type(o.type), length(o.length), value(o.value), value2(o.value2),
order(o.order), event(o.event), easing(o.easing) {}
Op &operator=(const Op &o) {
- type = o.type; length = o.length; value = o.value;
- value2 = o.value2; order = o.order; event = o.event;
+ type = o.type; length = o.length; value = o.value;
+ value2 = o.value2; order = o.order; event = o.event;
easing = o.easing;
return *this;
}
@@ -603,8 +603,8 @@ void QDeclarativeTimeLine::sync(QDeclarativeTimeLineValue &timeLineValue)
d->syncPoint = d->length;
}*/
-/*!
- \internal
+/*!
+ \internal
Temporary hack.
*/
@@ -613,9 +613,9 @@ void QDeclarativeTimeLine::setSyncPoint(int sp)
d->syncPoint = sp;
}
-/*!
- \internal
-
+/*!
+ \internal
+
Temporary hack.
*/
int QDeclarativeTimeLine::syncPoint() const
@@ -738,7 +738,7 @@ int QDeclarativeTimeLinePrivate::advance(int t)
TimeLine &tl = *iter;
Op &op = tl.ops.first();
int length = op.length - tl.consumedOpLength;
-
+
if (length < advanceTime) {
advanceTime = length;
if (advanceTime == 0)
@@ -747,7 +747,7 @@ int QDeclarativeTimeLinePrivate::advance(int t)
}
t -= advanceTime;
- // Process until then. A zero length advance time will only process
+ // Process until then. A zero length advance time will only process
// sets.
QList<QPair<int, Update> > updates;
@@ -761,8 +761,8 @@ int QDeclarativeTimeLinePrivate::advance(int t)
if (advanceTime == 0 && op.length != 0)
continue;
- if (tl.consumedOpLength == 0 &&
- op.type != Op::Pause &&
+ if (tl.consumedOpLength == 0 &&
+ op.type != Op::Pause &&
op.type != Op::Execute)
tl.base = v->value();
diff --git a/src/declarative/util/qdeclarativetransitionmanager.cpp b/src/declarative/util/qdeclarativetransitionmanager.cpp
index 000427d3..232f947f 100644
--- a/src/declarative/util/qdeclarativetransitionmanager.cpp
+++ b/src/declarative/util/qdeclarativetransitionmanager.cpp
@@ -81,7 +81,7 @@ QDeclarativeTransitionManager::~QDeclarativeTransitionManager()
delete d; d = 0;
}
-void QDeclarativeTransitionManager::complete()
+void QDeclarativeTransitionManager::complete()
{
d->applyBindings();
@@ -92,7 +92,7 @@ void QDeclarativeTransitionManager::complete()
d->completeList.clear();
- if (d->state)
+ if (d->state)
static_cast<QDeclarativeStatePrivate*>(QObjectPrivate::get(d->state))->complete();
}
@@ -207,8 +207,8 @@ void QDeclarativeTransitionManager::transition(const QList<QDeclarativeAction> &
} else {
if (touched.contains(action.property)) {
- if (action.toValue != action.fromValue)
- d->completeList <<
+ if (action.toValue != action.fromValue)
+ d->completeList <<
QDeclarativeSimpleAction(action, QDeclarativeSimpleAction::EndState);
applyList.removeAt(ii);
@@ -221,7 +221,7 @@ void QDeclarativeTransitionManager::transition(const QList<QDeclarativeAction> &
// Any actions remaining have not been handled by the transition and should
// be applied immediately. We skip applying bindings, as they are all
- // applied at the end in applyBindings() to avoid any nastiness mid
+ // applied at the end in applyBindings() to avoid any nastiness mid
// transition
foreach(const QDeclarativeAction &action, applyList) {
if (action.event && !action.event->changesBindings()) {
@@ -240,7 +240,7 @@ void QDeclarativeTransitionManager::transition(const QList<QDeclarativeAction> &
qWarning() << " No transition for event:" << action.event->typeName();
else
qWarning() << " No transition for:" << action.property.object()
- << action.property.name() << "From:" << action.fromValue
+ << action.property.name() << "From:" << action.fromValue
<< "To:" << action.toValue;
}
}
diff --git a/src/declarative/util/qdeclarativetransitionmanager_p_p.h b/src/declarative/util/qdeclarativetransitionmanager_p_p.h
index 2902cb41..c37fc6b6 100644
--- a/src/declarative/util/qdeclarativetransitionmanager_p_p.h
+++ b/src/declarative/util/qdeclarativetransitionmanager_p_p.h
@@ -59,7 +59,7 @@ QT_BEGIN_NAMESPACE
class QDeclarativeStatePrivate;
class QDeclarativeTransitionManagerPrivate;
-class Q_AUTOTEST_EXPORT QDeclarativeTransitionManager
+class Q_AUTOTEST_EXPORT QDeclarativeTransitionManager
{
public:
QDeclarativeTransitionManager();
diff --git a/src/declarative/util/qdeclarativexmllistmodel.cpp b/src/declarative/util/qdeclarativexmllistmodel.cpp
index 7139581a..badfff43 100644
--- a/src/declarative/util/qdeclarativexmllistmodel.cpp
+++ b/src/declarative/util/qdeclarativexmllistmodel.cpp
@@ -114,7 +114,7 @@ typedef QPair<int, int> QDeclarativeXmlListRange;
For example, if there is an XML document like this:
\quotefile doc/src/snippets/declarative/xmlrole.xml
-
+
Here are some valid XPath expressions for XmlRole queries on this document:
\snippet doc/src/snippets/declarative/xmlrole.qml 0
@@ -127,7 +127,7 @@ typedef QPair<int, int> QDeclarativeXmlListRange;
/*!
\qmlproperty bool XmlRole::isKey
Defines whether this is a key role.
-
+
Key roles are used to to determine whether a set of values should
be updated or added to the XML list model when XmlListModel::reload()
is called.
@@ -321,7 +321,7 @@ void QDeclarativeXmlQueryEngine::processJobs()
return;
currentJob = m_jobs.takeLast();
}
-
+
locker.unlock();
processQuery(&currentJob);
locker.relock();
@@ -450,7 +450,7 @@ void QDeclarativeXmlQueryEngine::doSubQueryJob(XmlQueryJob *currentJob, QDeclara
for (int i=0; i<currentJob->keyRoleResultsCache.count(); i++) {
if (!keyRoleResults.contains(currentJob->keyRoleResultsCache[i]))
addIndexToRangeList(&currentResult->removed, i);
- else
+ else
temp << currentJob->keyRoleResultsCache[i];
}
@@ -644,10 +644,10 @@ void QDeclarativeXmlListModelPrivate::clear_role(QDeclarativeListProperty<QDecla
\endqml
The \l {XmlListModel::query}{query} value of "/rss/channel/item" specifies that the XmlListModel should generate
- a model item for each \c <item> in the XML document.
-
+ a model item for each \c <item> in the XML document.
+
The XmlRole objects define the
- model item attributes. Here, each model item will have \c title and \c pubDate
+ model item attributes. Here, each model item will have \c title and \c pubDate
attributes that match the \c title and \c pubDate values of its corresponding \c <item>.
(See \l XmlRole::query for more examples of valid XPath expressions for XmlRole.)
@@ -682,8 +682,8 @@ void QDeclarativeXmlListModelPrivate::clear_role(QDeclarativeListProperty<QDecla
\endqml
Then when reload() is called, the model will only add and reload
- items with a "pubDate" value that is not already
- present in the model.
+ items with a "pubDate" value that is not already
+ present in the model.
This is useful when displaying the contents of XML documents that
are incrementally updated (such as RSS feeds) to avoid repainting the
@@ -901,9 +901,9 @@ QScriptValue QDeclarativeXmlListModel::get(int index) const
return sengine->undefinedValue();
QScriptValue sv = sengine->newObject();
- for (int i=0; i<d->roleObjects.count(); i++)
+ for (int i=0; i<d->roleObjects.count(); i++)
sv.setProperty(d->roleObjects[i]->name(), sengine->toScriptValue(d->data.value(i).value(index)));
- return sv;
+ return sv;
}
/*!
@@ -935,7 +935,7 @@ QDeclarativeXmlListModel::Status QDeclarativeXmlListModel::status() const
1.0 (all data downloaded). If the XML data is not from a remote source,
the progress becomes 1.0 as soon as the data is read.
- Note that when the progress is 1.0, the XML data has been downloaded, but
+ Note that when the progress is 1.0, the XML data has been downloaded, but
it is yet to be loaded into the model at this point. Use the status
property to find out when the XML data has been read and loaded into
the model.
@@ -983,13 +983,13 @@ void QDeclarativeXmlListModel::componentComplete()
\qmlmethod XmlListModel::reload()
Reloads the model.
-
+
If no key roles have been specified, all existing model
data is removed, and the model is rebuilt from scratch.
Otherwise, items are only added if the model does not already
contain items with matching key role values.
-
+
\sa {Using key XML roles}, XmlRole::isKey
*/
void QDeclarativeXmlListModel::reload()
diff --git a/src/declarative/util/qlistmodelinterface_p.h b/src/declarative/util/qlistmodelinterface_p.h
index b485c5fe..be097d7e 100644
--- a/src/declarative/util/qlistmodelinterface_p.h
+++ b/src/declarative/util/qlistmodelinterface_p.h
@@ -71,7 +71,7 @@ class Q_DECLARATIVE_PRIVATE_EXPORT QListModelInterface : public QObject
void itemsChanged(int index, int count, const QList<int> &roles);
protected:
- QListModelInterface(QObjectPrivate &dd, QObject *parent)
+ QListModelInterface(QObjectPrivate &dd, QObject *parent)
: QObject(dd, parent) {}
};