aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@digia.com>2014-01-15 22:01:15 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-01-22 21:01:53 +0100
commite2ea0a83cc876fb54a2a8bf6f1350dbfa52f596b (patch)
tree36ec4b74aa50b9355e74e5d186039c3cdbd38acd /src
parent2ce7959eb9e69cd68013fc6a0f77a9556a84365b (diff)
fix whitespace
remove trailing spaces and expand tabs Change-Id: Ieacb9d096b612c45d1a64700044c114d1f7522bc Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src')
-rw-r--r--src/plugins/qmltooling/shared/qpacketprotocol.cpp2
-rw-r--r--src/qml/compiler/qv4instr_moth_p.h6
-rw-r--r--src/qml/compiler/qv4jsir.cpp16
-rw-r--r--src/qml/debugger/qqmlenginedebugservice.cpp12
-rw-r--r--src/qml/doc/snippets/delegatemodel/visualdatamodel_rootindex/view.qml2
-rw-r--r--src/qml/doc/snippets/qml/SelfDestroyingRect.qml4
-rw-r--r--src/qml/doc/snippets/qml/createQmlObject.qml2
-rw-r--r--src/qml/doc/snippets/qml/listmodel/listmodel-nested.qml2
-rw-r--r--src/qml/doc/snippets/qml/qml-documents/inline-component.qml4
-rw-r--r--src/qml/doc/snippets/qml/qml-documents/inline-text-component.qml4
-rw-r--r--src/qml/doc/snippets/qml/qml-documents/non-trivial.qml4
-rw-r--r--src/qml/doc/snippets/qml/qml-documents/qmldocuments.qml2
-rw-r--r--src/qml/doc/snippets/qml/qtobject.qml2
-rw-r--r--src/qml/jsruntime/qv4include.cpp6
-rw-r--r--src/qml/jsruntime/qv4qobjectwrapper.cpp22
-rw-r--r--src/qml/jsruntime/qv4serialize.cpp8
-rw-r--r--src/qml/parser/qqmljslexer.cpp2
-rw-r--r--src/qml/qml/ftw/qbitfield_p.h8
-rw-r--r--src/qml/qml/ftw/qfieldlist_p.h4
-rw-r--r--src/qml/qml/ftw/qfinitestack_p.h8
-rw-r--r--src/qml/qml/ftw/qhashedstring.cpp6
-rw-r--r--src/qml/qml/ftw/qhashedstring_p.h68
-rw-r--r--src/qml/qml/ftw/qhashfield_p.h4
-rw-r--r--src/qml/qml/ftw/qintrusivelist.cpp4
-rw-r--r--src/qml/qml/ftw/qintrusivelist_p.h82
-rw-r--r--src/qml/qml/ftw/qqmlpool_p.h18
-rw-r--r--src/qml/qml/ftw/qqmlrefcount_p.h32
-rw-r--r--src/qml/qml/ftw/qqmlthread.cpp20
-rw-r--r--src/qml/qml/ftw/qqmlthread_p.h2
-rw-r--r--src/qml/qml/ftw/qrecursionwatcher_p.h2
-rw-r--r--src/qml/qml/qqml.h32
-rw-r--r--src/qml/qml/qqmlcleanup.cpp4
-rw-r--r--src/qml/qml/qqmlcleanup_p.h2
-rw-r--r--src/qml/qml/qqmlcompileddata.cpp12
-rw-r--r--src/qml/qml/qqmlcompiler.cpp72
-rw-r--r--src/qml/qml/qqmlcompiler_p.h30
-rw-r--r--src/qml/qml/qqmlcomponent_p.h6
-rw-r--r--src/qml/qml/qqmlcontext.cpp6
-rw-r--r--src/qml/qml/qqmlcontext_p.h2
-rw-r--r--src/qml/qml/qqmlcustomparser.cpp4
-rw-r--r--src/qml/qml/qqmlcustomparser_p.h2
-rw-r--r--src/qml/qml/qqmldata_p.h6
-rw-r--r--src/qml/qml/qqmlengine.cpp2
-rw-r--r--src/qml/qml/qqmlengine_p.h50
-rw-r--r--src/qml/qml/qqmlerror.cpp4
-rw-r--r--src/qml/qml/qqmlglobal_p.h10
-rw-r--r--src/qml/qml/qqmlguard_p.h14
-rw-r--r--src/qml/qml/qqmlimport.cpp4
-rw-r--r--src/qml/qml/qqmlincubator.cpp68
-rw-r--r--src/qml/qml/qqmlincubator.h10
-rw-r--r--src/qml/qml/qqmlinfo.cpp4
-rw-r--r--src/qml/qml/qqmlinstruction_p.h16
-rw-r--r--src/qml/qml/qqmllist.cpp26
-rw-r--r--src/qml/qml/qqmlmetatype.cpp20
-rw-r--r--src/qml/qml/qqmlmetatype_p.h4
-rw-r--r--src/qml/qml/qqmlnotifier.cpp2
-rw-r--r--src/qml/qml/qqmlnotifier_p.h4
-rw-r--r--src/qml/qml/qqmlnullablevalue_p_p.h2
-rw-r--r--src/qml/qml/qqmlopenmetaobject.cpp2
-rw-r--r--src/qml/qml/qqmlparserstatus.cpp2
-rw-r--r--src/qml/qml/qqmlprivate.h8
-rw-r--r--src/qml/qml/qqmlproperty.cpp2
-rw-r--r--src/qml/qml/qqmlproperty.h2
-rw-r--r--src/qml/qml/qqmlproperty_p.h4
-rw-r--r--src/qml/qml/qqmlproxymetaobject.cpp4
-rw-r--r--src/qml/qml/qqmlscript.cpp94
-rw-r--r--src/qml/qml/qqmlscript_p.h26
-rw-r--r--src/qml/qml/qqmlscriptstring.h2
-rw-r--r--src/qml/qml/qqmltypeloader.cpp126
-rw-r--r--src/qml/qml/qqmltypeloader_p.h8
-rw-r--r--src/qml/qml/qqmltypenamecache.cpp2
-rw-r--r--src/qml/qml/qqmltypewrapper.cpp2
-rw-r--r--src/qml/qml/qqmlvaluetype_p.h4
-rw-r--r--src/qml/qml/qqmlvme.cpp88
-rw-r--r--src/qml/qml/qqmlvme_p.h2
-rw-r--r--src/qml/qml/qqmlvmemetaobject.cpp42
-rw-r--r--src/qml/qml/qqmlvmemetaobject_p.h2
-rw-r--r--src/qml/qml/qqmlxmlhttprequest.cpp58
-rw-r--r--src/qml/qml/v8/qv8engine_p.h2
-rw-r--r--src/qml/types/qquickworkerscript.cpp12
-rw-r--r--src/quick/doc/snippets/qml/animatedimage.qml2
-rw-r--r--src/quick/doc/snippets/qml/listview/listview.qml2
-rw-r--r--src/quick/doc/snippets/qml/loader/connections.qml2
-rw-r--r--src/quick/doc/snippets/qml/loader/simple.qml2
-rw-r--r--src/quick/doc/snippets/qml/parentanimation.qml4
-rw-r--r--src/quick/doc/snippets/qml/parentchange.qml4
-rw-r--r--src/quick/doc/snippets/qml/propertyanimation.qml4
-rw-r--r--src/quick/doc/snippets/qml/propertychanges.qml4
-rw-r--r--src/quick/doc/snippets/qml/repeaters/repeater.qml6
-rw-r--r--src/quick/doc/snippets/qml/rotationanimation.qml4
-rw-r--r--src/quick/doc/snippets/qml/row.qml2
-rw-r--r--src/quick/doc/snippets/qml/state.qml4
-rw-r--r--src/quick/doc/snippets/qml/transition-from-to.qml2
-rw-r--r--src/quick/doc/snippets/qml/transition-reversible.qml2
-rw-r--r--src/quick/doc/snippets/qml/transition.qml4
-rw-r--r--src/quick/util/qquickimageprovider.cpp18
-rw-r--r--src/quick/util/qquickpixmapcache.cpp44
-rw-r--r--src/quick/util/qquickstate_p_p.h2
-rw-r--r--src/quick/util/qquicktimeline.cpp24
-rw-r--r--src/quick/util/qquicktransitionmanager.cpp12
-rw-r--r--src/quick/util/qquicktransitionmanager_p_p.h2
101 files changed, 710 insertions, 710 deletions
diff --git a/src/plugins/qmltooling/shared/qpacketprotocol.cpp b/src/plugins/qmltooling/shared/qpacketprotocol.cpp
index 0792dadfe3..7de5a7648e 100644
--- a/src/plugins/qmltooling/shared/qpacketprotocol.cpp
+++ b/src/plugins/qmltooling/shared/qpacketprotocol.cpp
@@ -237,7 +237,7 @@ QPacketProtocol::~QPacketProtocol()
/*!
Returns the maximum packet size allowed. By default this is
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.
diff --git a/src/qml/compiler/qv4instr_moth_p.h b/src/qml/compiler/qv4instr_moth_p.h
index 5b5667abb4..a2cc051003 100644
--- a/src/qml/compiler/qv4instr_moth_p.h
+++ b/src/qml/compiler/qv4instr_moth_p.h
@@ -231,7 +231,7 @@ union Instr
struct instr_ret {
MOTH_INSTR_HEADER
Param result;
- };
+ };
struct instr_loadRuntimeString {
MOTH_INSTR_HEADER
int stringId;
@@ -525,7 +525,7 @@ union Instr
};
struct instr_jump {
MOTH_INSTR_HEADER
- ptrdiff_t offset;
+ ptrdiff_t offset;
};
struct instr_cjump {
MOTH_INSTR_HEADER
@@ -782,7 +782,7 @@ struct InstrMeta {
typedef Instr::instr_##FMT DataType; \
static const DataType &data(const Instr &instr) { return instr.FMT; } \
static void setData(Instr &instr, const DataType &v) { instr.FMT = v; } \
- };
+ };
FOR_EACH_MOTH_INSTR(MOTH_INSTR_META_TEMPLATE);
#undef MOTH_INSTR_META_TEMPLATE
diff --git a/src/qml/compiler/qv4jsir.cpp b/src/qml/compiler/qv4jsir.cpp
index deb1af51b4..ea92bb468d 100644
--- a/src/qml/compiler/qv4jsir.cpp
+++ b/src/qml/compiler/qv4jsir.cpp
@@ -740,7 +740,7 @@ Temp *BasicBlock::LOCAL(unsigned index, unsigned scope)
}
Expr *BasicBlock::CONST(Type type, double value)
-{
+{
Const *e = function->New<Const>();
if (type == NumberType) {
int ival = (int)value;
@@ -769,7 +769,7 @@ Expr *BasicBlock::REGEXP(const QString *value, int flags)
}
Name *BasicBlock::NAME(const QString &id, quint32 line, quint32 column)
-{
+{
Name *e = function->New<Name>();
e->init(function->newString(id), line, column);
return e;
@@ -805,7 +805,7 @@ Expr *BasicBlock::CONVERT(Expr *expr, Type type)
}
Expr *BasicBlock::UNOP(AluOp op, Expr *expr)
-{
+{
Unop *e = function->New<Unop>();
e->init(op, expr);
return e;
@@ -819,7 +819,7 @@ Expr *BasicBlock::BINOP(AluOp op, Expr *left, Expr *right)
}
Expr *BasicBlock::CALL(Expr *base, ExprList *args)
-{
+{
Call *e = function->New<Call>();
e->init(base, args);
int argc = 0;
@@ -851,7 +851,7 @@ Expr *BasicBlock::MEMBER(Expr *base, const QString *name, QQmlPropertyData *prop
}
Stmt *BasicBlock::EXP(Expr *expr)
-{
+{
if (isTerminated())
return 0;
@@ -862,7 +862,7 @@ Stmt *BasicBlock::EXP(Expr *expr)
}
Stmt *BasicBlock::MOVE(Expr *target, Expr *source)
-{
+{
if (isTerminated())
return 0;
@@ -872,7 +872,7 @@ Stmt *BasicBlock::MOVE(Expr *target, Expr *source)
return s;
}
-Stmt *BasicBlock::JUMP(BasicBlock *target)
+Stmt *BasicBlock::JUMP(BasicBlock *target)
{
if (isTerminated())
return 0;
@@ -890,7 +890,7 @@ Stmt *BasicBlock::JUMP(BasicBlock *target)
return s;
}
-Stmt *BasicBlock::CJUMP(Expr *cond, BasicBlock *iftrue, BasicBlock *iffalse)
+Stmt *BasicBlock::CJUMP(Expr *cond, BasicBlock *iftrue, BasicBlock *iffalse)
{
if (isTerminated())
return 0;
diff --git a/src/qml/debugger/qqmlenginedebugservice.cpp b/src/qml/debugger/qqmlenginedebugservice.cpp
index 5f3db9fb65..300561050f 100644
--- a/src/qml/debugger/qqmlenginedebugservice.cpp
+++ b/src/qml/debugger/qqmlenginedebugservice.cpp
@@ -83,7 +83,7 @@ QQmlEngineDebugService::~QQmlEngineDebugService()
delete m_statesDelegate;
}
-QDataStream &operator<<(QDataStream &ds,
+QDataStream &operator<<(QDataStream &ds,
const QQmlEngineDebugService::QQmlObjectData &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,
QQmlEngineDebugService::QQmlObjectData &data)
{
ds >> data.url >> data.lineNumber >> data.columnNumber >> data.idString
@@ -101,7 +101,7 @@ QDataStream &operator>>(QDataStream &ds,
return ds;
}
-QDataStream &operator<<(QDataStream &ds,
+QDataStream &operator<<(QDataStream &ds,
const QQmlEngineDebugService::QQmlObjectProperty &data)
{
ds << (int)data.type << data.name << data.value << data.valueTypeName
@@ -109,7 +109,7 @@ QDataStream &operator<<(QDataStream &ds,
return ds;
}
-QDataStream &operator>>(QDataStream &ds,
+QDataStream &operator>>(QDataStream &ds,
QQmlEngineDebugService::QQmlObjectProperty &data)
{
int type;
@@ -219,13 +219,13 @@ QVariant QQmlEngineDebugService::valueContents(const QVariant &value) const
return QString(QStringLiteral("<unknown value>"));
}
-void QQmlEngineDebugService::buildObjectDump(QDataStream &message,
+void QQmlEngineDebugService::buildObjectDump(QDataStream &message,
QObject *object, bool recur, bool dumpProperties)
{
message << objectData(object);
QObjectList children = object->children();
-
+
int childrenCount = children.count();
for (int ii = 0; ii < children.count(); ++ii) {
if (qobject_cast<QQmlContext*>(children[ii]))
diff --git a/src/qml/doc/snippets/delegatemodel/visualdatamodel_rootindex/view.qml b/src/qml/doc/snippets/delegatemodel/visualdatamodel_rootindex/view.qml
index 1e8cfade96..f46671e9a0 100644
--- a/src/qml/doc/snippets/delegatemodel/visualdatamodel_rootindex/view.qml
+++ b/src/qml/doc/snippets/delegatemodel/visualdatamodel_rootindex/view.qml
@@ -55,7 +55,7 @@ ListView {
MouseArea {
anchors.fill: parent
onClicked: {
- if (model.hasModelChildren)
+ if (model.hasModelChildren)
view.model.rootIndex = view.model.modelIndex(index)
}
}
diff --git a/src/qml/doc/snippets/qml/SelfDestroyingRect.qml b/src/qml/doc/snippets/qml/SelfDestroyingRect.qml
index b2e8c318f2..16a73c204d 100644
--- a/src/qml/doc/snippets/qml/SelfDestroyingRect.qml
+++ b/src/qml/doc/snippets/qml/SelfDestroyingRect.qml
@@ -45,9 +45,9 @@ Rectangle {
width: 80; height: 80
color: "red"
- NumberAnimation on opacity {
+ NumberAnimation on opacity {
to: 0
- duration: 1000
+ duration: 1000
onRunningChanged: {
if (!running) {
diff --git a/src/qml/doc/snippets/qml/createQmlObject.qml b/src/qml/doc/snippets/qml/createQmlObject.qml
index 7984261f0f..10f49f13c3 100644
--- a/src/qml/doc/snippets/qml/createQmlObject.qml
+++ b/src/qml/doc/snippets/qml/createQmlObject.qml
@@ -45,7 +45,7 @@ Rectangle {
width: 100
height: 100
-
+
function createIt() {
//![0]
var newObject = Qt.createQmlObject('import QtQuick 2.0; Rectangle {color: "red"; width: 20; height: 20}',
diff --git a/src/qml/doc/snippets/qml/listmodel/listmodel-nested.qml b/src/qml/doc/snippets/qml/listmodel/listmodel-nested.qml
index c9637712f6..3c836d81cf 100644
--- a/src/qml/doc/snippets/qml/listmodel/listmodel-nested.qml
+++ b/src/qml/doc/snippets/qml/listmodel/listmodel-nested.qml
@@ -86,7 +86,7 @@ Component {
Text { text: "Attributes:" }
Repeater {
model: attributes
- Text { text: description }
+ Text { text: description }
}
}
}
diff --git a/src/qml/doc/snippets/qml/qml-documents/inline-component.qml b/src/qml/doc/snippets/qml/qml-documents/inline-component.qml
index 5b600499c4..b8144c263f 100644
--- a/src/qml/doc/snippets/qml/qml-documents/inline-component.qml
+++ b/src/qml/doc/snippets/qml/qml-documents/inline-component.qml
@@ -42,7 +42,7 @@
import QtQuick 2.0
Rectangle {
- width: 240; height: 320;
+ width: 240; height: 320;
ListView {
anchors.fill: parent
@@ -52,6 +52,6 @@ Rectangle {
text: modelData.firstName + " " + modelData.lastName
}
}
- }
+ }
}
//! [document]
diff --git a/src/qml/doc/snippets/qml/qml-documents/inline-text-component.qml b/src/qml/doc/snippets/qml/qml-documents/inline-text-component.qml
index 44d67a7480..e731ce998f 100644
--- a/src/qml/doc/snippets/qml/qml-documents/inline-text-component.qml
+++ b/src/qml/doc/snippets/qml/qml-documents/inline-text-component.qml
@@ -42,7 +42,7 @@
import QtQuick 2.0
Rectangle {
- width: 240; height: 320;
+ width: 240; height: 320;
ListView {
anchors.fill: parent
@@ -50,6 +50,6 @@ Rectangle {
delegate: Text {
text: modelData.firstName + " " + modelData.lastName
}
- }
+ }
}
//! [document]
diff --git a/src/qml/doc/snippets/qml/qml-documents/non-trivial.qml b/src/qml/doc/snippets/qml/qml-documents/non-trivial.qml
index ccf4603b44..cedd09d3ce 100644
--- a/src/qml/doc/snippets/qml/qml-documents/non-trivial.qml
+++ b/src/qml/doc/snippets/qml/qml-documents/non-trivial.qml
@@ -42,7 +42,7 @@
import QtQuick 2.0
Rectangle {
- width: 240; height: 320;
+ width: 240; height: 320;
resources: [
Component {
@@ -57,6 +57,6 @@ Rectangle {
anchors.fill: parent
model: contactModel
delegate: contactDelegate
- }
+ }
}
//! [document]
diff --git a/src/qml/doc/snippets/qml/qml-documents/qmldocuments.qml b/src/qml/doc/snippets/qml/qml-documents/qmldocuments.qml
index 66322fdfd1..fd582db061 100644
--- a/src/qml/doc/snippets/qml/qml-documents/qmldocuments.qml
+++ b/src/qml/doc/snippets/qml/qml-documents/qmldocuments.qml
@@ -45,7 +45,7 @@ Rectangle {
property alias text: textItem.text
width: 100; height: 30
- border.width: 1
+ border.width: 1
radius: 5
antialiasing: true
diff --git a/src/qml/doc/snippets/qml/qtobject.qml b/src/qml/doc/snippets/qml/qtobject.qml
index 7d0957326e..6fdf7f74d3 100644
--- a/src/qml/doc/snippets/qml/qtobject.qml
+++ b/src/qml/doc/snippets/qml/qtobject.qml
@@ -41,7 +41,7 @@
import QtQuick 2.0
Item {
- QtObject {
+ QtObject {
id: attributes
property string name
property int size
diff --git a/src/qml/jsruntime/qv4include.cpp b/src/qml/jsruntime/qv4include.cpp
index d0e0e9413b..7642db1e9b 100644
--- a/src/qml/jsruntime/qv4include.cpp
+++ b/src/qml/jsruntime/qv4include.cpp
@@ -131,8 +131,8 @@ void QV4Include::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);
@@ -209,7 +209,7 @@ QV4::ReturnedValue QV4Include::method_include(QV4::CallContext *ctx)
callbackFunction);
result = i->result();
- } else {
+ } else {
QFile f(localFile);
diff --git a/src/qml/jsruntime/qv4qobjectwrapper.cpp b/src/qml/jsruntime/qv4qobjectwrapper.cpp
index c27cea9cb6..1cf6ef06b7 100644
--- a/src/qml/jsruntime/qv4qobjectwrapper.cpp
+++ b/src/qml/jsruntime/qv4qobjectwrapper.cpp
@@ -1114,7 +1114,7 @@ static QV4::ReturnedValue CallMethod(QObject *object, int index, int returnType,
return args[0].toValue(engine);
} else if (returnType != QMetaType::Void) {
-
+
CallArgument arg;
arg.initAsType(returnType);
@@ -1134,7 +1134,7 @@ static QV4::ReturnedValue CallMethod(QObject *object, int index, int returnType,
}
/*!
- 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 \l QScript::callQtMethod() function.
@@ -1308,7 +1308,7 @@ static const QQmlPropertyData * RelatedMethod(QObject *object,
QMetaMethod method = mo->method(current->overrideIndex);
dummy.load(method);
-
+
// Look for overloaded methods
QByteArray methodName = method.name();
for (int ii = current->overrideIndex - 1; ii >= methodOffset; --ii) {
@@ -1342,7 +1342,7 @@ static QV4::ReturnedValue CallPrecise(QObject *object, const QQmlPropertyData &d
int *args = 0;
QVarLengthArray<int, 9> dummy;
- args = QQmlPropertyCache::methodParameterTypes(object, data.coreIndex, dummy,
+ args = QQmlPropertyCache::methodParameterTypes(object, data.coreIndex, dummy,
&unknownTypeError);
if (!args) {
@@ -1368,13 +1368,13 @@ static QV4::ReturnedValue CallPrecise(QObject *object, const QQmlPropertyData &d
/*!
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.
*/
@@ -1425,7 +1425,7 @@ static QV4::ReturnedValue CallOverloaded(QObject *object, const QQmlPropertyData
continue; // We already have a better option
int methodMatchScore = 0;
- for (int ii = 0; ii < methodArgumentCount; ++ii)
+ for (int ii = 0; ii < methodArgumentCount; ++ii)
methodMatchScore += MatchScore((v = callArgs->args[ii]), methodArgTypes[ii]);
if (bestParameterScore > methodParameterScore || bestMatchScore > methodMatchScore) {
@@ -1447,7 +1447,7 @@ static QV4::ReturnedValue CallOverloaded(QObject *object, const QQmlPropertyData
QString error = QLatin1String("Unable to determine callable overload. Candidates are:");
const QQmlPropertyData *candidate = &data;
while (candidate) {
- error += QLatin1String("\n ") +
+ error += QLatin1String("\n ") +
QString::fromUtf8(object->metaObject()->method(candidate->coreIndex).methodSignature().constData());
candidate = RelatedMethod(object, candidate, dummy);
}
@@ -1482,7 +1482,7 @@ void CallArgument::cleanup()
jsonObjectPtr->~QJsonObject();
} else if (type == QMetaType::QJsonValue) {
jsonValuePtr->~QJsonValue();
- }
+ }
}
void *CallArgument::dataPtr()
diff --git a/src/qml/jsruntime/qv4serialize.cpp b/src/qml/jsruntime/qv4serialize.cpp
index dec0f69147..084ff9c98c 100644
--- a/src/qml/jsruntime/qv4serialize.cpp
+++ b/src/qml/jsruntime/qv4serialize.cpp
@@ -55,13 +55,13 @@ QT_BEGIN_NAMESPACE
using namespace QV4;
-// We allow the following JavaScript types to be passed between the main and
+// We allow the following JavaScript types to be passed between the main and
// the secondary thread:
// + undefined
// + null
// + Boolean
// + String
-// + Function
+// + Function
// + Array
// + "Simple" Objects
// + Number
@@ -143,7 +143,7 @@ static inline void *popPtr(const char *&data)
return rv;
}
-// XXX TODO: Check that worker script is exception safe in the case of
+// XXX TODO: Check that worker script is exception safe in the case of
// serialization/deserialization failures
#define ALIGN(size) (((size) + 3) & ~3)
@@ -171,7 +171,7 @@ void Serialize::serialize(QByteArray &data, const QV4::ValueRef v, QV8Engine *en
reserve(data, utf16size + sizeof(quint32));
push(data, valueheader(WorkerString, length));
-
+
int offset = data.size();
data.resize(data.size() + utf16size);
char *buffer = data.data() + offset;
diff --git a/src/qml/parser/qqmljslexer.cpp b/src/qml/parser/qqmljslexer.cpp
index 8e8ed954ad..73d0a8c3dd 100644
--- a/src/qml/parser/qqmljslexer.cpp
+++ b/src/qml/parser/qqmljslexer.cpp
@@ -707,7 +707,7 @@ again:
_validTokenText = true;
_tokenText.resize(0);
startCode--;
- while (startCode != _codePtr - 1)
+ while (startCode != _codePtr - 1)
_tokenText += *startCode++;
while (_codePtr <= _endPtr) {
diff --git a/src/qml/qml/ftw/qbitfield_p.h b/src/qml/qml/ftw/qbitfield_p.h
index b224f5b57d..12e98dc655 100644
--- a/src/qml/qml/ftw/qbitfield_p.h
+++ b/src/qml/qml/ftw/qbitfield_p.h
@@ -91,13 +91,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;
}
@@ -106,14 +106,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/qml/qml/ftw/qfieldlist_p.h b/src/qml/qml/ftw/qfieldlist_p.h
index 5d37751f05..c90b6773a1 100644
--- a/src/qml/qml/ftw/qfieldlist_p.h
+++ b/src/qml/qml/ftw/qfieldlist_p.h
@@ -90,7 +90,7 @@ private:
// QFieldList is a simple linked list, that can append and prepend and also
// maintains a count
template<class N, N *N::*nextMember>
-class QFieldList
+class QFieldList
{
public:
inline QFieldList();
@@ -253,7 +253,7 @@ N *QFieldList<N, nextMember>::takeFirst()
}
value->*nextMember = 0;
--_count;
- }
+ }
return value;
}
diff --git a/src/qml/qml/ftw/qfinitestack_p.h b/src/qml/qml/ftw/qfinitestack_p.h
index 8b499d9b6d..31a530fa64 100644
--- a/src/qml/qml/ftw/qfinitestack_p.h
+++ b/src/qml/qml/ftw/qfinitestack_p.h
@@ -83,7 +83,7 @@ private:
template<typename T>
QFiniteStack<T>::QFiniteStack()
-: _array(0), _alloc(0), _size(0)
+: _array(0), _alloc(0), _size(0)
{
}
@@ -134,7 +134,7 @@ T QFiniteStack<T>::pop()
return _array[_size];
}
}
-
+
template<typename T>
int QFiniteStack<T>::count() const
{
@@ -154,7 +154,7 @@ T &QFiniteStack<T>::operator[](int index)
}
template<typename T>
-void QFiniteStack<T>::allocate(int size)
+void QFiniteStack<T>::allocate(int size)
{
Q_ASSERT(_array == 0);
Q_ASSERT(_alloc == 0);
@@ -171,7 +171,7 @@ void QFiniteStack<T>::deallocate()
{
if (QTypeInfo<T>::isComplex) {
T *i = _array + _size;
- while (i != _array)
+ while (i != _array)
(--i)->~T();
}
diff --git a/src/qml/qml/ftw/qhashedstring.cpp b/src/qml/qml/ftw/qhashedstring.cpp
index 012412b6b5..fa3524ff3e 100644
--- a/src/qml/qml/ftw/qhashedstring.cpp
+++ b/src/qml/qml/ftw/qhashedstring.cpp
@@ -198,19 +198,19 @@ bool QHashedString::compare(const QChar *lhs, const QChar *rhs, int length)
QHashedStringRef QHashedStringRef::mid(int offset, int length) const
{
Q_ASSERT(offset < m_length);
- return QHashedStringRef(m_data + offset,
+ return QHashedStringRef(m_data + offset,
(length == -1 || (offset + length) > m_length)?(m_length - offset):length);
}
bool QHashedStringRef::endsWith(const QString &s) const
{
- return s.length() < m_length &&
+ return s.length() < m_length &&
QHashedString::compare(s.constData(), m_data + m_length - s.length(), s.length());
}
bool QHashedStringRef::startsWith(const QString &s) const
{
- return s.length() < m_length &&
+ return s.length() < m_length &&
QHashedString::compare(s.constData(), m_data, s.length());
}
diff --git a/src/qml/qml/ftw/qhashedstring_p.h b/src/qml/qml/ftw/qhashedstring_p.h
index 46f0533740..61a492013d 100644
--- a/src/qml/qml/ftw/qhashedstring_p.h
+++ b/src/qml/qml/ftw/qhashedstring_p.h
@@ -97,7 +97,7 @@ private:
};
class QHashedCStringRef;
-class Q_AUTOTEST_EXPORT QHashedStringRef
+class Q_AUTOTEST_EXPORT QHashedStringRef
{
public:
inline QHashedStringRef();
@@ -258,15 +258,15 @@ public:
}
inline bool equals(const QHashedStringRef &string) const {
- return length == string.length() &&
- hash == string.hash() &&
+ return length == string.length() &&
+ hash == string.hash() &&
(isQString()?QHashedString::compare(string.constData(), (QChar *)utf16Data(), length):
QHashedString::compare(string.constData(), cStrData(), length));
}
inline bool equals(const QHashedCStringRef &string) const {
- return length == string.length() &&
- hash == string.hash() &&
+ return length == string.length() &&
+ hash == string.hash() &&
(isQString()?QHashedString::compare((QChar *)utf16Data(), string.constData(), length):
QHashedString::compare(string.constData(), cStrData(), length));
}
@@ -275,7 +275,7 @@ public:
class Q_AUTOTEST_EXPORT QStringHashData
{
public:
- QStringHashData()
+ QStringHashData()
: buckets(0), numBuckets(0), size(0), numBits(0)
#ifdef QSTRINGHASH_LINK_DEBUG
, linkCount(0)
@@ -1026,33 +1026,33 @@ typename QStringHash<T>::ConstIterator QStringMultiHash<T>::findNext(const Const
return ConstIterator();
}
-inline uint qHash(const QHashedString &string)
-{
- return uint(string.hash());
+inline uint qHash(const QHashedString &string)
+{
+ return uint(string.hash());
}
-inline uint qHash(const QHashedStringRef &string)
-{
- return uint(string.hash());
+inline uint qHash(const QHashedStringRef &string)
+{
+ return uint(string.hash());
}
-QHashedString::QHashedString()
-: QString(), m_hash(0)
+QHashedString::QHashedString()
+: QString(), m_hash(0)
{
}
-QHashedString::QHashedString(const QString &string)
-: QString(string), m_hash(0)
+QHashedString::QHashedString(const QString &string)
+: QString(string), m_hash(0)
{
}
-QHashedString::QHashedString(const QString &string, quint32 hash)
-: QString(string), m_hash(hash)
+QHashedString::QHashedString(const QString &string, quint32 hash)
+: QString(string), m_hash(hash)
{
}
-QHashedString::QHashedString(const QHashedString &string)
-: QString(string), m_hash(string.m_hash)
+QHashedString::QHashedString(const QHashedString &string)
+: QString(string), m_hash(string.m_hash)
{
}
@@ -1065,29 +1065,29 @@ QHashedString &QHashedString::operator=(const QHashedString &string)
bool QHashedString::operator==(const QHashedString &string) const
{
- return (string.m_hash == m_hash || !string.m_hash || !m_hash) &&
+ return (string.m_hash == m_hash || !string.m_hash || !m_hash) &&
static_cast<const QString &>(*this) == static_cast<const QString &>(string);
}
bool QHashedString::operator==(const QHashedStringRef &string) const
{
return length() == string.m_length &&
- (string.m_hash == m_hash || !string.m_hash || !m_hash) &&
+ (string.m_hash == m_hash || !string.m_hash || !m_hash) &&
QHashedString::compare(constData(), string.m_data, string.m_length);
}
quint32 QHashedString::hash() const
-{
+{
if (!m_hash) computeHash();
return m_hash;
}
quint32 QHashedString::existingHash() const
-{
+{
return m_hash;
}
-QHashedStringRef::QHashedStringRef()
+QHashedStringRef::QHashedStringRef()
: m_data(0), m_length(0), m_hash(0)
{
}
@@ -1138,21 +1138,21 @@ bool QHashedStringRef::operator==(const QString &string) const
bool QHashedStringRef::operator==(const QHashedString &string) const
{
- return m_length == string.length() &&
+ return m_length == string.length() &&
(m_hash == string.m_hash || !m_hash || !string.m_hash) &&
QHashedString::compare(string.constData(), m_data, m_length);
}
bool QHashedStringRef::operator==(const QHashedStringRef &string) const
{
- return m_length == string.m_length &&
+ return m_length == string.m_length &&
(m_hash == string.m_hash || !m_hash || !string.m_hash) &&
QHashedString::compare(string.m_data, m_data, m_length);
}
bool QHashedStringRef::operator==(const QHashedCStringRef &string) const
{
- return m_length == string.m_length &&
+ return m_length == string.m_length &&
(m_hash == string.m_hash || !m_hash || !string.m_hash) &&
QHashedString::compare(m_data, string.m_data, m_length);
}
@@ -1165,7 +1165,7 @@ bool QHashedStringRef::operator!=(const QString &string) const
bool QHashedStringRef::operator!=(const QHashedString &string) const
{
- return m_length != string.length() ||
+ return m_length != string.length() ||
(m_hash != string.m_hash && m_hash && string.m_hash) ||
!QHashedString::compare(string.constData(), m_data, m_length);
}
@@ -1224,7 +1224,7 @@ bool QHashedStringRef::startsWithUpper() const
}
quint32 QHashedStringRef::hash() const
-{
+{
if (!m_hash) computeHash();
return m_hash;
}
@@ -1279,20 +1279,20 @@ void QHashedCStringRef::writeUtf16(quint16 *output) const
{
int l = m_length;
const char *d = m_data;
- while (l--)
+ while (l--)
*output++ = *d++;
}
-bool QHashedString::compare(const QChar *lhs, const char *rhs, int length)
+bool QHashedString::compare(const QChar *lhs, const char *rhs, int length)
{
Q_ASSERT(lhs && rhs);
const quint16 *l = (const quint16*)lhs;
- while (length--)
+ while (length--)
if (*l++ != *rhs++) return false;
return true;
}
-bool QHashedString::compare(const char *lhs, const char *rhs, int length)
+bool QHashedString::compare(const char *lhs, const char *rhs, int length)
{
Q_ASSERT(lhs && rhs);
return 0 == ::memcmp(lhs, rhs, length);
diff --git a/src/qml/qml/ftw/qhashfield_p.h b/src/qml/qml/ftw/qhashfield_p.h
index 32c7a0fbe2..aa8840688a 100644
--- a/src/qml/qml/ftw/qhashfield_p.h
+++ b/src/qml/qml/ftw/qhashfield_p.h
@@ -63,7 +63,7 @@ QT_BEGIN_NAMESPACE
// example where you would write:
// QSet<QString> strings;
// for (int ii = 0; ii < mystrings.count(); ++ii) {
-// if (strings.contains(mystrings.at(ii)))
+// if (strings.contains(mystrings.at(ii)))
// qFatal("Duplication!");
// strings.insert(mystrings);
// }
@@ -73,7 +73,7 @@ QT_BEGIN_NAMESPACE
// if (strings.testAndSet(qHash(mystrings.at(ii)))) {
// // The string *might* be duplicated
// for (int jj = 0; jj < ii; ++jj) {
-// if (mystrings.at(ii) == mystrings.at(jj))
+// if (mystrings.at(ii) == mystrings.at(jj))
// qFatal("Duplication!");
// }
// }
diff --git a/src/qml/qml/ftw/qintrusivelist.cpp b/src/qml/qml/ftw/qintrusivelist.cpp
index 12d710ca47..7c80b57c9d 100644
--- a/src/qml/qml/ftw/qintrusivelist.cpp
+++ b/src/qml/qml/ftw/qintrusivelist.cpp
@@ -46,7 +46,7 @@
\brief The QIntrusiveList class is a template class that provides a list of objects using static storage.
\internal
-QIntrusiveList creates a linked list of objects. Adding and removing objects from the
+QIntrusiveList creates a linked list of objects. Adding and removing objects from the
QIntrusiveList is a constant time operation and is very quick. The list performs no memory
allocations, but does require the objects being added to the list to contain a QIntrusiveListNode
instance for the list's use. Even so, for small lists QIntrusiveList uses less memory than Qt's
@@ -102,7 +102,7 @@ Destroy the list. All entries are removed.
/*!
\fn void QIntrusiveList::insert(N *object);
-Insert \a object into the list. If \a object is a member of this, or another list, it will be
+Insert \a object into the list. If \a object is a member of this, or another list, it will be
removed and inserted at the head of this list.
*/
diff --git a/src/qml/qml/ftw/qintrusivelist_p.h b/src/qml/qml/ftw/qintrusivelist_p.h
index ccaeee2e40..67de569951 100644
--- a/src/qml/qml/ftw/qintrusivelist_p.h
+++ b/src/qml/qml/ftw/qintrusivelist_p.h
@@ -82,7 +82,7 @@ public:
inline iterator &operator++();
inline iterator &erase();
-
+
private:
N *_value;
};
@@ -114,60 +114,60 @@ public:
};
template<class N, QIntrusiveListNode N::*member>
-QIntrusiveList<N, member>::iterator::iterator()
-: _value(0)
+QIntrusiveList<N, member>::iterator::iterator()
+: _value(0)
{
}
template<class N, QIntrusiveListNode N::*member>
-QIntrusiveList<N, member>::iterator::iterator(N *value)
-: _value(value)
+QIntrusiveList<N, member>::iterator::iterator(N *value)
+: _value(value)
{
}
template<class N, QIntrusiveListNode N::*member>
-N *QIntrusiveList<N, member>::iterator::operator*() const
-{
- return _value;
+N *QIntrusiveList<N, member>::iterator::operator*() const
+{
+ return _value;
}
template<class N, QIntrusiveListNode N::*member>
-N *QIntrusiveList<N, member>::iterator::operator->() const
-{
- return _value;
+N *QIntrusiveList<N, member>::iterator::operator->() const
+{
+ return _value;
}
template<class N, QIntrusiveListNode N::*member>
-bool QIntrusiveList<N, member>::iterator::operator==(const iterator &other) const
-{
- return other._value == _value;
+bool QIntrusiveList<N, member>::iterator::operator==(const iterator &other) const
+{
+ return other._value == _value;
}
template<class N, QIntrusiveListNode N::*member>
-bool QIntrusiveList<N, member>::iterator::operator!=(const iterator &other) const
-{
- return other._value != _value;
+bool QIntrusiveList<N, member>::iterator::operator!=(const iterator &other) const
+{
+ return other._value != _value;
}
template<class N, QIntrusiveListNode N::*member>
-typename QIntrusiveList<N, member>::iterator &QIntrusiveList<N, member>::iterator::operator++()
-{
- _value = QIntrusiveList<N, member>::next(_value);
- return *this;
+typename QIntrusiveList<N, member>::iterator &QIntrusiveList<N, member>::iterator::operator++()
+{
+ _value = QIntrusiveList<N, member>::next(_value);
+ return *this;
}
template<class N, QIntrusiveListNode N::*member>
-typename QIntrusiveList<N, member>::iterator &QIntrusiveList<N, member>::iterator::erase()
-{
- N *old = _value;
- _value = QIntrusiveList<N, member>::next(_value);
- (old->*member).remove();
+typename QIntrusiveList<N, member>::iterator &QIntrusiveList<N, member>::iterator::erase()
+{
+ N *old = _value;
+ _value = QIntrusiveList<N, member>::next(_value);
+ (old->*member).remove();
return *this;
}
-
+
template<class N, QIntrusiveListNode N::*member>
-QIntrusiveList<N, member>::QIntrusiveList()
-: __first(0)
+QIntrusiveList<N, member>::QIntrusiveList()
+: __first(0)
{
}
@@ -184,7 +184,7 @@ bool QIntrusiveList<N, member>::isEmpty() const
}
template<class N, QIntrusiveListNode N::*member>
-void QIntrusiveList<N, member>::insert(N *n)
+void QIntrusiveList<N, member>::insert(N *n)
{
QIntrusiveListNode *nnode = &(n->*member);
nnode->remove();
@@ -215,13 +215,13 @@ bool QIntrusiveList<N, member>::contains(N *n) const
}
template<class N, QIntrusiveListNode N::*member>
-N *QIntrusiveList<N, member>::first() const
-{
- return __first?nodeToN(__first):0;
+N *QIntrusiveList<N, member>::first() const
+{
+ return __first?nodeToN(__first):0;
}
template<class N, QIntrusiveListNode N::*member>
-N *QIntrusiveList<N, member>::next(N *current)
+N *QIntrusiveList<N, member>::next(N *current)
{
QIntrusiveListNode *nextnode = (current->*member)._next;
N *nextstruct = nextnode?nodeToN(nextnode):0;
@@ -229,19 +229,19 @@ N *QIntrusiveList<N, member>::next(N *current)
}
template<class N, QIntrusiveListNode N::*member>
-typename QIntrusiveList<N, member>::iterator QIntrusiveList<N, member>::begin()
-{
- return __first?iterator(nodeToN(__first)):iterator();
+typename QIntrusiveList<N, member>::iterator QIntrusiveList<N, member>::begin()
+{
+ return __first?iterator(nodeToN(__first)):iterator();
}
template<class N, QIntrusiveListNode N::*member>
-typename QIntrusiveList<N, member>::iterator QIntrusiveList<N, member>::end()
-{
- return iterator();
+typename QIntrusiveList<N, member>::iterator QIntrusiveList<N, member>::end()
+{
+ return iterator();
}
template<class N, QIntrusiveListNode N::*member>
-N *QIntrusiveList<N, member>::nodeToN(QIntrusiveListNode *node)
+N *QIntrusiveList<N, member>::nodeToN(QIntrusiveListNode *node)
{
return (N *)((char *)node - ((char *)&(((N *)0)->*member) - (char *)0));
}
diff --git a/src/qml/qml/ftw/qqmlpool_p.h b/src/qml/qml/ftw/qqmlpool_p.h
index 408ac74771..7a04291cd4 100644
--- a/src/qml/qml/ftw/qqmlpool_p.h
+++ b/src/qml/qml/ftw/qqmlpool_p.h
@@ -63,7 +63,7 @@ class Q_QML_PRIVATE_EXPORT QQmlPool
{
public:
// The class has a destructor that needs to be called
- class Class {
+ class Class {
public:
inline QQmlPool *pool() const;
@@ -82,7 +82,7 @@ public:
class POD {
public:
inline QQmlPool *pool() const;
-
+
private:
void *operator new(size_t);
void *operator new(size_t, void *m) { return m; }
@@ -120,16 +120,16 @@ public:
int count() const {
return m_length;
}
- int length() const {
- return m_length;
+ int length() const {
+ return m_length;
}
- const T &at(int index) const {
- Q_ASSERT(index < m_length);
- return m_data[index];
+ const T &at(int index) const {
+ Q_ASSERT(index < m_length);
+ return m_data[index];
};
T &operator[](int index) {
- Q_ASSERT(index < m_length);
- return m_data[index];
+ Q_ASSERT(index < m_length);
+ return m_data[index];
};
const T *data() const { return m_data; }
private:
diff --git a/src/qml/qml/ftw/qqmlrefcount_p.h b/src/qml/qml/ftw/qqmlrefcount_p.h
index 24c3e7a2cc..de32f0e915 100644
--- a/src/qml/qml/ftw/qqmlrefcount_p.h
+++ b/src/qml/qml/ftw/qqmlrefcount_p.h
@@ -86,7 +86,7 @@ public:
inline QQmlRefPointer<T> &operator=(const QQmlRefPointer<T> &o);
inline QQmlRefPointer<T> &operator=(T *);
-
+
inline bool isNull() const { return !o; }
inline T* operator->() const { return o; }
@@ -100,27 +100,27 @@ private:
T *o;
};
-QQmlRefCount::QQmlRefCount()
-: refCount(1)
+QQmlRefCount::QQmlRefCount()
+: refCount(1)
{
}
-QQmlRefCount::~QQmlRefCount()
+QQmlRefCount::~QQmlRefCount()
{
Q_ASSERT(refCount.load() == 0);
}
-void QQmlRefCount::addref()
-{
+void QQmlRefCount::addref()
+{
Q_ASSERT(refCount.load() > 0);
- refCount.ref();
+ refCount.ref();
}
-void QQmlRefCount::release()
-{
+void QQmlRefCount::release()
+{
Q_ASSERT(refCount.load() > 0);
- if (!refCount.deref())
- destroy();
+ if (!refCount.deref())
+ destroy();
}
int QQmlRefCount::count() const
@@ -128,20 +128,20 @@ int QQmlRefCount::count() const
return refCount.load();
}
-void QQmlRefCount::destroy()
-{
- delete this;
+void QQmlRefCount::destroy()
+{
+ delete this;
}
template<class T>
QQmlRefPointer<T>::QQmlRefPointer()
-: o(0)
+: o(0)
{
}
template<class T>
QQmlRefPointer<T>::QQmlRefPointer(T *o)
-: o(o)
+: o(o)
{
if (o) o->addref();
}
diff --git a/src/qml/qml/ftw/qqmlthread.cpp b/src/qml/qml/ftw/qqmlthread.cpp
index 1ea3f25405..c49463c913 100644
--- a/src/qml/qml/ftw/qqmlthread.cpp
+++ b/src/qml/qml/ftw/qqmlthread.cpp
@@ -83,10 +83,10 @@ public:
void threadEvent();
protected:
- virtual bool event(QEvent *);
+ virtual bool event(QEvent *);
private:
- struct MainObject : public QObject {
+ struct MainObject : public QObject {
MainObject(QQmlThreadPrivate *p);
virtual bool event(QEvent *e);
QQmlThreadPrivate *p;
@@ -97,8 +97,8 @@ private:
QWaitCondition _wait;
};
-QQmlThreadPrivate::MainObject::MainObject(QQmlThreadPrivate *p)
-: p(p)
+QQmlThreadPrivate::MainObject::MainObject(QQmlThreadPrivate *p)
+: p(p)
{
}
@@ -116,22 +116,22 @@ void QQmlThreadPrivate::triggerThreadEvent()
QCoreApplication::postEvent(this, new QEvent(QEvent::User));
}
-bool QQmlThreadPrivate::MainObject::event(QEvent *e)
+bool QQmlThreadPrivate::MainObject::event(QEvent *e)
{
- if (e->type() == QEvent::User)
+ if (e->type() == QEvent::User)
p->mainEvent();
return QObject::event(e);
}
-
+
QQmlThreadPrivate::QQmlThreadPrivate(QQmlThread *q)
-: q(q), m_threadProcessing(false), m_mainProcessing(false), m_shutdown(false),
+: q(q), m_threadProcessing(false), m_mainProcessing(false), m_shutdown(false),
m_mainThreadWaiting(false), mainSync(0), m_mainObject(this)
{
}
bool QQmlThreadPrivate::event(QEvent *e)
{
- if (e->type() == QEvent::User)
+ if (e->type() == QEvent::User)
threadEvent();
return QThread::event(e);
}
@@ -175,7 +175,7 @@ void QQmlThreadPrivate::mainEvent()
unlock();
}
-void QQmlThreadPrivate::threadEvent()
+void QQmlThreadPrivate::threadEvent()
{
lock();
diff --git a/src/qml/qml/ftw/qqmlthread_p.h b/src/qml/qml/ftw/qqmlthread_p.h
index 688fce6d5a..ee5996d9ef 100644
--- a/src/qml/qml/ftw/qqmlthread_p.h
+++ b/src/qml/qml/ftw/qqmlthread_p.h
@@ -63,7 +63,7 @@ QT_BEGIN_NAMESPACE
class QThread;
class QQmlThreadPrivate;
-class QQmlThread
+class QQmlThread
{
public:
QQmlThread();
diff --git a/src/qml/qml/ftw/qrecursionwatcher_p.h b/src/qml/qml/ftw/qrecursionwatcher_p.h
index c6b3db38d4..8a8d6575da 100644
--- a/src/qml/qml/ftw/qrecursionwatcher_p.h
+++ b/src/qml/qml/ftw/qrecursionwatcher_p.h
@@ -76,7 +76,7 @@ private:
};
QRecursionNode::QRecursionNode()
-: _r(0)
+: _r(0)
{
}
diff --git a/src/qml/qml/qqml.h b/src/qml/qml/qqml.h
index 641209d1f3..633953c81c 100644
--- a/src/qml/qml/qqml.h
+++ b/src/qml/qml/qqml.h
@@ -55,10 +55,10 @@
#define QML_DECLARE_TYPE(TYPE) \
Q_DECLARE_METATYPE(TYPE *) \
- Q_DECLARE_METATYPE(QQmlListProperty<TYPE>)
+ Q_DECLARE_METATYPE(QQmlListProperty<TYPE>)
#define QML_DECLARE_TYPE_HASMETATYPE(TYPE) \
- Q_DECLARE_METATYPE(QQmlListProperty<TYPE>)
+ Q_DECLARE_METATYPE(QQmlListProperty<TYPE>)
#define QML_DECLARE_INTERFACE(INTERFACE) \
QML_DECLARE_TYPE(INTERFACE)
@@ -109,7 +109,7 @@ int qmlRegisterType()
QML_GETTYPENAMES
QQmlPrivate::RegisterType type = {
- 0,
+ 0,
qRegisterNormalizedMetaType<T *>(pointerName.constData()),
qRegisterNormalizedMetaType<QQmlListProperty<T> >(listName.constData()),
@@ -121,7 +121,7 @@ int qmlRegisterType()
QQmlPrivate::attachedPropertiesFunc<T>(),
QQmlPrivate::attachedPropertiesMetaObject<T>(),
- QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
+ QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueSource>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueInterceptor>::cast(),
@@ -204,7 +204,7 @@ int qmlRegisterType(const char *uri, int versionMajor, int versionMinor, const c
QML_GETTYPENAMES
QQmlPrivate::RegisterType type = {
- 0,
+ 0,
qRegisterNormalizedMetaType<T *>(pointerName.constData()),
qRegisterNormalizedMetaType<QQmlListProperty<T> >(listName.constData()),
@@ -216,7 +216,7 @@ int qmlRegisterType(const char *uri, int versionMajor, int versionMinor, const c
QQmlPrivate::attachedPropertiesFunc<T>(),
QQmlPrivate::attachedPropertiesMetaObject<T>(),
- QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
+ QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueSource>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueInterceptor>::cast(),
@@ -298,7 +298,7 @@ int qmlRegisterExtendedType()
QML_GETTYPENAMES
QQmlPrivate::RegisterType type = {
- 0,
+ 0,
qRegisterNormalizedMetaType<T *>(pointerName.constData()),
qRegisterNormalizedMetaType<QQmlListProperty<T> >(listName.constData()),
@@ -310,7 +310,7 @@ int qmlRegisterExtendedType()
QQmlPrivate::attachedPropertiesFunc<T>(),
QQmlPrivate::attachedPropertiesMetaObject<T>(),
- QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
+ QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueSource>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueInterceptor>::cast(),
@@ -324,20 +324,20 @@ 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)
{
QML_GETTYPENAMES
QQmlAttachedPropertiesFunc attached = QQmlPrivate::attachedPropertiesFunc<E>();
- const QMetaObject * attachedMetaObject = QQmlPrivate::attachedPropertiesMetaObject<E>();
+ const QMetaObject * attachedMetaObject = QQmlPrivate::attachedPropertiesMetaObject<E>();
if (!attached) {
attached = QQmlPrivate::attachedPropertiesFunc<T>();
attachedMetaObject = QQmlPrivate::attachedPropertiesMetaObject<T>();
}
QQmlPrivate::RegisterType type = {
- 0,
+ 0,
qRegisterNormalizedMetaType<T *>(pointerName.constData()),
qRegisterNormalizedMetaType<QQmlListProperty<T> >(listName.constData()),
@@ -349,7 +349,7 @@ int qmlRegisterExtendedType(const char *uri, int versionMajor, int versionMinor,
attached,
attachedMetaObject,
- QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
+ QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueSource>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueInterceptor>::cast(),
@@ -383,13 +383,13 @@ 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, QQmlCustomParser *parser)
{
QML_GETTYPENAMES
QQmlPrivate::RegisterType type = {
- 0,
+ 0,
qRegisterNormalizedMetaType<T *>(pointerName.constData()),
qRegisterNormalizedMetaType<QQmlListProperty<T> >(listName.constData()),
@@ -401,7 +401,7 @@ int qmlRegisterCustomType(const char *uri, int versionMajor, int versionMinor,
QQmlPrivate::attachedPropertiesFunc<T>(),
QQmlPrivate::attachedPropertiesMetaObject<T>(),
- QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
+ QQmlPrivate::StaticCastSelector<T,QQmlParserStatus>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueSource>::cast(),
QQmlPrivate::StaticCastSelector<T,QQmlPropertyValueInterceptor>::cast(),
@@ -506,7 +506,7 @@ inline int qmlRegisterSingletonType(const QUrl &url, const char *uri, int versio
inline int qmlRegisterType(const QUrl &url, const char *uri, int versionMajor, int versionMinor, const char *qmlName)
{
- if (url.isRelative()) {
+ if (url.isRelative()) {
// User input check must go here, because QQmlPrivate::qmlregister is also used internally for composite types
qWarning("qmlRegisterType requires absolute URLs.");
return 0;
diff --git a/src/qml/qml/qqmlcleanup.cpp b/src/qml/qml/qqmlcleanup.cpp
index 36f633c29f..94762d4fc7 100644
--- a/src/qml/qml/qqmlcleanup.cpp
+++ b/src/qml/qml/qqmlcleanup.cpp
@@ -48,7 +48,7 @@ QT_BEGIN_NAMESPACE
/*!
\internal
\class QQmlCleanup
-\brief The QQmlCleanup provides a callback when a QQmlEngine is deleted.
+\brief The QQmlCleanup provides a callback when a QQmlEngine is deleted.
Any object that needs cleanup to occur before the QQmlEngine's V8 engine is
destroyed should inherit from QQmlCleanup. The clear() virtual method will be
@@ -111,7 +111,7 @@ QQmlCleanup::~QQmlCleanup()
if (prev) *prev = next;
if (next) next->prev = prev;
- prev = 0;
+ prev = 0;
next = 0;
}
diff --git a/src/qml/qml/qqmlcleanup_p.h b/src/qml/qml/qqmlcleanup_p.h
index 249ef97cc3..1f210ea7ce 100644
--- a/src/qml/qml/qqmlcleanup_p.h
+++ b/src/qml/qml/qqmlcleanup_p.h
@@ -44,7 +44,7 @@
#include <private/qtqmlglobal_p.h>
-//
+//
// W A R N I N G
// -------------
//
diff --git a/src/qml/qml/qqmlcompileddata.cpp b/src/qml/qml/qqmlcompileddata.cpp
index cc8fcdb6ba..05ec0ab9c7 100644
--- a/src/qml/qml/qqmlcompileddata.cpp
+++ b/src/qml/qml/qqmlcompileddata.cpp
@@ -127,7 +127,7 @@ QQmlCompiledData::~QQmlCompiledData()
qDeleteAll(resolvedTypes);
resolvedTypes.clear();
- for (int ii = 0; ii < propertyCaches.count(); ++ii)
+ for (int ii = 0; ii < propertyCaches.count(); ++ii)
if (propertyCaches.at(ii))
propertyCaches.at(ii)->release();
@@ -163,7 +163,7 @@ QQmlPropertyCache *QQmlCompiledData::TypeReference::propertyCache() const
/*!
Returns the property cache, creating one if it doesn't already exist. The cache is not referenced.
*/
-QQmlPropertyCache *QQmlCompiledData::TypeReference::createPropertyCache(QQmlEngine *engine)
+QQmlPropertyCache *QQmlCompiledData::TypeReference::createPropertyCache(QQmlEngine *engine)
{
if (typePropertyCache) {
return typePropertyCache;
@@ -234,13 +234,13 @@ int QQmlCompiledData::addInstructionHelper(QQmlInstruction::Type type, QQmlInstr
return ptrOffset;
}
-int QQmlCompiledData::nextInstructionIndex()
-{
+int QQmlCompiledData::nextInstructionIndex()
+{
return bytecode.size();
}
-QQmlInstruction *QQmlCompiledData::instruction(int index)
-{
+QQmlInstruction *QQmlCompiledData::instruction(int index)
+{
return (QQmlInstruction *)(bytecode.constData() + index);
}
diff --git a/src/qml/qml/qqmlcompiler.cpp b/src/qml/qml/qqmlcompiler.cpp
index a0c1bbcdda..cd0dea975b 100644
--- a/src/qml/qml/qqmlcompiler.cpp
+++ b/src/qml/qml/qqmlcompiler.cpp
@@ -102,7 +102,7 @@ QQmlCompiler::QQmlCompiler(QQmlPool *pool)
: compileState(0), pool(pool), output(0), engine(0), enginePrivate(0), unitRoot(0), unit(0), cachedComponentTypeRef(-1),
cachedTranslationContextIndex(-1), componentStats(0)
{
- if (compilerStatDump())
+ if (compilerStatDump())
componentStats = pool->New<ComponentStats>();
}
@@ -1007,13 +1007,13 @@ bool QQmlCompiler::buildObject(QQmlScript::Object *obj, const BindingContext &ct
if (tr.type && obj->metatype->metaObject() == &QQmlComponent::staticMetaObject) {
COMPILE_CHECK(buildComponent(obj, ctxt));
return true;
- }
+ }
if (tr.component) {
- typedef QQmlInstruction I;
+ typedef QQmlInstruction I;
const I *init = ((const I *)tr.component->bytecode.constData());
Q_ASSERT(init && tr.component->instructionType(init) == QQmlInstruction::Init);
-
+
// Adjust stack depths to include nested components
compileState->objectDepth.pushPop(init->init.objectStackSize);
compileState->listDepth.pushPop(init->init.listStackSize);
@@ -1027,7 +1027,7 @@ bool QQmlCompiler::buildObject(QQmlScript::Object *obj, const BindingContext &ct
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, Normal));
@@ -1058,7 +1058,7 @@ bool QQmlCompiler::buildObject(QQmlScript::Object *obj, const BindingContext &ct
}
}
- // Merge
+ // Merge
Property *defaultProperty = 0;
Property *skipProperty = 0;
if (obj->defaultProperty) {
@@ -1098,7 +1098,7 @@ bool QQmlCompiler::buildObject(QQmlScript::Object *obj, const BindingContext &ct
}
defaultProperty->values.insertAfter(insertPos, explicitProperty->values);
- }
+ }
}
QQmlCustomParser *cp = 0;
@@ -1316,9 +1316,9 @@ void QQmlCompiler::genObjectBody(QQmlScript::Object *obj)
Instruction::DeferInit dinit;
// XXX - these are now massive over allocations
dinit.bindingsSize = compileState->totalBindingsCount;
- dinit.parserStatusSize = compileState->parserStatusCount;
- dinit.objectStackSize = compileState->objectDepth.maxDepth();
- dinit.listStackSize = compileState->listDepth.maxDepth();
+ dinit.parserStatusSize = compileState->parserStatusCount;
+ dinit.objectStackSize = compileState->objectDepth.maxDepth();
+ dinit.listStackSize = compileState->listDepth.maxDepth();
output->addInstruction(dinit);
for (Property *prop = obj->valueProperties.first(); prop; prop = Object::PropertyList::next(prop)) {
@@ -1404,7 +1404,7 @@ void QQmlCompiler::genObjectBody(QQmlScript::Object *obj)
}
for (Property *prop = obj->valueProperties.first(); prop; prop = Object::PropertyList::next(prop)) {
- if (prop->isDeferred)
+ if (prop->isDeferred)
continue;
if (prop->isAlias)
genValueProperty(prop, obj);
@@ -1485,7 +1485,7 @@ void QQmlCompiler::genComponent(QQmlScript::Object *obj)
Instruction::Done done;
output->addInstruction(done);
- output->instruction(createInstruction)->createComponent.count =
+ output->instruction(createInstruction)->createComponent.count =
output->nextInstructionIndex() - nextInstructionIndex;
compileState = oldCompileState;
@@ -1516,12 +1516,12 @@ bool QQmlCompiler::buildComponent(QQmlScript::Object *obj,
if (obj->properties.isMany() ||
(obj->properties.isOne() && obj->properties.first()->name() != id_string))
COMPILE_EXCEPTION(obj->properties.first(), tr("Component elements may not contain properties other than id"));
-
+
if (!obj->properties.isEmpty())
idProp = obj->properties.first();
if (idProp) {
- if (idProp->value || idProp->values.isMany() || idProp->values.first()->object)
+ if (idProp->value || idProp->values.isMany() || idProp->values.first()->object)
COMPILE_EXCEPTION(idProp, tr("Invalid component id specification"));
COMPILE_CHECK(checkValidId(idProp->values.first(), idProp->values.first()->primitive()))
@@ -1790,7 +1790,7 @@ bool QQmlCompiler::buildProperty(QQmlScript::Property *prop,
QQmlScript::Object *obj,
const BindingContext &ctxt)
{
- if (prop->isEmpty())
+ if (prop->isEmpty())
COMPILE_EXCEPTION(prop, tr("Empty property assignment"));
if (isAttachedPropertyName(prop->name())) {
@@ -1808,7 +1808,7 @@ bool QQmlCompiler::buildProperty(QQmlScript::Property *prop,
unit->imports().resolveType(prop->name(), &type, 0, 0, &typeNamespace);
if (typeNamespace) {
- COMPILE_CHECK(buildPropertyInNamespace(typeNamespace, prop, obj,
+ COMPILE_CHECK(buildPropertyInNamespace(typeNamespace, prop, obj,
ctxt));
return true;
} else if (!type || !type->attachedPropertiesType()) {
@@ -1852,13 +1852,13 @@ bool QQmlCompiler::buildProperty(QQmlScript::Property *prop,
// We can't error here as the "id" property does not require a
// successful index resolution
- if (prop->index != -1)
+ if (prop->index != -1)
prop->type = prop->core.propType;
// 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) {
QQmlPropertyCache *cache = output->types.at(prop->parent->type).component->rootPropertyCache;
@@ -1866,7 +1866,7 @@ bool QQmlCompiler::buildProperty(QQmlScript::Property *prop,
prop->isAlias = true;
}
- if (prop->index != -1 && !prop->values.isEmpty())
+ if (prop->index != -1 && !prop->values.isEmpty())
prop->parent->setBindingBit(prop->index);
}
@@ -1931,7 +1931,7 @@ bool QQmlCompiler::buildPropertyInNamespace(QQmlImportNamespace *ns,
QQmlType *type = 0;
unit->imports().resolveType(ns, prop->name(), &type, 0, 0);
- if (!type || !type->attachedPropertiesType())
+ if (!type || !type->attachedPropertiesType())
COMPILE_EXCEPTION(prop, tr("Non-existent attached object"));
if (!prop->value)
@@ -2131,7 +2131,7 @@ void QQmlCompiler::saveComponentState()
compileState->root->componentCompileState = compileState;
- if (componentStats)
+ if (componentStats)
componentStats->savedComponentStats.append(componentStats->componentStat);
}
@@ -2234,7 +2234,7 @@ bool QQmlCompiler::buildGroupedProperty(QQmlScript::Property *prop,
if (!prop->value->metatype)
COMPILE_EXCEPTION(prop, tr("Invalid grouped property access"));
- if (!prop->values.isEmpty())
+ if (!prop->values.isEmpty())
COMPILE_EXCEPTION(prop->values.first(), tr( "Cannot assign a value directly to a grouped property"));
obj->addGroupedProperty(prop);
@@ -2263,7 +2263,7 @@ bool QQmlCompiler::buildValueTypeProperty(QObject *type,
for (Property *prop = obj->properties.first(); prop; prop = obj->properties.next(prop)) {
QQmlPropertyData *d = property(obj, prop->name());
- if (d == 0)
+ if (d == 0)
COMPILE_EXCEPTION(prop, tr("Cannot assign to non-existent property \"%1\"").arg(prop->name().toString()));
prop->index = d->coreIndex;
@@ -2311,7 +2311,7 @@ bool QQmlCompiler::buildValueTypeProperty(QObject *type,
for (Value *v = prop->onValues.first(); v; v = Property::ValueList::next(v)) {
Q_ASSERT(v->object);
- COMPILE_CHECK(buildPropertyOnAssignment(prop, obj, baseObj, v, ctxt));
+ COMPILE_CHECK(buildPropertyOnAssignment(prop, obj, baseObj, v, ctxt));
}
obj->addValueProperty(prop);
@@ -2323,7 +2323,7 @@ bool QQmlCompiler::buildValueTypeProperty(QObject *type,
}
// Build assignments to QML lists. QML lists are properties of type
-// QQmlListProperty<T>. List properties can accept a list of
+// QQmlListProperty<T>. List properties can accept a list of
// objects, or a single binding.
bool QQmlCompiler::buildListProperty(QQmlScript::Property *prop,
QQmlScript::Object *obj,
@@ -2720,7 +2720,7 @@ bool QQmlCompiler::checkDynamicMeta(QQmlScript::Object *obj)
}
if (propNames.testAndSet(prop.name.hash())) {
- for (Object::DynamicProperty *p2 = obj->dynamicProperties.first(); p2 != p;
+ for (Object::DynamicProperty *p2 = obj->dynamicProperties.first(); p2 != p;
p2 = obj->dynamicProperties.next(p2)) {
if (p2->name == prop.name) {
COMPILE_EXCEPTION_LOCATION(prop.nameLocation.line,
@@ -2798,7 +2798,7 @@ bool QQmlCompiler::mergeDynamicMetaProperties(QQmlScript::Object *obj)
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"));
}
@@ -3620,7 +3620,7 @@ int QQmlCompiler::genContextCache()
}
QQmlPropertyData
-QQmlCompiler::genValueTypeData(QQmlScript::Property *valueTypeProp,
+QQmlCompiler::genValueTypeData(QQmlScript::Property *valueTypeProp,
QQmlScript::Property *prop)
{
QQmlValueType *vt = QQmlValueTypeFactory::valueType(prop->type);
@@ -3633,8 +3633,8 @@ bool QQmlCompiler::completeComponentBuild()
if (componentStats)
componentStats->componentStat.ids = compileState->ids.count();
- for (Object *aliasObject = compileState->aliasingObjects.first(); aliasObject;
- aliasObject = compileState->aliasingObjects.next(aliasObject))
+ for (Object *aliasObject = compileState->aliasingObjects.first(); aliasObject;
+ aliasObject = compileState->aliasingObjects.next(aliasObject))
COMPILE_CHECK(buildDynamicMetaAliases(aliasObject));
const QQmlScript::Parser &parser = unit->parser();
@@ -3884,7 +3884,7 @@ QQmlCompiler::signal(QQmlScript::Object *object, const QHashedStringRef &name, b
QHashedStringRef propName = name.mid(0, name.length() - Changed_string.length());
d = property(object, propName, notInRevision);
- if (d)
+ if (d)
return cache->signal(d->notifyIndex);
}
@@ -3892,20 +3892,20 @@ QQmlCompiler::signal(QQmlScript::Object *object, const QHashedStringRef &name, b
}
// This code must match the semantics of QQmlPropertyPrivate::findSignalByName
-int QQmlCompiler::indexOfSignal(QQmlScript::Object *object, const QString &name,
+int QQmlCompiler::indexOfSignal(QQmlScript::Object *object, const QString &name,
bool *notInRevision)
{
QQmlPropertyData *d = signal(object, QStringRef(&name), notInRevision);
return d?d->coreIndex:-1;
}
-int QQmlCompiler::indexOfProperty(QQmlScript::Object *object, const QString &name,
+int QQmlCompiler::indexOfProperty(QQmlScript::Object *object, const QString &name,
bool *notInRevision)
{
return indexOfProperty(object, QStringRef(&name), notInRevision);
}
-int QQmlCompiler::indexOfProperty(QQmlScript::Object *object, const QHashedStringRef &name,
+int QQmlCompiler::indexOfProperty(QQmlScript::Object *object, const QHashedStringRef &name,
bool *notInRevision)
{
QQmlPropertyData *d = property(object, name, notInRevision);
diff --git a/src/qml/qml/qqmlcompiler_p.h b/src/qml/qml/qqmlcompiler_p.h
index 0feebed93d..c63f430b0a 100644
--- a/src/qml/qml/qqmlcompiler_p.h
+++ b/src/qml/qml/qqmlcompiler_p.h
@@ -101,7 +101,7 @@ public:
int listMetaTypeId;
bool isRegisteredWithEngine;
- struct TypeReference
+ struct TypeReference
{
TypeReference()
: type(0), typePropertyCache(0), component(0)
@@ -208,7 +208,7 @@ private:
};
namespace QQmlCompilerTypes {
- struct BindingContext
+ struct BindingContext
{
BindingContext()
: stack(0), owner(0), object(0) {}
@@ -258,7 +258,7 @@ namespace QQmlCompilerTypes {
int n;
};
- struct IdList : public QFieldList<QQmlScript::Object,
+ struct IdList : public QFieldList<QQmlScript::Object,
&QQmlScript::Object::nextIdObject>
{
QQmlScript::Object *value(const QString &id) const {
@@ -292,8 +292,8 @@ namespace QQmlCompilerTypes {
// more than one of these for each compile
struct ComponentCompileState : public QQmlPool::Class
{
- ComponentCompileState()
- : parserStatusCount(0), totalBindingsCount(0), pushedProperties(0), nested(false),
+ ComponentCompileState()
+ : parserStatusCount(0), totalBindingsCount(0), pushedProperties(0), nested(false),
root(0) {}
IdList ids;
@@ -364,23 +364,23 @@ private:
bool buildObject(QQmlScript::Object *obj, const QQmlCompilerTypes::BindingContext &);
bool buildComponent(QQmlScript::Object *obj, const QQmlCompilerTypes::BindingContext &);
bool buildSubObject(QQmlScript::Object *obj, const QQmlCompilerTypes::BindingContext &);
- bool buildSignal(QQmlScript::Property *prop, QQmlScript::Object *obj,
+ bool buildSignal(QQmlScript::Property *prop, QQmlScript::Object *obj,
const QQmlCompilerTypes::BindingContext &);
- bool buildProperty(QQmlScript::Property *prop, QQmlScript::Object *obj,
+ bool buildProperty(QQmlScript::Property *prop, QQmlScript::Object *obj,
const QQmlCompilerTypes::BindingContext &);
bool buildPropertyInNamespace(QQmlImportNamespace *ns,
- QQmlScript::Property *prop,
- QQmlScript::Object *obj,
+ QQmlScript::Property *prop,
+ QQmlScript::Object *obj,
const QQmlCompilerTypes::BindingContext &);
bool buildIdProperty(QQmlScript::Property *prop, QQmlScript::Object *obj);
- bool buildAttachedProperty(QQmlScript::Property *prop,
+ bool buildAttachedProperty(QQmlScript::Property *prop,
QQmlScript::Object *obj,
const QQmlCompilerTypes::BindingContext &ctxt);
bool buildGroupedProperty(QQmlScript::Property *prop,
QQmlScript::Object *obj,
const QQmlCompilerTypes::BindingContext &ctxt);
- bool buildValueTypeProperty(QObject *type,
- QQmlScript::Object *obj,
+ bool buildValueTypeProperty(QObject *type,
+ QQmlScript::Object *obj,
QQmlScript::Object *baseObj,
const QQmlCompilerTypes::BindingContext &ctxt);
bool buildListProperty(QQmlScript::Property *prop,
@@ -432,13 +432,13 @@ private:
void genComponent(QQmlScript::Object *obj);
void genValueProperty(QQmlScript::Property *prop, QQmlScript::Object *obj);
void genListProperty(QQmlScript::Property *prop, QQmlScript::Object *obj);
- void genPropertyAssignment(QQmlScript::Property *prop,
+ void genPropertyAssignment(QQmlScript::Property *prop,
QQmlScript::Object *obj,
QQmlScript::Property *valueTypeProperty = 0);
void genLiteralAssignment(QQmlScript::Property *prop,
QQmlScript::Value *value);
- void genBindingAssignment(QQmlScript::Value *binding,
- QQmlScript::Property *prop,
+ void genBindingAssignment(QQmlScript::Value *binding,
+ QQmlScript::Property *prop,
QQmlScript::Object *obj,
QQmlScript::Property *valueTypeProperty = 0);
int genContextCache();
diff --git a/src/qml/qml/qqmlcomponent_p.h b/src/qml/qml/qqmlcomponent_p.h
index 8bf4005dd6..7e855fdfd0 100644
--- a/src/qml/qml/qqmlcomponent_p.h
+++ b/src/qml/qml/qqmlcomponent_p.h
@@ -81,7 +81,7 @@ class QQmlComponentAttached;
class Q_QML_PRIVATE_EXPORT QQmlComponentPrivate : public QObjectPrivate, public QQmlTypeData::TypeDataCallback
{
Q_DECLARE_PUBLIC(QQmlComponent)
-
+
public:
QQmlComponentPrivate()
: typeData(0), progress(0.), start(-1), cc(0), engine(0), creationContext(0), depthIncreased(false) {}
@@ -95,7 +95,7 @@ public:
QQmlTypeData *typeData;
virtual void typeDataReady(QQmlTypeData *);
virtual void typeDataProgress(QQmlTypeData *, qreal);
-
+
void fromTypeData(QQmlTypeData *data);
QUrl url;
@@ -124,7 +124,7 @@ public:
};
ConstructionState state;
- static void beginDeferred(QQmlEnginePrivate *enginePriv, QObject *object,
+ static void beginDeferred(QQmlEnginePrivate *enginePriv, QObject *object,
ConstructionState *state);
static void complete(QQmlEnginePrivate *enginePriv, ConstructionState *state);
diff --git a/src/qml/qml/qqmlcontext.cpp b/src/qml/qml/qqmlcontext.cpp
index 78e6650d02..7b1ba46db2 100644
--- a/src/qml/qml/qqmlcontext.cpp
+++ b/src/qml/qml/qqmlcontext.cpp
@@ -403,7 +403,7 @@ QVariant QQmlContext::contextProperty(const QString &name) const
}
/*!
-Returns the name of \a object in this context, or an empty string if \a object
+Returns the name of \a object in this context, or an empty string if \a object
is not named in the context. Objects are named by setContextProperty(), or by ids in
the case of QML created contexts.
@@ -521,7 +521,7 @@ QObject *QQmlContextPrivate::context_at(QQmlListProperty<QObject> *prop, int ind
QQmlContextData::QQmlContextData()
-: parent(0), engine(0), isInternal(false), ownedByParent(false), isJSContext(false),
+: parent(0), engine(0), isInternal(false), ownedByParent(false), isJSContext(false),
isPragmaLibraryContext(false), unresolvedNames(false), hasEmittedDestruction(false), isRootObjectInCreation(false),
publicContext(0), activeVMEData(0),
contextObject(0), imports(0), childContexts(0), nextChild(0), prevChild(0),
@@ -531,7 +531,7 @@ QQmlContextData::QQmlContextData()
}
QQmlContextData::QQmlContextData(QQmlContext *ctxt)
-: parent(0), engine(0), isInternal(false), ownedByParent(false), isJSContext(false),
+: parent(0), engine(0), isInternal(false), ownedByParent(false), isJSContext(false),
isPragmaLibraryContext(false), unresolvedNames(false), hasEmittedDestruction(false), isRootObjectInCreation(false),
publicContext(ctxt), activeVMEData(0),
contextObject(0), imports(0), childContexts(0), nextChild(0), prevChild(0),
diff --git a/src/qml/qml/qqmlcontext_p.h b/src/qml/qml/qqmlcontext_p.h
index 26048b0217..464bee82c0 100644
--- a/src/qml/qml/qqmlcontext_p.h
+++ b/src/qml/qml/qqmlcontext_p.h
@@ -134,7 +134,7 @@ public:
QUrl resolvedUrl(const QUrl &);
- // My containing QQmlContext. If isInternal is true this owns publicContext.
+ // My containing QQmlContext. If isInternal is true this owns publicContext.
// If internal is false publicContext owns this.
QQmlContext *asQQmlContext();
QQmlContextPrivate *asQQmlContextPrivate();
diff --git a/src/qml/qml/qqmlcustomparser.cpp b/src/qml/qml/qqmlcustomparser.cpp
index 90bd2fd875..004d9f435a 100644
--- a/src/qml/qml/qqmlcustomparser.cpp
+++ b/src/qml/qml/qqmlcustomparser.cpp
@@ -93,7 +93,7 @@ using namespace QQmlScript;
The \a object will be an instance of the TypeClass specified by QML_REGISTER_CUSTOM_TYPE.
*/
-QQmlCustomParserNode
+QQmlCustomParserNode
QQmlCustomParserNodePrivate::fromObject(QQmlScript::Object *root)
{
QQmlCustomParserNode rootNode;
@@ -111,7 +111,7 @@ QQmlCustomParserNodePrivate::fromObject(QQmlScript::Object *root)
return rootNode;
}
-QQmlCustomParserProperty
+QQmlCustomParserProperty
QQmlCustomParserNodePrivate::fromProperty(QQmlScript::Property *p)
{
QQmlCustomParserProperty prop;
diff --git a/src/qml/qml/qqmlcustomparser_p.h b/src/qml/qml/qqmlcustomparser_p.h
index b4d716b240..b406717410 100644
--- a/src/qml/qml/qqmlcustomparser_p.h
+++ b/src/qml/qml/qqmlcustomparser_p.h
@@ -79,7 +79,7 @@ public:
QQmlScript::Location location() const;
bool isList() const;
- // Will be one of QQmlScript::Variant, QQmlCustomParserProperty or
+ // Will be one of QQmlScript::Variant, QQmlCustomParserProperty or
// QQmlCustomParserNode
QList<QVariant> assignedValues() const;
diff --git a/src/qml/qml/qqmldata_p.h b/src/qml/qml/qqmldata_p.h
index 982156ea15..c4b19394f0 100644
--- a/src/qml/qml/qqmldata_p.h
+++ b/src/qml/qml/qqmldata_p.h
@@ -143,7 +143,7 @@ public:
void layout(QQmlNotifierEndpoint*);
};
NotifyList *notifyList;
-
+
inline QQmlNotifierEndpoint *notify(int index);
void addNotify(int index, QQmlNotifierEndpoint *);
int endpointCount(int index);
@@ -151,7 +151,7 @@ public:
void disconnectNotifiers();
// The context that created the C++ object
- QQmlContextData *context;
+ QQmlContextData *context;
// The outermost context in which this object lives
QQmlContextData *outerContext;
@@ -163,7 +163,7 @@ public:
QQmlData**prevContextObject;
int bindingBitsSize;
- quint32 *bindingBits;
+ quint32 *bindingBits;
inline bool hasBindingBit(int) const;
void clearBindingBit(int);
diff --git a/src/qml/qml/qqmlengine.cpp b/src/qml/qml/qqmlengine.cpp
index f8e5ad5874..205034dfbb 100644
--- a/src/qml/qml/qqmlengine.cpp
+++ b/src/qml/qml/qqmlengine.cpp
@@ -107,7 +107,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(QQmlProperty)
diff --git a/src/qml/qml/qqmlengine_p.h b/src/qml/qml/qqmlengine_p.h
index 19eb320fbe..e292dbf6c0 100644
--- a/src/qml/qml/qqmlengine_p.h
+++ b/src/qml/qml/qqmlengine_p.h
@@ -271,16 +271,16 @@ public:
mutable QMutex mutex;
private:
- // Locker locks the QQmlEnginePrivate data structures for read and write, if necessary.
- // Currently, locking is only necessary if the threaded loader is running concurrently. If it is
+ // Locker locks the QQmlEnginePrivate data structures for read and write, if necessary.
+ // Currently, locking is only necessary if the threaded loader is running concurrently. If it is
// either idle, or is running with the main thread blocked, no locking is necessary. This way
// we only pay for locking when we have to.
- // Consequently, this class should only be used to protect simple accesses or modifications of the
+ // Consequently, this class should only be used to protect simple accesses or modifications of the
// QQmlEnginePrivate structures or operations that can be guaranteed not to start activity
// on the loader thread.
- // The Locker API is identical to QMutexLocker. Locker reuses the QQmlEnginePrivate::mutex
+ // The Locker API is identical to QMutexLocker. Locker reuses the QQmlEnginePrivate::mutex
// QMutex instance and multiple Lockers are recursive in the same thread.
- class Locker
+ class Locker
{
public:
inline Locker(const QQmlEngine *);
@@ -333,7 +333,7 @@ QQmlEnginePrivate::Locker::~Locker()
void QQmlEnginePrivate::Locker::unlock()
{
- if (m_locked) {
+ if (m_locked) {
m_ep->mutex.unlock();
m_locked = false;
}
@@ -373,7 +373,7 @@ thread, \a value will be deleted immediately.
This method should be used for *any* type that has resources that need to
be freed in the engine thread. This is generally types that use V8 handles.
As there is some small overhead in checking the current thread, it is best
-practice to check if any V8 handles actually need to be freed and delete
+practice to check if any V8 handles actually need to be freed and delete
the instance directly if not.
*/
template<typename T>
@@ -384,7 +384,7 @@ void QQmlEnginePrivate::deleteInEngineThread(T *value)
Q_ASSERT(value);
if (isEngineThread()) {
delete value;
- } else {
+ } else {
struct I : public Deletable {
I(T *value) : value(value) {}
~I() { delete value; }
@@ -420,10 +420,10 @@ is returned.
The returned cache is not referenced, so if it is to be stored, call addref().
XXX thread There is a potential future race condition in this and all the cache()
-functions. As the QQmlPropertyCache is returned unreferenced, when called
-from the loader thread, it is possible that the cache will have been dereferenced
+functions. As the QQmlPropertyCache is returned unreferenced, when called
+from the loader thread, it is possible that the cache will have been dereferenced
and deleted before the loader thread has a chance to use or reference it. This
-can't currently happen as the cache holds a reference to the
+can't currently happen as the cache holds a reference to the
QQmlPropertyCache until the QQmlEngine is destroyed.
*/
QQmlPropertyCache *QQmlEnginePrivate::cache(QObject *obj)
@@ -475,8 +475,8 @@ QQmlPropertyCache *QQmlEnginePrivate::cache(QQmlType *type, int minorVersion, QQ
return rv;
}
-QV8Engine *QQmlEnginePrivate::getV8Engine(QQmlEngine *e)
-{
+QV8Engine *QQmlEnginePrivate::getV8Engine(QQmlEngine *e)
+{
Q_ASSERT(e);
return e->d_func()->v8engine();
@@ -489,32 +489,32 @@ QV4::ExecutionEngine *QQmlEnginePrivate::getV4Engine(QQmlEngine *e)
return e->d_func()->v4engine();
}
-QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlEngine *e)
-{
+QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlEngine *e)
+{
Q_ASSERT(e);
return e->d_func();
}
-const QQmlEnginePrivate *QQmlEnginePrivate::get(const QQmlEngine *e)
-{
+const QQmlEnginePrivate *QQmlEnginePrivate::get(const QQmlEngine *e)
+{
Q_ASSERT(e);
return e->d_func();
}
-QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlContext *c)
-{
- return (c && c->engine()) ? QQmlEnginePrivate::get(c->engine()) : 0;
+QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlContext *c)
+{
+ return (c && c->engine()) ? QQmlEnginePrivate::get(c->engine()) : 0;
}
-QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlContextData *c)
-{
- return (c && c->engine) ? QQmlEnginePrivate::get(c->engine) : 0;
+QQmlEnginePrivate *QQmlEnginePrivate::get(QQmlContextData *c)
+{
+ return (c && c->engine) ? QQmlEnginePrivate::get(c->engine) : 0;
}
-QQmlEngine *QQmlEnginePrivate::get(QQmlEnginePrivate *p)
-{
+QQmlEngine *QQmlEnginePrivate::get(QQmlEnginePrivate *p)
+{
Q_ASSERT(p);
return p->q_func();
diff --git a/src/qml/qml/qqmlerror.cpp b/src/qml/qml/qqmlerror.cpp
index ad95ecdf06..c583156c43 100644
--- a/src/qml/qml/qqmlerror.cpp
+++ b/src/qml/qml/qqmlerror.cpp
@@ -131,7 +131,7 @@ QQmlError &QQmlError::operator=(const QQmlError &other)
}
/*!
- \internal
+ \internal
*/
QQmlError::~QQmlError()
{
@@ -297,7 +297,7 @@ QDebug operator<<(QDebug debug, const QQmlError &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/qml/qml/qqmlglobal_p.h b/src/qml/qml/qqmlglobal_p.h
index 7b968a7e46..eca13e8fb8 100644
--- a/src/qml/qml/qqmlglobal_p.h
+++ b/src/qml/qml/qqmlglobal_p.h
@@ -193,14 +193,14 @@ struct QQmlGraphics_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/qml/qml/qqmlguard_p.h b/src/qml/qml/qqmlguard_p.h
index 455f5c93a8..b2e0949c74 100644
--- a/src/qml/qml/qqmlguard_p.h
+++ b/src/qml/qml/qqmlguard_p.h
@@ -59,7 +59,7 @@
QT_BEGIN_NAMESPACE
-class QQmlGuardImpl
+class QQmlGuardImpl
{
public:
inline QQmlGuardImpl();
@@ -91,7 +91,7 @@ public:
inline T *object() const;
inline void setObject(T *g);
-
+
inline bool isNull() const
{ return !o; }
@@ -141,7 +141,7 @@ void QQmlGuardImpl::addGuard()
{
Q_ASSERT(!prev);
- if (QObjectPrivate::get(o)->wasDeleted)
+ if (QObjectPrivate::get(o)->wasDeleted)
return;
QQmlData *data = QQmlData::get(o, true);
@@ -198,13 +198,13 @@ QQmlGuard<T> &QQmlGuard<T>::operator=(T *g)
}
template<class T>
-T *QQmlGuard<T>::object() const
-{
- return static_cast<T *>(o);
+T *QQmlGuard<T>::object() const
+{
+ return static_cast<T *>(o);
}
template<class T>
-void QQmlGuard<T>::setObject(T *g)
+void QQmlGuard<T>::setObject(T *g)
{
if (g != o) {
if (prev) remGuard();
diff --git a/src/qml/qml/qqmlimport.cpp b/src/qml/qml/qqmlimport.cpp
index 8645d2116a..0848af07e3 100644
--- a/src/qml/qml/qqmlimport.cpp
+++ b/src/qml/qml/qqmlimport.cpp
@@ -303,7 +303,7 @@ public:
\brief The QQmlImports class encapsulates one QML document's import statements.
\internal
*/
-QQmlImports::QQmlImports(const QQmlImports &copy)
+QQmlImports::QQmlImports(const QQmlImports &copy)
: d(copy.d)
{
++d->ref;
@@ -1631,7 +1631,7 @@ QString QQmlImportDatabase::resolvePlugin(QQmlTypeLoader *typeLoader,
}
if (qmlImportTrace())
- qDebug() << "QQmlImportDatabase::resolvePlugin: Could not resolve plugin" << baseName
+ qDebug() << "QQmlImportDatabase::resolvePlugin: Could not resolve plugin" << baseName
<< "in" << qmldirPath;
return QString();
diff --git a/src/qml/qml/qqmlincubator.cpp b/src/qml/qml/qqmlincubator.cpp
index 52bf1d8b3e..10fd05ab58 100644
--- a/src/qml/qml/qqmlincubator.cpp
+++ b/src/qml/qml/qqmlincubator.cpp
@@ -48,8 +48,8 @@
#include "qqmlmemoryprofiler_p.h"
#include "qqmlobjectcreator_p.h"
-// XXX TODO
-// - check that the Component.onCompleted behavior is the same as 4.8 in the synchronous and
+// XXX TODO
+// - check that the Component.onCompleted behavior is the same as 4.8 in the synchronous and
// async if nested cases
void QQmlEnginePrivate::incubate(QQmlIncubator &i, QQmlContextData *forContext)
{
@@ -107,7 +107,7 @@ void QQmlEnginePrivate::incubate(QQmlIncubator &i, QQmlContextData *forContext)
}
/*!
-Sets the engine's incubation \a controller. The engine can only have one active controller
+Sets the engine's incubation \a controller. The engine can only have one active controller
and it does not take ownership of it.
\sa incubationController()
@@ -181,7 +181,7 @@ the process of creating objects a QQmlIncubators must be driven only during the
application's idle time. QQmlIncubationController allows the application to control
exactly when, how often and for how long this processing occurs.
-A QQmlIncubationController derived instance should be created and set on a
+A QQmlIncubationController derived instance should be created and set on a
QQmlEngine by calling the QQmlEngine::setIncubationController() method.
Processing is then controlled by calling the QQmlIncubationController::incubateFor()
or QQmlIncubationController::incubateWhile() methods as dictated by the application's
@@ -191,12 +191,12 @@ For example, this is an example of a incubation controller that will incubate fo
of 5 milliseconds out of every 16 milliseconds.
\code
-class PeriodicIncubationController : public QObject,
- public QQmlIncubationController
+class PeriodicIncubationController : public QObject,
+ public QQmlIncubationController
{
public:
- PeriodicIncubationController() {
- startTimer(16);
+ PeriodicIncubationController() {
+ startTimer(16);
}
protected:
@@ -208,7 +208,7 @@ protected:
Although the previous example would work, it is not optimal. Real world incubation
controllers should try and maximize the amount of idle time they consume - rather
-than a static amount like 5 milliseconds - while not disturbing the application.
+than a static amount like 5 milliseconds - while not disturbing the application.
*/
/*!
@@ -244,7 +244,7 @@ int QQmlIncubationController::incubatingObjectCount() const
}
/*!
-Called when the number of incubating objects changes. \a incubatingObjectCount is the
+Called when the number of incubating objects changes. \a incubatingObjectCount is the
new number of incubating objects.
The default implementation does nothing.
@@ -307,7 +307,7 @@ void QQmlIncubatorPrivate::incubate(QQmlVME::Interrupt &i)
return;
result = tresult;
- if (errors.isEmpty() && result == 0)
+ if (errors.isEmpty() && result == 0)
goto finishIncubate;
if (result) {
@@ -428,8 +428,8 @@ application uses QQmlComponent::create() directly, the QML object instance is cr
synchronously which, depending on the complexity of the object, can cause noticeable pauses or
stutters in the application.
-The use of QQmlIncubator gives more control over the creation of a QML object,
-including allowing it to be created asynchronously using application idle time. The following
+The use of QQmlIncubator gives more control over the creation of a QML object,
+including allowing it to be created asynchronously using application idle time. The following
example shows a simple use of QQmlIncubator.
\code
@@ -443,25 +443,25 @@ while (incubator.isReady()) {
QObject *object = incubator.object();
\endcode
-Asynchronous incubators are controlled by a QQmlIncubationController that is
+Asynchronous incubators are controlled by a QQmlIncubationController that is
set on the QQmlEngine, which lets the engine know when the application is idle and
incubating objects should be processed. If an incubation controller is not set on the
QQmlEngine, QQmlIncubator creates objects synchronously regardless of the
-specified IncubationMode.
+specified IncubationMode.
QQmlIncubator supports three incubation modes:
\list
\li Synchronous The creation occurs synchronously. That is, once the
QQmlComponent::create() call returns, the incubator will already be in either the
Error or Ready state. A synchronous incubator has no real advantage compared to using
-the synchronous creation methods on QQmlComponent directly, but it may simplify an
-application's implementation to use the same API for both synchronous and asynchronous
+the synchronous creation methods on QQmlComponent directly, but it may simplify an
+application's implementation to use the same API for both synchronous and asynchronous
creations.
\li Asynchronous (default) The creation occurs asynchronously, assuming a
-QQmlIncubatorController is set on the QQmlEngine.
+QQmlIncubatorController is set on the QQmlEngine.
-The incubator will remain in the Loading state until either the creation is complete or an error
+The incubator will remain in the Loading state until either the creation is complete or an error
occurs. The statusChanged() callback can be used to be notified of status changes.
Applications should use the Asynchronous incubation mode to create objects that are not needed
@@ -471,31 +471,31 @@ the object is needed immediately the QQmlIncubator::forceCompletion() method can
to complete the creation process synchronously.
\li AsynchronousIfNested The creation will occur asynchronously if part of a nested asynchronous
-creation, or synchronously if not.
+creation, or synchronously if not.
In most scenarios where a QML component wants the appearance of a synchronous
-instantiation, it should use this mode.
+instantiation, it should use this mode.
This mode is best explained with an example. When the ListView type is first created, it needs
-to populate itself with an initial set of delegates to show. If the ListView was 400 pixels high,
+to populate itself with an initial set of delegates to show. If the ListView was 400 pixels high,
and each delegate was 100 pixels high, it would need to create four initial delegate instances. If
the ListView used the Asynchronous incubation mode, the ListView would always be created empty and
then, sometime later, the four initial items would appear.
-Conversely, if the ListView was to use the Synchronous incubation mode it would behave correctly
-but it may introduce stutters into the application. As QML would have to stop and instantiate the
-ListView's delegates synchronously, if the ListView was part of a QML component that was being
+Conversely, if the ListView was to use the Synchronous incubation mode it would behave correctly
+but it may introduce stutters into the application. As QML would have to stop and instantiate the
+ListView's delegates synchronously, if the ListView was part of a QML component that was being
instantiated asynchronously this would undo much of the benefit of asynchronous instantiation.
The AsynchronousIfNested mode reconciles this problem. By using AsynchronousIfNested, the ListView
delegates are instantiated asynchronously if the ListView itself is already part of an asynchronous
instantiation, and synchronously otherwise. In the case of a nested asynchronous instantiation, the
outer asynchronous instantiation will not complete until after all the nested instantiations have also
-completed. This ensures that by the time the outer asynchronous instantitation completes, inner
+completed. This ensures that by the time the outer asynchronous instantitation completes, inner
items like ListView have already completed loading their initial delegates.
It is almost always incorrect to use the Synchronous incubation mode - elements or components that
-want the appearance of synchronous instantiation, but without the downsides of introducing freezes
+want the appearance of synchronous instantiation, but without the downsides of introducing freezes
or stutters into the application, should use the AsynchronousIfNested incubation mode.
\endlist
*/
@@ -523,14 +523,14 @@ QQmlIncubator::~QQmlIncubator()
/*!
\enum QQmlIncubator::IncubationMode
-Specifies the mode the incubator operates in. Regardless of the incubation mode, a
+Specifies the mode the incubator operates in. Regardless of the incubation mode, a
QQmlIncubator will behave synchronously if the QQmlEngine does not have
a QQmlIncubationController set.
\value Asynchronous The object will be created asynchronously.
\value AsynchronousIfNested If the object is being created in a context that is already part
-of an asynchronous creation, this incubator will join that existing incubation and execute
-asynchronously. The existing incubation will not become Ready until both it and this
+of an asynchronous creation, this incubator will join that existing incubation and execute
+asynchronously. The existing incubation will not become Ready until both it and this
incubation have completed. Otherwise, the incubation will execute synchronously.
\value Synchronous The object will be created synchronously.
*/
@@ -547,7 +547,7 @@ Specifies the status of the QQmlIncubator.
*/
/*!
-Clears the incubator. Any in-progress incubation is aborted. If the incubator is in the
+Clears the incubator. Any in-progress incubation is aborted. If the incubator is in the
Ready state, the created object is \b not deleted.
*/
void QQmlIncubator::clear()
@@ -706,7 +706,7 @@ void QQmlIncubator::setInitialState(QObject *object)
void QQmlIncubatorPrivate::changeStatus(QQmlIncubator::Status s)
{
- if (s == status)
+ if (s == status)
return;
status = s;
@@ -716,13 +716,13 @@ void QQmlIncubatorPrivate::changeStatus(QQmlIncubator::Status s)
QQmlIncubator::Status QQmlIncubatorPrivate::calculateStatus() const
{
- if (!errors.isEmpty())
+ if (!errors.isEmpty())
return QQmlIncubator::Error;
else if (result && progress == QQmlIncubatorPrivate::Completed && waitingFor.isEmpty())
return QQmlIncubator::Ready;
else if (compiledData)
return QQmlIncubator::Loading;
- else
+ else
return QQmlIncubator::Null;
}
diff --git a/src/qml/qml/qqmlincubator.h b/src/qml/qml/qqmlincubator.h
index 4d3287a394..2bcaee8a45 100644
--- a/src/qml/qml/qqmlincubator.h
+++ b/src/qml/qml/qqmlincubator.h
@@ -60,11 +60,11 @@ public:
AsynchronousIfNested,
Synchronous
};
- enum Status {
- Null,
- Ready,
- Loading,
- Error
+ enum Status {
+ Null,
+ Ready,
+ Loading,
+ Error
};
QQmlIncubator(IncubationMode = Asynchronous);
diff --git a/src/qml/qml/qqmlinfo.cpp b/src/qml/qml/qqmlinfo.cpp
index 32f0eeef36..63ce2d419c 100644
--- a/src/qml/qml/qqmlinfo.cpp
+++ b/src/qml/qml/qqmlinfo.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/qml/qml/qqmlinstruction_p.h b/src/qml/qml/qqmlinstruction_p.h
index bda8c3db0d..aeda9832f3 100644
--- a/src/qml/qml/qqmlinstruction_p.h
+++ b/src/qml/qml/qqmlinstruction_p.h
@@ -131,7 +131,7 @@ QT_BEGIN_NAMESPACE
F(Defer, defer) \
F(PopFetchedObject, common) \
F(FetchValueType, fetchValue) \
- F(PopValueType, fetchValue)
+ F(PopValueType, fetchValue)
#ifndef QT_NO_TRANSLATION
#define F_TRANSLATION(F, I, FMT) F(I, FMT)
@@ -161,7 +161,7 @@ QT_BEGIN_NAMESPACE
class QQmlCompiledData;
union QQmlInstruction
{
- enum Type {
+ enum Type {
FOR_EACH_QML_INSTR(QML_INSTR_ENUM)
};
@@ -193,7 +193,7 @@ union QQmlInstruction
struct instr_completeQml {
QML_INSTR_HEADER
ushort column;
- ushort line;
+ ushort line;
bool isRoot;
};
struct instr_create {
@@ -201,7 +201,7 @@ union QQmlInstruction
int type;
int data;
ushort column;
- ushort line;
+ ushort line;
bool isRoot:1;
bool parentToSuper:1;
};
@@ -211,7 +211,7 @@ union QQmlInstruction
int typeSize;
int type;
ushort column;
- ushort line;
+ ushort line;
bool parentToSuper;
};
struct instr_storeMeta {
@@ -266,7 +266,7 @@ union QQmlInstruction
struct instr_begin {
QML_INSTR_HEADER
int castValue;
- };
+ };
struct instr_storeFloat {
QML_INSTR_HEADER
int propertyIndex;
@@ -322,7 +322,7 @@ union QQmlInstruction
double numberValue;
bool isStringLiteral:1;
bool isNumberLiteral:1;
- };
+ };
struct instr_storeScript {
QML_INSTR_HEADER
int value;
@@ -399,7 +399,7 @@ union QQmlInstruction
struct instr_assignSignalObject {
QML_INSTR_HEADER
int signal;
- ushort line;
+ ushort line;
};
struct instr_createComponent {
QML_INSTR_HEADER
diff --git a/src/qml/qml/qqmllist.cpp b/src/qml/qml/qqmllist.cpp
index d172c9a185..6d0fddf2ad 100644
--- a/src/qml/qml/qqmllist.cpp
+++ b/src/qml/qml/qqmllist.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().
The \l {Qt Quick 1} version of this class is named QDeclarativeListReference.
@@ -125,7 +125,7 @@ QQmlListReference::QQmlListReference()
/*!
Constructs a QQmlListReference for \a object's \a property. If \a property is not a list
-property, an invalid QQmlListReference is created. If \a object is destroyed after
+property, an invalid QQmlListReference is created. If \a object is destroyed after
the reference is constructed, it will automatically become invalid. That is, it is safe to hold
QQmlListReference instances even after \a object is deleted.
@@ -243,7 +243,7 @@ bool QQmlListReference::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()
@@ -336,7 +336,7 @@ int QQmlListReference::count() const
\class QQmlListProperty
\since 5.0
\inmodule QtQml
-\brief The QQmlListProperty class allows applications to expose list-like
+\brief The QQmlListProperty class allows applications to expose list-like
properties to QML.
QML has many list properties, where more than one object value can be assigned.
@@ -344,7 +344,7 @@ The use of a list property from QML looks like this:
\code
FruitBasket {
- fruit: [
+ fruit: [
Apple {},
Orange{},
Banana{}
@@ -354,10 +354,10 @@ FruitBasket {
The QQmlListProperty 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 QQmlListProperty value from the property getter.
List properties should have no setter. In the example above, the Q_PROPERTY()
declarative will look like this:
@@ -366,7 +366,7 @@ declarative will look like this:
Q_PROPERTY(QQmlListProperty<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.
The \l {Qt Quick 1} version of this class is named QDeclarativeListProperty.
@@ -375,7 +375,7 @@ The \l {Qt Quick 1} version of this class is named QDeclarativeListProperty.
*/
/*!
-\fn QQmlListProperty::QQmlListProperty()
+\fn QQmlListProperty::QQmlListProperty()
\internal
*/
@@ -386,7 +386,7 @@ Convenience constructor for making a QQmlListProperty value from an existing
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.
*/
@@ -401,12 +401,12 @@ remains valid while \a object exists.
*/
/*!
-\fn QQmlListProperty::QQmlListProperty(QObject *object, void *data, AppendFunction append,
+\fn QQmlListProperty::QQmlListProperty(QObject *object, void *data, AppendFunction append,
CountFunction count, AtFunction at,
ClearFunction clear)
Construct a QQmlListProperty 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.
Null pointers can be passed for any function. If any null pointers are passed in, the list
@@ -431,7 +431,7 @@ Return the number of elements in the list \a property.
*/
/*!
-\fn bool QQmlListProperty::operator==(const QQmlListProperty &other) const
+\fn bool QQmlListProperty::operator==(const QQmlListProperty &other) const
Returns true if this QQmlListProperty is equal to \a other, otherwise false.
*/
diff --git a/src/qml/qml/qqmlmetatype.cpp b/src/qml/qml/qqmlmetatype.cpp
index 437e920d1a..1dd8ce0e3e 100644
--- a/src/qml/qml/qqmlmetatype.cpp
+++ b/src/qml/qml/qqmlmetatype.cpp
@@ -116,7 +116,7 @@ struct QQmlMetaTypeData
class QQmlTypeModulePrivate
{
public:
- QQmlTypeModulePrivate()
+ QQmlTypeModulePrivate()
: minMinorVersion(INT_MAX), maxMinorVersion(0), locked(false) {}
static QQmlTypeModulePrivate* get(QQmlTypeModule* q) { return q->d; }
@@ -479,7 +479,7 @@ QQmlType *QQmlType::superType() const
return d->superType;
}
-static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo,
+static void clone(QMetaObjectBuilder &builder, const QMetaObject *mo,
const QMetaObject *ignoreStart, const QMetaObject *ignoreEnd)
{
// Set classname
@@ -491,7 +491,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());
}
@@ -504,7 +504,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);
}
@@ -520,7 +520,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) {
@@ -540,7 +540,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);
}
@@ -860,7 +860,7 @@ const QMetaObject *QQmlType::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 QQmlType::attachedPropertiesId() const
@@ -1128,7 +1128,7 @@ int registerAutoParentFunction(QQmlPrivate::RegisterAutoParent &autoparent)
int registerInterface(const QQmlPrivate::RegisterInterface &interface)
{
- if (interface.version > 0)
+ if (interface.version > 0)
qFatal("qmlRegisterType(): Cannot mix incompatible QML versions.");
QWriteLocker lock(metaTypeDataLock());
@@ -1472,7 +1472,7 @@ bool QQmlMetaType::isModule(const QString &module, int versionMajor, int version
QQmlMetaTypeData *data = metaTypeData();
// first, check Types
- QQmlTypeModule *tm =
+ QQmlTypeModule *tm =
data->uriToModule.value(QQmlMetaTypeData::VersionedUri(module, versionMajor));
if (tm && tm->minimumMinorVersion() <= versionMinor && tm->maximumMinorVersion() >= versionMinor)
return true;
@@ -1755,7 +1755,7 @@ QQmlType *QQmlMetaType::qmlType(const QMetaObject *metaObject, const QHashedStri
}
/*!
- 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.
*/
QQmlType *QQmlMetaType::qmlType(int userType)
diff --git a/src/qml/qml/qqmlmetatype_p.h b/src/qml/qml/qqmlmetatype_p.h
index 2f473f5f46..6c19da6b15 100644
--- a/src/qml/qml/qqmlmetatype_p.h
+++ b/src/qml/qml/qqmlmetatype_p.h
@@ -103,7 +103,7 @@ public:
enum TypeCategory { Unknown, Object, List };
static TypeCategory typeCategory(int);
-
+
static bool isInterface(int);
static const char *interfaceIId(int);
static bool isList(int);
@@ -277,7 +277,7 @@ private:
QQmlTypeModulePrivate *d;
};
-class QQmlTypeModuleVersion
+class QQmlTypeModuleVersion
{
public:
QQmlTypeModuleVersion();
diff --git a/src/qml/qml/qqmlnotifier.cpp b/src/qml/qml/qqmlnotifier.cpp
index 3d4b260574..fb058379be 100644
--- a/src/qml/qml/qqmlnotifier.cpp
+++ b/src/qml/qml/qqmlnotifier.cpp
@@ -84,7 +84,7 @@ void QQmlNotifier::emitNotify(QQmlNotifierEndpoint *endpoint, void **a)
// End of notifying, restore values
endpoint->senderPtr = originalSenderPtr;
}
- }
+ }
}
/*! \internal
diff --git a/src/qml/qml/qqmlnotifier_p.h b/src/qml/qml/qqmlnotifier_p.h
index 93f2cd68da..0794f3a911 100644
--- a/src/qml/qml/qqmlnotifier_p.h
+++ b/src/qml/qml/qqmlnotifier_p.h
@@ -123,7 +123,7 @@ QQmlNotifier::QQmlNotifier()
}
QQmlNotifier::~QQmlNotifier()
-{
+{
QQmlNotifierEndpoint *endpoint = endpoints;
while (endpoint) {
QQmlNotifierEndpoint *n = endpoint;
@@ -221,7 +221,7 @@ bool QQmlNotifierEndpoint::isNotifying() const
/*!
Cancel any notifies that are in progress.
*/
-void QQmlNotifierEndpoint::cancelNotify()
+void QQmlNotifierEndpoint::cancelNotify()
{
if (isNotifying()) {
qintptr sp = *((qintptr *)(senderPtr & ~0x1));
diff --git a/src/qml/qml/qqmlnullablevalue_p_p.h b/src/qml/qml/qqmlnullablevalue_p_p.h
index ed3dfb8780..6c17153181 100644
--- a/src/qml/qml/qqmlnullablevalue_p_p.h
+++ b/src/qml/qml/qqmlnullablevalue_p_p.h
@@ -56,7 +56,7 @@
QT_BEGIN_NAMESPACE
template<typename T>
-struct QQmlNullableValue
+struct QQmlNullableValue
{
QQmlNullableValue()
: isNull(true), value(T()) {}
diff --git a/src/qml/qml/qqmlopenmetaobject.cpp b/src/qml/qml/qqmlopenmetaobject.cpp
index 5745f35498..4d2c3d0332 100644
--- a/src/qml/qml/qqmlopenmetaobject.cpp
+++ b/src/qml/qml/qqmlopenmetaobject.cpp
@@ -254,7 +254,7 @@ int QQmlOpenMetaObject::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/qml/qml/qqmlparserstatus.cpp b/src/qml/qml/qqmlparserstatus.cpp
index 41b7d962ce..0da22fb668 100644
--- a/src/qml/qml/qqmlparserstatus.cpp
+++ b/src/qml/qml/qqmlparserstatus.cpp
@@ -109,7 +109,7 @@ QQmlParserStatus::~QQmlParserStatus()
/*!
\fn void QQmlParserStatus::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/qml/qml/qqmlprivate.h b/src/qml/qml/qqmlprivate.h
index 15306cb131..90e7961e6b 100644
--- a/src/qml/qml/qqmlprivate.h
+++ b/src/qml/qml/qqmlprivate.h
@@ -85,8 +85,8 @@ namespace QQmlPrivate
class QQmlElement : public T
{
public:
- virtual ~QQmlElement() {
- QQmlPrivate::qdeclarativeelement_destructor(this);
+ virtual ~QQmlElement() {
+ QQmlPrivate::qdeclarativeelement_destructor(this);
}
};
@@ -130,7 +130,7 @@ namespace QQmlPrivate
};
template <typename T, bool hasMember>
- class has_attachedPropertiesMethod
+ class has_attachedPropertiesMethod
{
public:
typedef int yes_type;
@@ -141,7 +141,7 @@ namespace QQmlPrivate
static no_type check(...);
static bool const value = sizeof(check(&T::qmlAttachedProperties)) == sizeof(yes_type);
- };
+ };
template <typename T>
class has_attachedPropertiesMethod<T, false>
diff --git a/src/qml/qml/qqmlproperty.cpp b/src/qml/qml/qqmlproperty.cpp
index 3975b88bb0..0bbcafda54 100644
--- a/src/qml/qml/qqmlproperty.cpp
+++ b/src/qml/qml/qqmlproperty.cpp
@@ -1250,7 +1250,7 @@ QQmlPropertyPrivate::writeValueProperty(QObject *object,
return rv;
}
-bool QQmlPropertyPrivate::write(QObject *object,
+bool QQmlPropertyPrivate::write(QObject *object,
const QQmlPropertyData &property,
const QVariant &value, QQmlContextData *context,
WriteFlags flags)
diff --git a/src/qml/qml/qqmlproperty.h b/src/qml/qml/qqmlproperty.h
index c3322c0048..992d579aed 100644
--- a/src/qml/qml/qqmlproperty.h
+++ b/src/qml/qml/qqmlproperty.h
@@ -64,7 +64,7 @@ public:
Normal
};
- enum Type {
+ enum Type {
Invalid,
Property,
SignalProperty
diff --git a/src/qml/qml/qqmlproperty_p.h b/src/qml/qml/qqmlproperty_p.h
index ce15061ba0..28e9dca515 100644
--- a/src/qml/qml/qqmlproperty_p.h
+++ b/src/qml/qml/qqmlproperty_p.h
@@ -101,11 +101,11 @@ public:
bool writeValueProperty(const QVariant &, WriteFlags);
static QQmlMetaObject rawMetaObjectForType(QQmlEnginePrivate *, 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 writeValueProperty(QObject *,
const QQmlPropertyData &,
- const QVariant &, QQmlContextData *,
+ const QVariant &, QQmlContextData *,
WriteFlags flags = 0);
static bool write(QObject *, const QQmlPropertyData &, const QVariant &,
QQmlContextData *, WriteFlags flags = 0);
diff --git a/src/qml/qml/qqmlproxymetaobject.cpp b/src/qml/qml/qqmlproxymetaobject.cpp
index 8a6af7cb05..282cbb7a21 100644
--- a/src/qml/qml/qqmlproxymetaobject.cpp
+++ b/src/qml/qml/qqmlproxymetaobject.cpp
@@ -78,7 +78,7 @@ int QQmlProxyMetaObject::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 QQmlProxyMetaObject::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)
QQmlPropertyPrivate::connect(proxy, methodOffset + jj, object, localOffset + jj);
diff --git a/src/qml/qml/qqmlscript.cpp b/src/qml/qml/qqmlscript.cpp
index 6cb23ec07c..0618c90fa5 100644
--- a/src/qml/qml/qqmlscript.cpp
+++ b/src/qml/qml/qqmlscript.cpp
@@ -58,7 +58,7 @@ QT_BEGIN_NAMESPACE
using namespace QQmlJS;
using namespace QQmlScript;
-//
+//
// Parser IR classes
//
QQmlScript::Object::Object()
@@ -68,8 +68,8 @@ QQmlScript::Object::Object()
{
}
-QQmlScript::Object::~Object()
-{
+QQmlScript::Object::~Object()
+{
if (synthCache) synthCache->release();
}
@@ -215,7 +215,7 @@ int QQmlScript::Object::DynamicSlot::parameterNamesLength() const
}
QQmlScript::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), isReadOnlyDeclaration(false),
scriptStringScope(-1), nextMainProperty(0), nextProperty(0)
{
@@ -354,7 +354,7 @@ QString escapedString(const QString &string)
QString QQmlScript::Variant::asScript() const
{
- switch(type()) {
+ switch (type()) {
default:
case Invalid:
return QString();
@@ -363,7 +363,7 @@ QString QQmlScript::Variant::asScript() const
case Number:
if (asWritten.isEmpty())
return QString::number(d);
- else
+ else
return asWritten.toString();
case String:
return escapedString(asString());
@@ -727,7 +727,7 @@ ProcessAST::defineObjectBinding(AST::Node *node,
} else {
// Class
- QQmlScript::Object *obj = _parser->_pool.New<QQmlScript::Object>();
+ QQmlScript::Object *obj = _parser->_pool.New<QQmlScript::Object>();
obj->type = _parser->findOrCreateTypeId(objectType, obj);
obj->typeReference = _parser->_refTypes.at(obj->type);
@@ -1034,11 +1034,11 @@ bool ProcessAST::visit(AST::UiPublicMember *node)
bool typeFound = false;
Object::DynamicProperty::Type type;
- if ((unsigned)memberType.length() == strlen("alias") &&
+ if ((unsigned)memberType.length() == strlen("alias") &&
QHashedString::compare(memberType.constData(), "alias", int(strlen("alias")))) {
type = Object::DynamicProperty::Alias;
typeFound = true;
- }
+ }
for(int ii = 0; !typeFound && ii < propTypeNameToTypesCount; ++ii) {
const TypeNameToType *t = propTypeNameToTypes + ii;
@@ -1054,7 +1054,7 @@ bool ProcessAST::visit(AST::UiPublicMember *node)
if (typeModifier.isEmpty()) {
type = Object::DynamicProperty::Custom;
- } else if((unsigned)typeModifier.length() == strlen("list") &&
+ } else if ((unsigned)typeModifier.length() == strlen("list") &&
QHashedString::compare(typeModifier.constData(), "list", int(strlen("list")))) {
type = Object::DynamicProperty::CustomList;
} else {
@@ -1411,7 +1411,7 @@ QList<QQmlError> QQmlScript::Parser::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(' '));
@@ -1490,42 +1490,42 @@ QQmlScript::Object::ScriptBlock::Pragmas QQmlScript::Parser::extractPragmas(QStr
#define CHECK_TOKEN(t) if (token != QQmlJSGrammar:: t) return rv;
static const int uriTokens[] = {
- QQmlJSGrammar::T_IDENTIFIER,
- QQmlJSGrammar::T_PROPERTY,
- QQmlJSGrammar::T_SIGNAL,
- QQmlJSGrammar::T_READONLY,
- QQmlJSGrammar::T_ON,
- QQmlJSGrammar::T_BREAK,
- QQmlJSGrammar::T_CASE,
- QQmlJSGrammar::T_CATCH,
- QQmlJSGrammar::T_CONTINUE,
- QQmlJSGrammar::T_DEFAULT,
- QQmlJSGrammar::T_DELETE,
- QQmlJSGrammar::T_DO,
- QQmlJSGrammar::T_ELSE,
- QQmlJSGrammar::T_FALSE,
- QQmlJSGrammar::T_FINALLY,
- QQmlJSGrammar::T_FOR,
- QQmlJSGrammar::T_FUNCTION,
- QQmlJSGrammar::T_IF,
- QQmlJSGrammar::T_IN,
- QQmlJSGrammar::T_INSTANCEOF,
- QQmlJSGrammar::T_NEW,
- QQmlJSGrammar::T_NULL,
- QQmlJSGrammar::T_RETURN,
- QQmlJSGrammar::T_SWITCH,
- QQmlJSGrammar::T_THIS,
- QQmlJSGrammar::T_THROW,
- QQmlJSGrammar::T_TRUE,
- QQmlJSGrammar::T_TRY,
- QQmlJSGrammar::T_TYPEOF,
- QQmlJSGrammar::T_VAR,
- QQmlJSGrammar::T_VOID,
- QQmlJSGrammar::T_WHILE,
- QQmlJSGrammar::T_CONST,
- QQmlJSGrammar::T_DEBUGGER,
- QQmlJSGrammar::T_RESERVED_WORD,
- QQmlJSGrammar::T_WITH,
+ QQmlJSGrammar::T_IDENTIFIER,
+ QQmlJSGrammar::T_PROPERTY,
+ QQmlJSGrammar::T_SIGNAL,
+ QQmlJSGrammar::T_READONLY,
+ QQmlJSGrammar::T_ON,
+ QQmlJSGrammar::T_BREAK,
+ QQmlJSGrammar::T_CASE,
+ QQmlJSGrammar::T_CATCH,
+ QQmlJSGrammar::T_CONTINUE,
+ QQmlJSGrammar::T_DEFAULT,
+ QQmlJSGrammar::T_DELETE,
+ QQmlJSGrammar::T_DO,
+ QQmlJSGrammar::T_ELSE,
+ QQmlJSGrammar::T_FALSE,
+ QQmlJSGrammar::T_FINALLY,
+ QQmlJSGrammar::T_FOR,
+ QQmlJSGrammar::T_FUNCTION,
+ QQmlJSGrammar::T_IF,
+ QQmlJSGrammar::T_IN,
+ QQmlJSGrammar::T_INSTANCEOF,
+ QQmlJSGrammar::T_NEW,
+ QQmlJSGrammar::T_NULL,
+ QQmlJSGrammar::T_RETURN,
+ QQmlJSGrammar::T_SWITCH,
+ QQmlJSGrammar::T_THIS,
+ QQmlJSGrammar::T_THROW,
+ QQmlJSGrammar::T_TRUE,
+ QQmlJSGrammar::T_TRY,
+ QQmlJSGrammar::T_TYPEOF,
+ QQmlJSGrammar::T_VAR,
+ QQmlJSGrammar::T_VOID,
+ QQmlJSGrammar::T_WHILE,
+ QQmlJSGrammar::T_CONST,
+ QQmlJSGrammar::T_DEBUGGER,
+ QQmlJSGrammar::T_RESERVED_WORD,
+ QQmlJSGrammar::T_WITH,
QQmlJSGrammar::EOF_SYMBOL
};
diff --git a/src/qml/qml/qqmlscript_p.h b/src/qml/qml/qqmlscript_p.h
index fac31add5c..29da97fe83 100644
--- a/src/qml/qml/qqmlscript_p.h
+++ b/src/qml/qml/qqmlscript_p.h
@@ -72,14 +72,14 @@ namespace QQmlCompilerTypes { struct BindingReference; struct ComponentCompileSt
namespace QQmlScript {
-struct Location
+struct Location
{
Location() : line(0), column(0) {}
quint16 line;
quint16 column;
inline bool operator<(const Location &other) {
- return line < other.line ||
+ return line < other.line ||
(line == other.line && column < other.column);
}
};
@@ -253,12 +253,12 @@ public:
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.
int index;
- // The core data in the case of a regular property.
+ // The core data in the case of a regular property.
// XXX This has to be a value now as the synthCache may change during
// compilation which invalidates pointers. We should fix this.
QQmlPropertyData core;
@@ -280,14 +280,14 @@ public:
const QHashedStringRef &name() const { return _name; }
void setName(const QString &n) { _name = QHashedStringRef(pool()->NewString(n)); }
void setName(const QHashedStringRef &n) { _name = n; }
- // 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
// QQmlCompiler
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
// QQmlCompiler
bool isAlias;
// True if this is a readonly property declaration
@@ -314,9 +314,9 @@ class Object : public QQmlPool::Class
{
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
// QQmlCompiledData::types array, or -1 if the object is a property
// group.
int type;
@@ -331,7 +331,7 @@ public:
// Custom parsed data
QByteArray custom;
// Bit mask of the properties assigned bindings
- QByteArray bindingBitmask;
+ QByteArray bindingBitmask;
void setBindingBit(int);
QQmlPropertyCache *metatype;
@@ -374,7 +374,7 @@ public:
// Script blocks that were nested under this object
struct ScriptBlock {
- enum Pragma {
+ enum Pragma {
None = 0x00000000,
Shared = 0x00000001
};
@@ -385,14 +385,14 @@ public:
Pragmas pragmas;
};
- // The bytes to cast instances by to get to the QQmlParserStatus
+ // The bytes to cast instances by to get to the QQmlParserStatus
// interface. -1 indicates the type doesn't support this interface.
// Set by the QQmlCompiler.
int parserStatusCast;
LocationSpan location;
- struct DynamicProperty : public QQmlPool::POD
+ struct DynamicProperty : public QQmlPool::POD
{
DynamicProperty();
@@ -500,7 +500,7 @@ public:
class JavaScriptMetaData {
public:
- JavaScriptMetaData()
+ JavaScriptMetaData()
: pragmas(QQmlScript::Object::ScriptBlock::None) {}
QQmlScript::Object::ScriptBlock::Pragmas pragmas;
diff --git a/src/qml/qml/qqmlscriptstring.h b/src/qml/qml/qqmlscriptstring.h
index b192be8b77..852e7d629d 100644
--- a/src/qml/qml/qqmlscriptstring.h
+++ b/src/qml/qml/qqmlscriptstring.h
@@ -54,7 +54,7 @@ class QObject;
class QQmlContext;
class QQmlScriptStringPrivate;
class QmlObjectCreator;
-class Q_QML_EXPORT QQmlScriptString
+class Q_QML_EXPORT QQmlScriptString
{
public:
QQmlScriptString();
diff --git a/src/qml/qml/qqmltypeloader.cpp b/src/qml/qml/qqmltypeloader.cpp
index 278bb017d0..f734b77eec 100644
--- a/src/qml/qml/qqmltypeloader.cpp
+++ b/src/qml/qml/qqmltypeloader.cpp
@@ -94,7 +94,7 @@
#else
-#define ASSERT_MAINTHREAD()
+#define ASSERT_MAINTHREAD()
#define ASSERT_LOADTHREAD()
#define ASSERT_CALLBACK()
@@ -116,9 +116,9 @@ namespace {
}
// This is a lame object that we need to ensure that slots connected to
-// QNetworkReply get called in the correct thread (the loader thread).
+// QNetworkReply get called in the correct thread (the loader thread).
// As QQmlDataLoader lives in the main thread, and we can't use
-// Qt::DirectConnection connections from a QNetworkReply (because then
+// Qt::DirectConnection connections from a QNetworkReply (because then
// sender() wont work), we need to insert this object in the middle.
class QQmlDataLoaderNetworkReplyProxy : public QObject
{
@@ -168,8 +168,8 @@ private:
};
-QQmlDataLoaderNetworkReplyProxy::QQmlDataLoaderNetworkReplyProxy(QQmlDataLoader *l)
-: l(l)
+QQmlDataLoaderNetworkReplyProxy::QQmlDataLoaderNetworkReplyProxy(QQmlDataLoader *l)
+: l(l)
{
}
@@ -241,7 +241,7 @@ This enum describes the type of the data blob.
Create a new QQmlDataBlob for \a url and of the provided \a type.
*/
QQmlDataBlob::QQmlDataBlob(const QUrl &url, Type type)
-: m_type(type), m_url(url), m_finalUrl(url), m_manager(0), m_redirectCount(0),
+: m_type(type), m_url(url), m_finalUrl(url), m_manager(0), m_redirectCount(0),
m_inCallback(false), m_isDone(false)
{
}
@@ -396,7 +396,7 @@ QList<QQmlError> QQmlDataBlob::errors() const
/*!
Mark this blob as having \a errors.
-All outstanding dependencies will be cancelled. Requests to add new dependencies
+All outstanding dependencies will be cancelled. Requests to add new dependencies
will be ignored. Entry into the Error state is irreversable.
The setError() method may only be called from within a QQmlDataBlob callback.
@@ -434,8 +434,8 @@ void QQmlDataBlob::setError(const QList<QQmlError> &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.
The setError() method may only be called from within a QQmlDataBlob callback.
@@ -448,7 +448,7 @@ void QQmlDataBlob::addDependency(QQmlDataBlob *blob)
if (!blob ||
blob->status() == Error || blob->status() == Complete ||
- status() == Error || status() == Complete || m_isDone ||
+ status() == Error || status() == Complete || m_isDone ||
m_waitingFor.contains(blob))
return;
@@ -469,7 +469,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
@@ -537,7 +537,7 @@ void QQmlDataBlob::networkError(QNetworkReply::NetworkError networkError)
setError(error);
}
-/*!
+/*!
Called if \a blob, which was previously waited for, has an error.
The default implementation does nothing.
@@ -557,9 +557,9 @@ void QQmlDataBlob::dependencyComplete(QQmlDataBlob *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.
*/
@@ -571,9 +571,9 @@ void QQmlDataBlob::allDependenciesDone()
Called when the download progress of this blob changes. \a progress goes
from 0 to 1.
-This callback is only invoked if an asynchronous load for this blob is
+This callback is only invoked if an asynchronous load for this blob is
made. An asynchronous load is one in which the Asynchronous mode is
-specified explicitly, or one that is implicitly delayed due to a network
+specified explicitly, or one that is implicitly delayed due to a network
operation.
The default implementation does nothing.
@@ -587,12 +587,12 @@ void QQmlDataBlob::downloadProgressChanged(qreal progress)
Invoked on the main thread sometime after done() was called on the load thread.
You cannot modify the blobs state at all in this callback and cannot depend on the
-order or timeliness of these callbacks. Implementors should use this callback to notify
+order or timeliness of these callbacks. Implementors should use this callback to notify
dependencies on the main thread that the blob is done and not a lot else.
-This callback is only invoked if an asynchronous load for this blob is
+This callback is only invoked if an asynchronous load for this blob is
made. An asynchronous load is one in which the Asynchronous mode is
-specified explicitly, or one that is implicitly delayed due to a network
+specified explicitly, or one that is implicitly delayed due to a network
operation.
The default implementation does nothing.
@@ -670,7 +670,7 @@ void QQmlDataBlob::notifyComplete(QQmlDataBlob *blob)
blob->release();
- if (!isError() && m_waitingFor.isEmpty())
+ if (!isError() && m_waitingFor.isEmpty())
allDependenciesDone();
m_inCallback = false;
@@ -754,10 +754,10 @@ QQmlDataLoaderNetworkReplyProxy *QQmlDataLoaderThread::networkReplyProxy() const
return m_networkReplyProxy;
}
-void QQmlDataLoaderThread::load(QQmlDataBlob *b)
-{
+void QQmlDataLoaderThread::load(QQmlDataBlob *b)
+{
b->addref();
- callMethodInThread(&This::loadThread, b);
+ callMethodInThread(&This::loadThread, b);
}
void QQmlDataLoaderThread::loadAsync(QQmlDataBlob *b)
@@ -778,19 +778,19 @@ void QQmlDataLoaderThread::loadWithStaticDataAsync(QQmlDataBlob *b, const QByteA
postMethodToThread(&This::loadWithStaticDataThread, b, d);
}
-void QQmlDataLoaderThread::callCompleted(QQmlDataBlob *b)
-{
- b->addref();
- postMethodToMain(&This::callCompletedMain, b);
+void QQmlDataLoaderThread::callCompleted(QQmlDataBlob *b)
+{
+ b->addref();
+ postMethodToMain(&This::callCompletedMain, b);
}
-void QQmlDataLoaderThread::callDownloadProgressChanged(QQmlDataBlob *b, qreal p)
-{
- b->addref();
- postMethodToMain(&This::callDownloadProgressChangedMain, b, p);
+void QQmlDataLoaderThread::callDownloadProgressChanged(QQmlDataBlob *b, qreal p)
+{
+ b->addref();
+ postMethodToMain(&This::callDownloadProgressChangedMain, b, p);
}
-void QQmlDataLoaderThread::initializeEngine(QQmlExtensionInterface *iface,
+void QQmlDataLoaderThread::initializeEngine(QQmlExtensionInterface *iface,
const char *uri)
{
callMethodInMain(&This::initializeEngineMain, iface, uri);
@@ -804,9 +804,9 @@ void QQmlDataLoaderThread::shutdownThread()
m_networkReplyProxy = 0;
}
-void QQmlDataLoaderThread::loadThread(QQmlDataBlob *b)
-{
- m_loader->loadThread(b);
+void QQmlDataLoaderThread::loadThread(QQmlDataBlob *b)
+{
+ m_loader->loadThread(b);
b->release();
}
@@ -816,27 +816,27 @@ void QQmlDataLoaderThread::loadWithStaticDataThread(QQmlDataBlob *b, const QByte
b->release();
}
-void QQmlDataLoaderThread::callCompletedMain(QQmlDataBlob *b)
-{
+void QQmlDataLoaderThread::callCompletedMain(QQmlDataBlob *b)
+{
QML_MEMORY_SCOPE_URL(b->url());
#ifdef DATABLOB_DEBUG
- qWarning("QQmlDataLoaderThread: %s completed() callback", qPrintable(b->url().toString()));
+ qWarning("QQmlDataLoaderThread: %s completed() callback", qPrintable(b->url().toString()));
#endif
- b->completed();
- b->release();
+ b->completed();
+ b->release();
}
-void QQmlDataLoaderThread::callDownloadProgressChangedMain(QQmlDataBlob *b, qreal p)
-{
+void QQmlDataLoaderThread::callDownloadProgressChangedMain(QQmlDataBlob *b, qreal p)
+{
#ifdef DATABLOB_DEBUG
- qWarning("QQmlDataLoaderThread: %s downloadProgressChanged(%f) callback",
- qPrintable(b->url().toString()), p);
+ qWarning("QQmlDataLoaderThread: %s downloadProgressChanged(%f) callback",
+ qPrintable(b->url().toString()), p);
#endif
- b->downloadProgressChanged(p);
- b->release();
+ b->downloadProgressChanged(p);
+ b->release();
}
-void QQmlDataLoaderThread::initializeEngineMain(QQmlExtensionInterface *iface,
+void QQmlDataLoaderThread::initializeEngineMain(QQmlExtensionInterface *iface,
const char *uri)
{
Q_ASSERT(m_loader->engine()->thread() == QThread::currentThread());
@@ -856,7 +856,7 @@ The loader then fetches the data over the network or from the local file system
QQmlDataBlob is an abstract class, so should always be specialized.
Once data is received, the QQmlDataBlob::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 (QQmlDataBlob::setError()), or one or more dependencies being
created (QQmlDataBlob::addDependency()). Dependencies are other QQmlDataBlob's that
are required before processing can fully complete.
@@ -884,7 +884,7 @@ QQmlDataLoader::QQmlDataLoader(QQmlEngine *engine)
/*! \internal */
QQmlDataLoader::~QQmlDataLoader()
{
- 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();
shutdownThread();
@@ -909,7 +909,7 @@ The loader must be locked.
void QQmlDataLoader::load(QQmlDataBlob *blob, Mode mode)
{
#ifdef DATABLOB_DEBUG
- qWarning("QQmlDataLoader::load(%s): %s thread", qPrintable(blob->m_url.toString()),
+ qWarning("QQmlDataLoader::load(%s): %s thread", qPrintable(blob->m_url.toString()),
m_thread->isThisThread()?"Compile":"Engine");
#endif
blob->startLoading(this);
@@ -941,7 +941,7 @@ The loader must be locked.
void QQmlDataLoader::loadWithStaticData(QQmlDataBlob *blob, const QByteArray &data, Mode mode)
{
#ifdef DATABLOB_DEBUG
- qWarning("QQmlDataLoader::loadWithStaticData(%s, data): %s thread", qPrintable(blob->m_url.toString()),
+ qWarning("QQmlDataLoader::loadWithStaticData(%s, data): %s thread", qPrintable(blob->m_url.toString()),
m_thread->isThisThread()?"Compile":"Engine");
#endif
@@ -1118,7 +1118,7 @@ QQmlEngine *QQmlDataLoader::engine() const
Call the initializeEngine() method on \a iface. Used by QQmlImportDatabase to ensure it
gets called in the correct thread.
*/
-void QQmlDataLoader::initializeEngine(QQmlExtensionInterface *iface,
+void QQmlDataLoader::initializeEngine(QQmlExtensionInterface *iface,
const char *uri)
{
Q_ASSERT(m_thread->isThisThread() || engine()->thread() == QThread::currentThread());
@@ -1158,7 +1158,7 @@ void QQmlDataLoader::setData(QQmlDataBlob *blob, const QQmlDataBlob::Data &d)
if (!blob->isError() && !blob->isWaiting())
blob->allDependenciesDone();
- if (blob->status() != QQmlDataBlob::Error)
+ if (blob->status() != QQmlDataBlob::Error)
blob->m_data.setStatus(QQmlDataBlob::WaitingForDependencies);
blob->m_inCallback = false;
@@ -1525,12 +1525,12 @@ Returns a QQmlTypeData for the specified \a url. The QQmlTypeData may be cached
*/
QQmlTypeData *QQmlTypeLoader::getType(const QUrl &url, Mode mode)
{
- Q_ASSERT(!url.isRelative() &&
+ Q_ASSERT(!url.isRelative() &&
(QQmlFile::urlToLocalFileOrQrc(url).isEmpty() ||
!QDir::isRelativePath(QQmlFile::urlToLocalFileOrQrc(url))));
LockHolder<QQmlTypeLoader> holder(this);
-
+
QQmlTypeData *typeData = m_typeCache.value(url);
if (!typeData) {
@@ -1546,7 +1546,7 @@ QQmlTypeData *QQmlTypeLoader::getType(const QUrl &url, Mode mode)
}
/*!
-Returns a QQmlTypeData for the given \a data with the provided base \a url. The
+Returns a QQmlTypeData for the given \a data with the provided base \a url. The
QQmlTypeData will not be cached.
*/
QQmlTypeData *QQmlTypeLoader::getType(const QByteArray &data, const QUrl &url)
@@ -1564,7 +1564,7 @@ Return a QQmlScriptBlob for \a url. The QQmlScriptData may be cached.
*/
QQmlScriptBlob *QQmlTypeLoader::getScript(const QUrl &url)
{
- Q_ASSERT(!url.isRelative() &&
+ Q_ASSERT(!url.isRelative() &&
(QQmlFile::urlToLocalFileOrQrc(url).isEmpty() ||
!QDir::isRelativePath(QQmlFile::urlToLocalFileOrQrc(url))));
@@ -1588,7 +1588,7 @@ Returns a QQmlQmldirData for \a url. The QQmlQmldirData may be cached.
*/
QQmlQmldirData *QQmlTypeLoader::getQmldir(const QUrl &url)
{
- Q_ASSERT(!url.isRelative() &&
+ Q_ASSERT(!url.isRelative() &&
(QQmlFile::urlToLocalFileOrQrc(url).isEmpty() ||
!QDir::isRelativePath(QQmlFile::urlToLocalFileOrQrc(url))));
@@ -1905,7 +1905,7 @@ void QQmlTypeLoader::clearCache()
{
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)
(*iter)->release();
@@ -1971,9 +1971,9 @@ QQmlTypeData::QQmlTypeData(const QUrl &url, QQmlTypeLoader *manager)
QQmlTypeData::~QQmlTypeData()
{
- 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_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();
@@ -2110,7 +2110,7 @@ void QQmlTypeData::done()
}
// Compile component
- if (!isError())
+ if (!isError())
compile();
scriptParser.clear();
diff --git a/src/qml/qml/qqmltypeloader_p.h b/src/qml/qml/qqmltypeloader_p.h
index a022162a7c..976f5a5ffb 100644
--- a/src/qml/qml/qqmltypeloader_p.h
+++ b/src/qml/qml/qqmltypeloader_p.h
@@ -189,7 +189,7 @@ private:
// m_errors should *always* be written before the status is set to Error.
// We use the status change as a memory fence around m_errors so that locking
- // isn't required. Once the status is set to Error (or Complete), m_errors
+ // isn't required. Once the status is set to Error (or Complete), m_errors
// cannot be changed.
QList<QQmlError> m_errors;
@@ -244,7 +244,7 @@ private:
void loadWithStaticDataThread(QQmlDataBlob *, const QByteArray &);
void networkReplyFinished(QNetworkReply *);
void networkReplyProgress(QNetworkReply *, qint64, qint64);
-
+
typedef QHash<QNetworkReply *, QQmlDataBlob *> NetworkReplies;
void setData(QQmlDataBlob *, const QByteArray &);
@@ -491,10 +491,10 @@ private:
bool loadImplicitImport();
};
-// QQmlScriptData instances are created, uninitialized, by the loader in the
+// QQmlScriptData instances are created, uninitialized, by the loader in the
// load thread. The first time they are used by the VME, they are initialized which
// creates their v8 objects and they are referenced and added to the engine's cleanup
-// list. During QQmlCleanup::clear() all v8 resources are destroyed, and the
+// list. During QQmlCleanup::clear() all v8 resources are destroyed, and the
// reference that was created is released but final deletion only occurs once all the
// references as released. This is all intended to ensure that the v8 resources are
// only created and destroyed in the main thread :)
diff --git a/src/qml/qml/qqmltypenamecache.cpp b/src/qml/qml/qqmltypenamecache.cpp
index a880bbdd58..f388972559 100644
--- a/src/qml/qml/qqmltypenamecache.cpp
+++ b/src/qml/qml/qqmltypenamecache.cpp
@@ -99,7 +99,7 @@ QQmlTypeNameCache::Result QQmlTypeNameCache::query(const QHashedStringRef &name)
return result;
}
-QQmlTypeNameCache::Result QQmlTypeNameCache::query(const QHashedStringRef &name,
+QQmlTypeNameCache::Result QQmlTypeNameCache::query(const QHashedStringRef &name,
const void *importNamespace)
{
Q_ASSERT(importNamespace);
diff --git a/src/qml/qml/qqmltypewrapper.cpp b/src/qml/qml/qqmltypewrapper.cpp
index 93ad8dc6fe..573779acab 100644
--- a/src/qml/qml/qqmltypewrapper.cpp
+++ b/src/qml/qml/qqmltypewrapper.cpp
@@ -248,7 +248,7 @@ void QmlTypeWrapper::put(Managed *m, const StringRef name, const ValueRef value)
if (type && !type->isSingleton() && w->object) {
QObject *object = w->object;
QObject *ao = qmlAttachedPropertiesObjectById(type->attachedPropertiesId(), object);
- if (ao)
+ if (ao)
QV4::QObjectWrapper::setQmlProperty(v4->currentContext(), context, ao, name.getPointer(), QV4::QObjectWrapper::IgnoreRevision, value);
} else if (type && type->isSingleton()) {
QQmlEngine *e = v8engine->engine();
diff --git a/src/qml/qml/qqmlvaluetype_p.h b/src/qml/qml/qqmlvaluetype_p.h
index bd44dfb0cf..953ea2154d 100644
--- a/src/qml/qml/qqmlvaluetype_p.h
+++ b/src/qml/qml/qqmlvaluetype_p.h
@@ -247,7 +247,7 @@ public:
qreal y() const;
void setX(qreal);
void setY(qreal);
-
+
qreal width() const;
qreal height() const;
void setWidth(qreal);
@@ -270,7 +270,7 @@ public:
int y() const;
void setX(int);
void setY(int);
-
+
int width() const;
int height() const;
void setWidth(int);
diff --git a/src/qml/qml/qqmlvme.cpp b/src/qml/qml/qqmlvme.cpp
index 115fcc72d2..e60413327a 100644
--- a/src/qml/qml/qqmlvme.cpp
+++ b/src/qml/qml/qqmlvme.cpp
@@ -173,9 +173,9 @@ bool QQmlVME::initDeferred(QObject *object)
}
namespace {
-struct ActiveVMERestorer
+struct ActiveVMERestorer
{
- ActiveVMERestorer(QQmlVME *me, QQmlEnginePrivate *ep)
+ ActiveVMERestorer(QQmlVME *me, QQmlEnginePrivate *ep)
: ep(ep), oldVME(ep->activeVME) { ep->activeVME = me; }
~ActiveVMERestorer() { ep->activeVME = oldVME; }
@@ -202,7 +202,7 @@ QObject *QQmlVME::execute(QList<QQmlError> *errors, const Interrupt &interrupt)
return rv;
}
-inline bool fastHasBinding(QObject *o, int index)
+inline bool fastHasBinding(QObject *o, int index)
{
if (QQmlData *ddata = static_cast<QQmlData *>(QObjectPrivate::get(o)->declarativeData)) {
int coreIndex = index & 0x0000FFFF;
@@ -238,7 +238,7 @@ static QV4::ExecutionContext *qmlBindingContext(QQmlEngine *engine, QV4::Executi
return wrapper->context();
}
-// XXX we probably need some form of "work count" here to prevent us checking this
+// XXX we probably need some form of "work count" here to prevent us checking this
// for every instruction.
#define QML_BEGIN_INSTR_COMMON(I) { \
const QQmlInstructionMeta<(int)QQmlInstruction::I>::DataType &instr = QQmlInstructionMeta<(int)QQmlInstruction::I>::data(*genericInstr); \
@@ -461,7 +461,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
CTXT->imports = COMP->importCache;
CTXT->imports->addref();
CTXT->setParent(parentCtxt);
- if (instr.contextCache != -1)
+ if (instr.contextCache != -1)
CTXT->setIdPropertyData(COMP->contextCaches.at(instr.contextCache));
if (states.count() == 1) {
rootContext = CTXT;
@@ -469,7 +469,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
rootContext->isRootObjectInCreation = true;
}
if (states.count() == 1 && !creationContext.isNull()) {
- // A component that is logically created within another component instance shares the
+ // A component that is logically created within another component instance shares the
// same instances of script imports. For example:
//
// import QtQuick 2.0
@@ -482,7 +482,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
// }
//
// Has the same "Test" instance. To implement this, we simply copy the v8 handles into
- // the inner context. We have to create a fresh persistent handle for each to prevent
+ // the inner context. We have to create a fresh persistent handle for each to prevent
// double dispose. It is possible we could do this more efficiently using some form of
// referencing instead.
CTXT->importedScripts = creationContext->importedScripts;
@@ -630,9 +630,9 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
if (!objects.isEmpty()) {
QObject *parent = objects.at(objects.count() - 1 - (instr.parentToSuper?1:0));
#if 0 // ### refactor
- if (o->isWidgetType() && parent->isWidgetType())
+ if (o->isWidgetType() && parent->isWidgetType())
static_cast<QWidget*>(o)->setParent(static_cast<QWidget*>(parent));
- else
+ else
#endif
QQml_setParent_noEvent(o, parent);
ddata->parentFrozen = true;
@@ -644,7 +644,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
QML_BEGIN_INSTR(CreateSimpleObject)
const QQmlCompiledData::TypeReference &ref = TYPES.at(instr.type);
Q_QML_VME_PROFILE(profiler.start(ref.type->qmlTypeName(), CTXT->url, instr.line, instr.column));
- QObject *o = (QObject *)operator new(instr.typeSize + sizeof(QQmlData));
+ QObject *o = (QObject *)operator new(instr.typeSize + sizeof(QQmlData));
::memset(static_cast<void *>(o), 0, instr.typeSize + sizeof(QQmlData));
instr.create(o);
@@ -656,16 +656,16 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
ddata->lineNumber = instr.line;
ddata->columnNumber = instr.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 = objects.at(objects.count() - 1 - (instr.parentToSuper?1:0));
- QQml_setParent_noEvent(o, parent);
+ QQml_setParent_noEvent(o, parent);
ddata->parentFrozen = true;
objects.push(o);
@@ -682,7 +682,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
QML_END_INSTR(SetDefault)
QML_BEGIN_INSTR(CreateComponent)
- QQmlComponent *qcomp =
+ QQmlComponent *qcomp =
new QQmlComponent(CTXT->engine, COMP, INSTRUCTIONSTREAM - COMP->bytecode.constData(),
objects.isEmpty() ? 0 : objects.top());
@@ -717,7 +717,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
QQmlPropertyCache *propertyCache = PROPERTYCACHES.at(instr.propertyCache);
- const QQmlVMEMetaData *data =
+ const QQmlVMEMetaData *data =
(const QQmlVMEMetaData *)DATAS.at(instr.aliasData).constData();
QV4::ExecutionContext *qmlContext = qmlBindingContext(engine, QV8Engine::getV4(engine), qmlBindingWrappers, CTXT, target, objects.count() - 1);
@@ -739,13 +739,13 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
QQmlMetaType::StringConverter converter = QQmlMetaType::customStringConverter(type);
QVariant v = (*converter)(primitive);
- QMetaProperty prop =
+ QMetaProperty prop =
target->metaObject()->property(instr.propertyIndex);
- if (v.isNull() || ((int)prop.type() != type && prop.userType() != type))
+ if (v.isNull() || ((int)prop.type() != type && prop.userType() != type))
VME_EXCEPTION(tr("Cannot assign value %1 to property %2").arg(primitive).arg(QString::fromUtf8(prop.name())), instr.line);
void *a[] = { (void *)v.data(), 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.propertyIndex, a);
QML_END_INSTR(AssignCustomType)
@@ -818,7 +818,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
ss.d.data()->numberValue = instr.numberValue;
void *a[] = { &ss, 0, &status, &flags };
- QMetaObject::metacall(target, QMetaObject::WriteProperty,
+ QMetaObject::metacall(target, QMetaObject::WriteProperty,
instr.propertyIndex, a);
QML_END_INSTR(StoreScriptString)
@@ -837,9 +837,9 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
QML_END_INSTR(BeginObject)
QML_BEGIN_INSTR(StoreBinding)
- QObject *target =
+ QObject *target =
objects.at(objects.count() - 1 - instr.owner);
- QObject *context =
+ QObject *context =
objects.at(objects.count() - 1 - instr.context);
if (instr.isRoot && BINDINGSKIPLIST.testBit(instr.property.coreIndex))
@@ -885,7 +885,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
QObject *obj = objects.pop();
QQmlPropertyValueInterceptor *vi = reinterpret_cast<QQmlPropertyValueInterceptor *>(reinterpret_cast<char *>(obj) + instr.castValue);
QObject *target = obj->parent();
- QQmlProperty prop =
+ QQmlProperty prop =
QQmlPropertyPrivate::restore(target, instr.property, CTXT);
vi->setTarget(prop);
QQmlVMEMetaObject *mo = QQmlVMEMetaObject::get(target);
@@ -913,9 +913,9 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
void *ptr = 0;
const char *iid = QQmlMetaType::interfaceIId(type);
- if (iid)
+ if (iid)
ptr = assign->qt_metacast(iid);
- if (!ptr)
+ if (!ptr)
VME_EXCEPTION(tr("Cannot assign object to list"), instr.line);
if (list.qListProperty.append)
@@ -938,17 +938,17 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
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(tr("Cannot assign object to interface property"), instr.line);
QML_END_INSTR(StoreInterface)
-
+
QML_BEGIN_INSTR(FetchAttached)
QObject *target = objects.top();
@@ -968,7 +968,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
void *a[1];
a[0] = (void *)&(lists.top().qListProperty);
- QMetaObject::metacall(target, QMetaObject::ReadProperty,
+ QMetaObject::metacall(target, QMetaObject::ReadProperty,
instr.property, a);
QML_END_INSTR(FetchQList)
@@ -976,11 +976,11 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
QObject *target = objects.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.property, a);
if (!obj)
@@ -1026,14 +1026,14 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
// Possibly need to clear bindings
QQmlData *targetData = QQmlData::get(target);
if (targetData) {
- QQmlAbstractBinding *binding =
+ QQmlAbstractBinding *binding =
QQmlPropertyPrivate::binding(target, instr.property, -1);
if (binding && binding->bindingType() != QQmlAbstractBinding::ValueTypeProxy) {
QQmlPropertyPrivate::setBinding(target, instr.property, -1, 0);
binding->destroy();
} else if (binding) {
- QQmlValueTypeProxyBinding *proxy =
+ QQmlValueTypeProxyBinding *proxy =
static_cast<QQmlValueTypeProxyBinding *>(binding);
proxy->removeBindings(instr.bindingSkipList);
}
@@ -1048,7 +1048,7 @@ QObject *QQmlVME::run(QList<QQmlError> *errors,
QML_END_INSTR(FetchValueType)
QML_BEGIN_INSTR(PopValueType)
- QQmlValueType *valueHandler =
+ QQmlValueType *valueHandler =
static_cast<QQmlValueType *>(objects.pop());
QObject *target = objects.top();
valueHandler->write(target, instr.property, QQmlPropertyPrivate::BypassInterceptor);
@@ -1093,9 +1093,9 @@ void QQmlVME::reset()
QRecursionWatcher<QQmlVME, &QQmlVME::recursion> watcher(this);
if (!objects.isEmpty() && !(states.at(0).flags & State::Deferred))
- delete objects.at(0);
-
- if (!rootContext.isNull())
+ delete objects.at(0);
+
+ if (!rootContext.isNull())
rootContext->activeVMEData = 0;
// Remove the QQmlParserStatus and QQmlAbstractBinding back pointers
@@ -1106,7 +1106,7 @@ void QQmlVME::reset()
QQmlComponentAttached *a = componentAttached;
a->rem();
}
-
+
engine = 0;
objects.deallocate();
lists.deallocate();
@@ -1293,7 +1293,7 @@ QQmlVMEGuard::~QQmlVMEGuard()
void QQmlVMEGuard::guard(QQmlVME *vme)
{
clear();
-
+
m_objectCount = vme->objects.count();
m_objects = new QPointer<QObject>[m_objectCount];
for (int ii = 0; ii < m_objectCount; ++ii)
@@ -1301,7 +1301,7 @@ void QQmlVMEGuard::guard(QQmlVME *vme)
m_contextCount = (vme->rootContext.isNull()?0:1) + vme->states.count();
m_contexts = new QQmlGuardedContextData[m_contextCount];
- for (int ii = 0; ii < vme->states.count(); ++ii)
+ for (int ii = 0; ii < vme->states.count(); ++ii)
m_contexts[ii] = vme->states.at(ii).context;
if (!vme->rootContext.isNull())
m_contexts[m_contextCount - 1] = vme->rootContext.contextData();
diff --git a/src/qml/qml/qqmlvme_p.h b/src/qml/qml/qqmlvme_p.h
index d5afd4c67a..d26812a68f 100644
--- a/src/qml/qml/qqmlvme_p.h
+++ b/src/qml/qml/qqmlvme_p.h
@@ -187,7 +187,7 @@ private:
};
// Used to check that a QQmlVME that is interrupted mid-execution
-// is still valid. Checks all the objects and contexts have not been
+// is still valid. Checks all the objects and contexts have not been
// deleted.
class QQmlVMEGuard
{
diff --git a/src/qml/qml/qqmlvmemetaobject.cpp b/src/qml/qml/qqmlvmemetaobject.cpp
index ebe72b2ff6..0b966484ca 100644
--- a/src/qml/qml/qqmlvmemetaobject.cpp
+++ b/src/qml/qml/qqmlvmemetaobject.cpp
@@ -224,7 +224,7 @@ const void *QQmlVMEVariant::dataPtr() const
return &data;
}
-void *QQmlVMEVariant::dataPtr()
+void *QQmlVMEVariant::dataPtr()
{
return &data;
}
@@ -234,7 +234,7 @@ size_t QQmlVMEVariant::dataSize() const
return sizeof(data);
}
-QObject *QQmlVMEVariant::asQObject()
+QObject *QQmlVMEVariant::asQObject()
{
if (type != QMetaType::QObjectStar)
setValue((QObject *)0, 0, -1);
@@ -242,7 +242,7 @@ QObject *QQmlVMEVariant::asQObject()
return *(QQmlGuard<QObject> *)(dataPtr());
}
-const QVariant &QQmlVMEVariant::asQVariant()
+const QVariant &QQmlVMEVariant::asQVariant()
{
if (type != QMetaType::QVariant)
setValue(QVariant());
@@ -250,7 +250,7 @@ const QVariant &QQmlVMEVariant::asQVariant()
return *(QVariant *)(dataPtr());
}
-int QQmlVMEVariant::asInt()
+int QQmlVMEVariant::asInt()
{
if (type != QMetaType::Int)
setValue(int(0));
@@ -258,7 +258,7 @@ int QQmlVMEVariant::asInt()
return *(int *)(dataPtr());
}
-bool QQmlVMEVariant::asBool()
+bool QQmlVMEVariant::asBool()
{
if (type != QMetaType::Bool)
setValue(bool(false));
@@ -266,7 +266,7 @@ bool QQmlVMEVariant::asBool()
return *(bool *)(dataPtr());
}
-double QQmlVMEVariant::asDouble()
+double QQmlVMEVariant::asDouble()
{
if (type != QMetaType::Double)
setValue(double(0));
@@ -274,7 +274,7 @@ double QQmlVMEVariant::asDouble()
return *(double *)(dataPtr());
}
-const QString &QQmlVMEVariant::asQString()
+const QString &QQmlVMEVariant::asQString()
{
if (type != QMetaType::QString)
setValue(QString());
@@ -282,7 +282,7 @@ const QString &QQmlVMEVariant::asQString()
return *(QString *)(dataPtr());
}
-const QUrl &QQmlVMEVariant::asQUrl()
+const QUrl &QQmlVMEVariant::asQUrl()
{
if (type != QMetaType::QUrl)
setValue(QUrl());
@@ -290,7 +290,7 @@ const QUrl &QQmlVMEVariant::asQUrl()
return *(QUrl *)(dataPtr());
}
-const QTime &QQmlVMEVariant::asQTime()
+const QTime &QQmlVMEVariant::asQTime()
{
if (type != QMetaType::QTime)
setValue(QTime());
@@ -298,7 +298,7 @@ const QTime &QQmlVMEVariant::asQTime()
return *(QTime *)(dataPtr());
}
-const QDate &QQmlVMEVariant::asQDate()
+const QDate &QQmlVMEVariant::asQDate()
{
if (type != QMetaType::QDate)
setValue(QDate());
@@ -306,7 +306,7 @@ const QDate &QQmlVMEVariant::asQDate()
return *(QDate *)(dataPtr());
}
-const QDateTime &QQmlVMEVariant::asQDateTime()
+const QDateTime &QQmlVMEVariant::asQDateTime()
{
if (type != QMetaType::QDateTime)
setValue(QDateTime());
@@ -779,9 +779,9 @@ int QQmlVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
if (t == qMetaTypeId<QQmlListProperty<QObject> >()) {
int listIndex = data[id].asInt();
const List *list = &listProperties.at(listIndex);
- *reinterpret_cast<QQmlListProperty<QObject> *>(a[0]) =
+ *reinterpret_cast<QQmlListProperty<QObject> *>(a[0]) =
QQmlListProperty<QObject>(object, (void *)list,
- list_append, list_count, list_at,
+ list_append, list_count, list_at,
list_clear);
}
@@ -858,7 +858,7 @@ int QQmlVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
QQmlVMEMetaData::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;
@@ -867,7 +867,7 @@ int QQmlVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
QQmlContextPrivate *ctxtPriv = QQmlContextPrivate::get(context);
QObject *target = ctxtPriv->data->idValues[d->contextIdx].data();
- if (!target)
+ if (!target)
return -1;
connectAlias(id);
@@ -875,8 +875,8 @@ int QQmlVMEMetaObject::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]);
@@ -888,7 +888,7 @@ int QQmlVMEMetaObject::metaCall(QMetaObject::Call c, int _id, void **a)
}
}
}
-
+
if (d->isValueTypeAlias()) {
// Value type property
QQmlValueType *valueType = QQmlValueTypeFactory::valueType(d->valueType());
@@ -896,7 +896,7 @@ int QQmlVMEMetaObject::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);
@@ -987,7 +987,7 @@ QV4::ReturnedValue QQmlVMEMetaObject::method(int index)
return QV4::Primitive::undefinedValue().asReturnedValue();
}
- if (!v8methods)
+ if (!v8methods)
v8methods = new QV4::PersistentValue[metaData->methodCount];
return v8methods[index].value();
@@ -1186,7 +1186,7 @@ void QQmlVMEMetaObject::setVmeMethod(int index, QV4::ValueRef function)
int plainSignals = metaData->signalCount + metaData->propertyCount + metaData->aliasCount;
Q_ASSERT(index >= (methodOffset() + plainSignals) && index < (methodOffset() + plainSignals + metaData->methodCount));
- if (!v8methods)
+ if (!v8methods)
v8methods = new QV4::PersistentValue[metaData->methodCount];
int methodIndex = index - methodOffset() - plainSignals;
diff --git a/src/qml/qml/qqmlvmemetaobject_p.h b/src/qml/qml/qqmlvmemetaobject_p.h
index a9a0308ded..77db107668 100644
--- a/src/qml/qml/qqmlvmemetaobject_p.h
+++ b/src/qml/qml/qqmlvmemetaobject_p.h
@@ -113,7 +113,7 @@ struct QQmlVMEMetaData
return (propertyIdx & 0xFFFF0000) ? propType : 0;
}
};
-
+
struct PropertyData {
int propertyType;
};
diff --git a/src/qml/qml/qqmlxmlhttprequest.cpp b/src/qml/qml/qqmlxmlhttprequest.cpp
index 79428ca4a8..e2cdac16c0 100644
--- a/src/qml/qml/qqmlxmlhttprequest.cpp
+++ b/src/qml/qml/qqmlxmlhttprequest.cpp
@@ -122,11 +122,11 @@ QQmlXMLHttpRequestData::~QQmlXMLHttpRequestData()
namespace {
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)
@@ -134,18 +134,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;
@@ -407,7 +407,7 @@ public:
}
-void NodeImpl::addref()
+void NodeImpl::addref()
{
document->addref();
}
@@ -826,7 +826,7 @@ ReturnedValue Document::load(QV8Engine *engine, const QByteArray &data)
break;
case QXmlStreamReader::EndDocument:
break;
- case QXmlStreamReader::StartElement:
+ case QXmlStreamReader::StartElement:
{
Q_ASSERT(document);
NodeImpl *node = new NodeImpl;
@@ -851,7 +851,7 @@ ReturnedValue Document::load(QV8Engine *engine, const QByteArray &data)
attr->parent = node;
node->attributes.append(attr);
}
- }
+ }
break;
case QXmlStreamReader::EndElement:
nodeStack.pop();
@@ -1045,7 +1045,7 @@ class QQmlXMLHttpRequest : public QObject
{
Q_OBJECT
public:
- enum State { Unsent = 0,
+ enum State { Unsent = 0,
Opened = 1, HeadersReceived = 2,
Loading = 3, Done = 4 };
@@ -1250,7 +1250,7 @@ void QQmlXMLHttpRequest::requestFromUrl(const QUrl &url)
}
request.setHeader(QNetworkRequest::ContentTypeHeader, str);
} else {
- request.setHeader(QNetworkRequest::ContentTypeHeader,
+ request.setHeader(QNetworkRequest::ContentTypeHeader,
QLatin1String("text/plain;charset=UTF-8"));
}
}
@@ -1258,7 +1258,7 @@ void QQmlXMLHttpRequest::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));
}
}
@@ -1303,7 +1303,7 @@ ReturnedValue QQmlXMLHttpRequest::abort(const ValueRef me)
m_errorFlag = true;
m_request = QNetworkRequest();
- if (!(m_state == Unsent ||
+ if (!(m_state == Unsent ||
(m_state == Opened && !m_sendFlag) ||
m_state == Done)) {
@@ -1329,7 +1329,7 @@ void QQmlXMLHttpRequest::setMe(const ValueRef me)
void QQmlXMLHttpRequest::readyRead()
{
- m_status =
+ m_status =
m_network->attribute(QNetworkRequest::HttpStatusCodeAttribute).toInt();
m_statusText =
QString::fromUtf8(m_network->attribute(QNetworkRequest::HttpReasonPhraseAttribute).toByteArray());
@@ -1394,7 +1394,7 @@ void QQmlXMLHttpRequest::error(QNetworkReply::NetworkError error)
} else {
m_errorFlag = true;
m_responseEntityBody = QByteArray();
- }
+ }
m_state = Done;
@@ -1438,7 +1438,7 @@ void QQmlXMLHttpRequest::finished()
if (xhrDump()) {
qWarning().nospace() << "XMLHttpRequest: RESPONSE " << qPrintable(m_url.toString());
if (!m_responseEntityBody.isEmpty()) {
- qWarning().nospace() << " "
+ qWarning().nospace() << " "
<< qPrintable(QString::fromUtf8(m_responseEntityBody));
}
}
@@ -1479,7 +1479,7 @@ void QQmlXMLHttpRequest::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;
}
@@ -1494,7 +1494,7 @@ QTextCodec* QQmlXMLHttpRequest::findTextCodec() const
{
QTextCodec *codec = 0;
- if (!m_charset.isEmpty())
+ if (!m_charset.isEmpty())
codec = QTextCodec::codecForName(m_charset);
if (!codec && m_gotXml) {
@@ -1503,7 +1503,7 @@ QTextCodec* QQmlXMLHttpRequest::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)
@@ -1737,7 +1737,7 @@ ReturnedValue QQmlXMLHttpRequestCtor::method_open(CallContext *ctx)
// Argument 0 - Method
QString method = ctx->callData->args[0].toQStringNoThrow().toUpper();
- if (method != QLatin1String("GET") &&
+ if (method != QLatin1String("GET") &&
method != QLatin1String("PUT") &&
method != QLatin1String("HEAD") &&
method != QLatin1String("POST") &&
@@ -1747,7 +1747,7 @@ ReturnedValue QQmlXMLHttpRequestCtor::method_open(CallContext *ctx)
// Argument 1 - URL
QUrl url = QUrl(ctx->callData->args[1].toQStringNoThrow());
- if (url.isRelative())
+ if (url.isRelative())
url = engine->callingContext()->resolvedUrl(url);
// Argument 2 - async (optional)
@@ -1811,7 +1811,7 @@ ReturnedValue QQmlXMLHttpRequestCtor::method_setRequestHeader(CallContext *ctx)
nameUpper == QLatin1String("USER-AGENT") ||
nameUpper == QLatin1String("VIA") ||
nameUpper.startsWith(QLatin1String("PROXY-")) ||
- nameUpper.startsWith(QLatin1String("SEC-")))
+ nameUpper.startsWith(QLatin1String("SEC-")))
return Encode::undefined();
r->addHeader(name, value);
@@ -1958,7 +1958,7 @@ ReturnedValue QQmlXMLHttpRequestCtor::method_get_responseText(CallContext *ctx)
if (r->readyState() != QQmlXMLHttpRequest::Loading &&
r->readyState() != QQmlXMLHttpRequest::Done)
return engine->toString(QString());
- else
+ else
return engine->toString(r->responseBody());
}
diff --git a/src/qml/qml/v8/qv8engine_p.h b/src/qml/qml/v8/qv8engine_p.h
index 5d1005b479..e390ef56dd 100644
--- a/src/qml/qml/v8/qv8engine_p.h
+++ b/src/qml/qml/v8/qv8engine_p.h
@@ -117,7 +117,7 @@ namespace QV4 {
// ...
// Q_INVOKABLE void myMethod(QQmlV8Function*);
// };
-// The QQmlV8Function - and consequently the arguments and return value - only remains
+// The QQmlV8Function - and consequently the arguments and return value - only remains
// valid during the call. If the return value isn't set within myMethod(), the will return
// undefined.
class QV8Engine;
diff --git a/src/qml/types/qquickworkerscript.cpp b/src/qml/types/qquickworkerscript.cpp
index 53e45e2003..5af33a34f8 100644
--- a/src/qml/types/qquickworkerscript.cpp
+++ b/src/qml/types/qquickworkerscript.cpp
@@ -195,15 +195,15 @@ private:
void reportScriptException(WorkerScript *, const QQmlError &error);
};
-QQuickWorkerScriptEnginePrivate::WorkerEngine::WorkerEngine(QQuickWorkerScriptEnginePrivate *parent)
+QQuickWorkerScriptEnginePrivate::WorkerEngine::WorkerEngine(QQuickWorkerScriptEnginePrivate *parent)
: QV8Engine(0), p(parent), accessManager(0)
{
m_v4Engine->v8Engine = this;
}
-QQuickWorkerScriptEnginePrivate::WorkerEngine::~WorkerEngine()
-{
- delete accessManager;
+QQuickWorkerScriptEnginePrivate::WorkerEngine::~WorkerEngine()
+{
+ delete accessManager;
}
void QQuickWorkerScriptEnginePrivate::WorkerEngine::init()
@@ -264,7 +264,7 @@ QV4::ReturnedValue QQuickWorkerScriptEnginePrivate::WorkerEngine::sendFunction(i
return v.asReturnedValue();
}
-QNetworkAccessManager *QQuickWorkerScriptEnginePrivate::WorkerEngine::networkAccessManager()
+QNetworkAccessManager *QQuickWorkerScriptEnginePrivate::WorkerEngine::networkAccessManager()
{
if (!accessManager) {
if (p->qmlengine && p->qmlengine->networkAccessManagerFactory()) {
@@ -411,7 +411,7 @@ void QQuickWorkerScriptEnginePrivate::processLoad(int id, const QUrl &url)
}
}
-void QQuickWorkerScriptEnginePrivate::reportScriptException(WorkerScript *script,
+void QQuickWorkerScriptEnginePrivate::reportScriptException(WorkerScript *script,
const QQmlError &error)
{
QQuickWorkerScriptEnginePrivate *p = QQuickWorkerScriptEnginePrivate::get(workerEngine);
diff --git a/src/quick/doc/snippets/qml/animatedimage.qml b/src/quick/doc/snippets/qml/animatedimage.qml
index d2f778e030..f6e8d027ea 100644
--- a/src/quick/doc/snippets/qml/animatedimage.qml
+++ b/src/quick/doc/snippets/qml/animatedimage.qml
@@ -49,7 +49,7 @@ Rectangle {
AnimatedImage { id: animation; source: "animation.gif" }
- Rectangle {
+ Rectangle {
property int frames: animation.frameCount
width: 4; height: 8
diff --git a/src/quick/doc/snippets/qml/listview/listview.qml b/src/quick/doc/snippets/qml/listview/listview.qml
index 41c7f78fbe..868ba4dfc1 100644
--- a/src/quick/doc/snippets/qml/listview/listview.qml
+++ b/src/quick/doc/snippets/qml/listview/listview.qml
@@ -141,7 +141,7 @@ ListView {
}
model: ContactModel {}
- delegate: contactsDelegate
+ delegate: contactsDelegate
focus: true
}
//![isCurrentItem]
diff --git a/src/quick/doc/snippets/qml/loader/connections.qml b/src/quick/doc/snippets/qml/loader/connections.qml
index cc63fad40d..a433f4a40e 100644
--- a/src/quick/doc/snippets/qml/loader/connections.qml
+++ b/src/quick/doc/snippets/qml/loader/connections.qml
@@ -49,7 +49,7 @@ Item {
source: "MyItem.qml"
}
- Connections {
+ Connections {
target: myLoader.item
onMessage: console.log(msg)
}
diff --git a/src/quick/doc/snippets/qml/loader/simple.qml b/src/quick/doc/snippets/qml/loader/simple.qml
index 4a68a3ce53..e9a1940ac6 100644
--- a/src/quick/doc/snippets/qml/loader/simple.qml
+++ b/src/quick/doc/snippets/qml/loader/simple.qml
@@ -46,7 +46,7 @@ Item {
Loader { id: pageLoader }
- MouseArea {
+ MouseArea {
anchors.fill: parent
onClicked: pageLoader.source = "Page1.qml"
}
diff --git a/src/quick/doc/snippets/qml/parentanimation.qml b/src/quick/doc/snippets/qml/parentanimation.qml
index c5077ba000..6652030e15 100644
--- a/src/quick/doc/snippets/qml/parentanimation.qml
+++ b/src/quick/doc/snippets/qml/parentanimation.qml
@@ -43,13 +43,13 @@ import QtQuick 2.0
Item {
width: 200; height: 100
- Rectangle {
+ Rectangle {
id: redRect
width: 100; height: 100
color: "red"
}
- Rectangle {
+ Rectangle {
id: blueRect
x: redRect.width
width: 50; height: 50
diff --git a/src/quick/doc/snippets/qml/parentchange.qml b/src/quick/doc/snippets/qml/parentchange.qml
index 777fa225eb..4f1fb2a286 100644
--- a/src/quick/doc/snippets/qml/parentchange.qml
+++ b/src/quick/doc/snippets/qml/parentchange.qml
@@ -43,13 +43,13 @@ import QtQuick 2.0
Item {
width: 200; height: 100
- Rectangle {
+ Rectangle {
id: redRect
width: 100; height: 100
color: "red"
}
- Rectangle {
+ Rectangle {
id: blueRect
x: redRect.width
width: 50; height: 50
diff --git a/src/quick/doc/snippets/qml/propertyanimation.qml b/src/quick/doc/snippets/qml/propertyanimation.qml
index 4d7140d406..db589bbc21 100644
--- a/src/quick/doc/snippets/qml/propertyanimation.qml
+++ b/src/quick/doc/snippets/qml/propertyanimation.qml
@@ -55,8 +55,8 @@ Rectangle {
}
//! [single state]
- transitions: Transition {
- PropertyAnimation { properties: "x,y"; easing.type: Easing.InOutQuad }
+ transitions: Transition {
+ PropertyAnimation { properties: "x,y"; easing.type: Easing.InOutQuad }
}
}
//![transition]
diff --git a/src/quick/doc/snippets/qml/propertychanges.qml b/src/quick/doc/snippets/qml/propertychanges.qml
index b49b9df2eb..f9f1b807e0 100644
--- a/src/quick/doc/snippets/qml/propertychanges.qml
+++ b/src/quick/doc/snippets/qml/propertychanges.qml
@@ -53,9 +53,9 @@ Item {
width: 100; height: 100
color: "red"
- MouseArea {
+ MouseArea {
id: mouseArea
- anchors.fill: parent
+ anchors.fill: parent
}
states: State {
diff --git a/src/quick/doc/snippets/qml/repeaters/repeater.qml b/src/quick/doc/snippets/qml/repeaters/repeater.qml
index 704bea6bee..3afc8c67c2 100644
--- a/src/quick/doc/snippets/qml/repeaters/repeater.qml
+++ b/src/quick/doc/snippets/qml/repeaters/repeater.qml
@@ -48,7 +48,7 @@ Row {
Row {
Repeater {
model: 3
- Rectangle {
+ Rectangle {
width: 100; height: 40
border.width: 1
color: "yellow"
@@ -60,7 +60,7 @@ Row {
//! [index]
Column {
Repeater {
- model: 10
+ model: 10
Text { text: "I'm item " + index }
}
}
@@ -79,7 +79,7 @@ Column {
Row {
Rectangle { width: 10; height: 20; color: "red" }
Repeater {
- model: 10
+ model: 10
Rectangle { width: 20; height: 20; radius: 10; color: "green" }
}
Rectangle { width: 10; height: 20; color: "blue" }
diff --git a/src/quick/doc/snippets/qml/rotationanimation.qml b/src/quick/doc/snippets/qml/rotationanimation.qml
index 3924332f86..677c798ce9 100644
--- a/src/quick/doc/snippets/qml/rotationanimation.qml
+++ b/src/quick/doc/snippets/qml/rotationanimation.qml
@@ -50,9 +50,9 @@ Item {
color: "red"
antialiasing: true
- states: State {
+ states: State {
name: "rotated"
- PropertyChanges { target: rect; rotation: 180 }
+ PropertyChanges { target: rect; rotation: 180 }
}
transitions: Transition {
diff --git a/src/quick/doc/snippets/qml/row.qml b/src/quick/doc/snippets/qml/row.qml
index ad8a21326b..88f24c9140 100644
--- a/src/quick/doc/snippets/qml/row.qml
+++ b/src/quick/doc/snippets/qml/row.qml
@@ -48,7 +48,7 @@ Rectangle {
Row {
anchors.horizontalCenter: parent.horizontalCenter
anchors.verticalCenter: parent.verticalCenter
-
+
spacing: 5
Rectangle { width: 100; height: 100; radius: 20.0
diff --git a/src/quick/doc/snippets/qml/state.qml b/src/quick/doc/snippets/qml/state.qml
index 03475c49ab..09afde4b6f 100644
--- a/src/quick/doc/snippets/qml/state.qml
+++ b/src/quick/doc/snippets/qml/state.qml
@@ -45,9 +45,9 @@ Rectangle {
width: 100; height: 100
color: "black"
- MouseArea {
+ MouseArea {
id: mouseArea
- anchors.fill: parent
+ anchors.fill: parent
onClicked: myRect.state == 'clicked' ? myRect.state = "" : myRect.state = 'clicked';
}
diff --git a/src/quick/doc/snippets/qml/transition-from-to.qml b/src/quick/doc/snippets/qml/transition-from-to.qml
index 415ab4f41f..7afc097eef 100644
--- a/src/quick/doc/snippets/qml/transition-from-to.qml
+++ b/src/quick/doc/snippets/qml/transition-from-to.qml
@@ -52,7 +52,7 @@ Rectangle {
PropertyChanges { target: rect; color: "yellow" }
}
- transitions: Transition {
+ transitions: Transition {
ColorAnimation { duration: 1000 }
}
}
diff --git a/src/quick/doc/snippets/qml/transition-reversible.qml b/src/quick/doc/snippets/qml/transition-reversible.qml
index 03848a37fa..1bb5a0bc5b 100644
--- a/src/quick/doc/snippets/qml/transition-reversible.qml
+++ b/src/quick/doc/snippets/qml/transition-reversible.qml
@@ -54,7 +54,7 @@ Rectangle {
}
//! [sequential animations]
- transitions: Transition {
+ transitions: Transition {
SequentialAnimation {
PropertyAnimation { property: "x"; duration: 1000 }
ColorAnimation { duration: 1000 }
diff --git a/src/quick/doc/snippets/qml/transition.qml b/src/quick/doc/snippets/qml/transition.qml
index a4189074fa..421149764c 100644
--- a/src/quick/doc/snippets/qml/transition.qml
+++ b/src/quick/doc/snippets/qml/transition.qml
@@ -55,8 +55,8 @@ Rectangle {
PropertyChanges { target: rect; x: 50; y: 50 }
}
- transitions: Transition {
- NumberAnimation { properties: "x,y"; easing.type: Easing.InOutQuad }
+ transitions: Transition {
+ NumberAnimation { properties: "x,y"; easing.type: Easing.InOutQuad }
}
}
//![0]
diff --git a/src/quick/util/qquickimageprovider.cpp b/src/quick/util/qquickimageprovider.cpp
index 450238bd41..16c18d2594 100644
--- a/src/quick/util/qquickimageprovider.cpp
+++ b/src/quick/util/qquickimageprovider.cpp
@@ -147,8 +147,8 @@ QImage QQuickTextureFactory::image() const
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 QQmlEngine::addImageProvider().
@@ -173,11 +173,11 @@ QImage QQuickTextureFactory::image() const
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 imageprovider/imageprovider.cpp 0
@@ -188,7 +188,7 @@ QImage QQuickTextureFactory::image() const
with a "colors" identifier:
\code
- int main(int argc, char *argv[])
+ int main(int argc, char *argv[])
{
...
@@ -203,7 +203,7 @@ QImage QQuickTextureFactory::image() const
\image imageprovider.png
- A complete example is available in Qt's
+ A complete example is available in Qt's
\l {qml/imageprovider}{examples/quick/imageprovider}
directory. Note the example registers the provider via a \l{QQmlExtensionPlugin}{plugin}
instead of registering it in the application \c main() function as shown above.
@@ -214,7 +214,7 @@ QImage QQuickTextureFactory::image() const
Image providers that support QImage or Texture 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.
@@ -285,7 +285,7 @@ QQuickImageProvider::Flags QQuickImageProvider::flags() const
}
/*!
- 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/quick/util/qquickpixmapcache.cpp b/src/quick/util/qquickpixmapcache.cpp
index af66ef26a4..3bff2bb890 100644
--- a/src/quick/util/qquickpixmapcache.cpp
+++ b/src/quick/util/qquickpixmapcache.cpp
@@ -234,7 +234,7 @@ class QQuickPixmapData
{
public:
QQuickPixmapData(QQuickPixmap *pixmap, const QUrl &u, const QSize &s, const QString &e)
- : refCount(1), inCache(false), pixmapStatus(QQuickPixmap::Error),
+ : refCount(1), inCache(false), pixmapStatus(QQuickPixmap::Error),
url(u), errorString(e), requestSize(s), textureFactory(0), reply(0), prevUnreferenced(0),
prevUnreferencedPtr(0), nextUnreferenced(0)
{
@@ -242,7 +242,7 @@ public:
}
QQuickPixmapData(QQuickPixmap *pixmap, const QUrl &u, const QSize &r)
- : refCount(1), inCache(false), pixmapStatus(QQuickPixmap::Loading),
+ : refCount(1), inCache(false), pixmapStatus(QQuickPixmap::Loading),
url(u), requestSize(r), textureFactory(0), reply(0), prevUnreferenced(0), prevUnreferencedPtr(0),
nextUnreferenced(0)
{
@@ -286,7 +286,7 @@ public:
uint refCount;
bool inCache:1;
-
+
QQuickPixmap::Status pixmapStatus;
QUrl url;
QString errorString;
@@ -337,7 +337,7 @@ QNetworkAccessManager *QQuickPixmapReader::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);
@@ -469,17 +469,17 @@ QQuickPixmapReaderThreadObject::QQuickPixmapReaderThreadObject(QQuickPixmapReade
{
}
-void QQuickPixmapReaderThreadObject::processJobs()
-{
- QCoreApplication::postEvent(this, new QEvent(QEvent::User));
+void QQuickPixmapReaderThreadObject::processJobs()
+{
+ QCoreApplication::postEvent(this, new QEvent(QEvent::User));
}
-bool QQuickPixmapReaderThreadObject::event(QEvent *e)
+bool QQuickPixmapReaderThreadObject::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);
}
}
@@ -495,7 +495,7 @@ void QQuickPixmapReader::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
@@ -529,7 +529,7 @@ void QQuickPixmapReader::processJobs()
}
}
-void QQuickPixmapReader::processJob(QQuickPixmapReply *runningJob, const QUrl &url,
+void QQuickPixmapReader::processJob(QQuickPixmapReply *runningJob, const QUrl &url,
const QSize &requestSize)
{
// fetch
@@ -649,7 +649,7 @@ QQuickPixmapReply *QQuickPixmapReader::getImage(QQuickPixmapData *data)
QQuickPixmapReply *reply = new QQuickPixmapReply(data);
reply->engineForReader = engine;
jobs.append(reply);
- // XXX
+ // XXX
if (threadObject) threadObject->processJobs();
mutex.unlock();
return reply;
@@ -661,7 +661,7 @@ void QQuickPixmapReader::cancel(QQuickPixmapReply *reply)
if (reply->loading) {
cancelled.append(reply);
reply->data = 0;
- // XXX
+ // XXX
if (threadObject) threadObject->processJobs();
} else {
jobs.removeAll(reply);
@@ -816,7 +816,7 @@ void QQuickPixmapStore::referencePixmap(QQuickPixmapData *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;
}
@@ -927,7 +927,7 @@ void QQuickPixmapData::addref()
{
++refCount;
Q_QML_PROFILE(pixmapCountChanged<QQmlProfilerService::PixmapReferenceCountChanged>(url, refCount));
- if (prevUnreferencedPtr)
+ if (prevUnreferencedPtr)
pixmapStore()->referencePixmap(this);
}
@@ -1029,7 +1029,7 @@ static QQuickPixmapData* createPixmapDataSync(QQuickPixmap *declarativePixmap, Q
}
QString localFile = QQmlFile::urlToLocalFileOrQrc(url);
- if (localFile.isEmpty())
+ if (localFile.isEmpty())
return 0;
QFile f(localFile);
@@ -1130,7 +1130,7 @@ const QUrl &QQuickPixmap::url() const
const QSize &QQuickPixmap::implicitSize() const
{
- if (d)
+ if (d)
return d->implicitSize;
else
return nullPixmap()->size;
@@ -1252,7 +1252,7 @@ void QQuickPixmap::load(QQmlEngine *engine, const QUrl &url, const QSize &reques
Q_QML_PROFILE(pixmapStateChanged<QQmlProfilerService::PixmapLoadingError>(url));
return;
}
- }
+ }
if (!engine)
return;
@@ -1283,7 +1283,7 @@ void QQuickPixmap::clear()
void QQuickPixmap::clear(QObject *obj)
{
if (d) {
- if (d->reply)
+ if (d->reply)
QObject::disconnect(d->reply, 0, obj, 0);
d->declarativePixmaps.remove(this);
d->release();
diff --git a/src/quick/util/qquickstate_p_p.h b/src/quick/util/qquickstate_p_p.h
index c559c8163c..82e456ed65 100644
--- a/src/quick/util/qquickstate_p_p.h
+++ b/src/quick/util/qquickstate_p_p.h
@@ -215,7 +215,7 @@ public:
struct OperationGuard : public QQmlGuard<QQuickStateOperation>
{
- OperationGuard(QObject *obj, QList<OperationGuard> *l) : list(l) {
+ OperationGuard(QObject *obj, QList<OperationGuard> *l) : list(l) {
setObject(static_cast<QQuickStateOperation *>(obj));
}
QList<OperationGuard> *list;
diff --git a/src/quick/util/qquicktimeline.cpp b/src/quick/util/qquicktimeline.cpp
index d8cf9bd877..5305537d24 100644
--- a/src/quick/util/qquicktimeline.cpp
+++ b/src/quick/util/qquicktimeline.cpp
@@ -81,7 +81,7 @@ struct QQuickTimeLinePrivate
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 QQuickTimeLineCallback &ev = QQuickTimeLineCallback(), const QEasingCurve &es = QEasingCurve())
: type(t), length(l), value(v), value2(v2), order(o), event(ev),
easing(es) {}
@@ -89,8 +89,8 @@ struct QQuickTimeLinePrivate
: 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;
}
@@ -604,8 +604,8 @@ void QQuickTimeLine::sync(QQuickTimeLineValue &timeLineValue)
d->syncPoint = d->length;
}*/
-/*!
- \internal
+/*!
+ \internal
Temporary hack.
*/
@@ -614,9 +614,9 @@ void QQuickTimeLine::setSyncPoint(int sp)
d->syncPoint = sp;
}
-/*!
- \internal
-
+/*!
+ \internal
+
Temporary hack.
*/
int QQuickTimeLine::syncPoint() const
@@ -739,7 +739,7 @@ int QQuickTimeLinePrivate::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)
@@ -748,7 +748,7 @@ int QQuickTimeLinePrivate::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;
@@ -762,8 +762,8 @@ int QQuickTimeLinePrivate::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/quick/util/qquicktransitionmanager.cpp b/src/quick/util/qquicktransitionmanager.cpp
index 769dadc4fc..2821d7628c 100644
--- a/src/quick/util/qquicktransitionmanager.cpp
+++ b/src/quick/util/qquicktransitionmanager.cpp
@@ -89,7 +89,7 @@ bool QQuickTransitionManager::isRunning() const
return d->transitionInstance && d->transitionInstance->isRunning();
}
-void QQuickTransitionManager::complete()
+void QQuickTransitionManager::complete()
{
d->applyBindings();
@@ -100,7 +100,7 @@ void QQuickTransitionManager::complete()
d->completeList.clear();
- if (d->state)
+ if (d->state)
static_cast<QQuickStatePrivate*>(QObjectPrivate::get(d->state))->complete();
finished();
@@ -228,8 +228,8 @@ void QQuickTransitionManager::transition(const QList<QQuickStateAction> &list,
} else {
if (touched.contains(action.property)) {
- if (action.toValue != action.fromValue)
- d->completeList <<
+ if (action.toValue != action.fromValue)
+ d->completeList <<
QQuickSimpleAction(action, QQuickSimpleAction::EndState);
applyList.removeAt(ii);
@@ -242,7 +242,7 @@ void QQuickTransitionManager::transition(const QList<QQuickStateAction> &list,
// 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 QQuickStateAction &action, applyList) {
if (action.event && !action.event->changesBindings()) {
@@ -261,7 +261,7 @@ void QQuickTransitionManager::transition(const QList<QQuickStateAction> &list,
qWarning() << " No transition for event:" << action.event->type();
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/quick/util/qquicktransitionmanager_p_p.h b/src/quick/util/qquicktransitionmanager_p_p.h
index 6211b5488c..bf203feaf4 100644
--- a/src/quick/util/qquicktransitionmanager_p_p.h
+++ b/src/quick/util/qquicktransitionmanager_p_p.h
@@ -60,7 +60,7 @@ QT_BEGIN_NAMESPACE
class QQuickStatePrivate;
class QQuickTransitionManagerPrivate;
-class Q_AUTOTEST_EXPORT QQuickTransitionManager
+class Q_AUTOTEST_EXPORT QQuickTransitionManager
{
public:
QQuickTransitionManager();