summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@intel.com>2014-05-01 14:54:02 -0700
committerThe Qt Project <gerrit-noreply@qt-project.org>2014-05-07 22:16:40 +0200
commit3ef7c3fc56d41f0028e7ee822abd95fe5c21bd7e (patch)
tree28270a14c4b8c05b6b02c8dadf67efebf1b4c0d8 /src
parentfc0ae9f3c325936a77e5efaeeabccb56f8919ee8 (diff)
downloadqtquick1-3ef7c3fc56d41f0028e7ee822abd95fe5c21bd7e.tar.gz
Don't use a variable called 'interface'
MSVC has #define interface struct, resulting in a nonsensical error from the compiler about "struct: missing tag name" in a line that doesn't say "struct". Change-Id: I1ca703fd7920052e9d0bdf9a6936df77597ff022 Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src')
-rw-r--r--src/declarative/qml/qdeclarativemetatype.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/src/declarative/qml/qdeclarativemetatype.cpp b/src/declarative/qml/qdeclarativemetatype.cpp
index d90ccad8..29f4b518 100644
--- a/src/declarative/qml/qdeclarativemetatype.cpp
+++ b/src/declarative/qml/qdeclarativemetatype.cpp
@@ -191,13 +191,13 @@ QDeclarativeTypePrivate::QDeclarativeTypePrivate()
}
-QDeclarativeType::QDeclarativeType(int index, const QDeclarativePrivate::RegisterInterface &interface)
+QDeclarativeType::QDeclarativeType(int index, const QDeclarativePrivate::RegisterInterface &iface)
: d(new QDeclarativeTypePrivate)
{
d->m_isInterface = true;
- d->m_iid = interface.iid;
- d->m_typeId = interface.typeId;
- d->m_listId = interface.listId;
+ d->m_iid = iface.iid;
+ d->m_typeId = iface.typeId;
+ d->m_listId = iface.listId;
d->m_newFunc = 0;
d->m_index = index;
d->m_isSetup = true;
@@ -598,9 +598,9 @@ int registerAutoParentFunction(QDeclarativePrivate::RegisterAutoParent &autopare
return data->parentFunctions.count() - 1;
}
-int registerInterface(const QDeclarativePrivate::RegisterInterface &interface)
+int registerInterface(const QDeclarativePrivate::RegisterInterface &iface)
{
- if (interface.version > 0)
+ if (iface.version > 0)
qFatal("qmlRegisterType(): Cannot mix incompatible QML versions.");
QWriteLocker lock(metaTypeDataLock());
@@ -608,7 +608,7 @@ int registerInterface(const QDeclarativePrivate::RegisterInterface &interface)
int index = data->types.count();
- QDeclarativeType *type = new QDeclarativeType(index, interface);
+ QDeclarativeType *type = new QDeclarativeType(index, iface);
data->types.append(type);
data->idToType.insert(type->typeId(), type);
@@ -617,12 +617,12 @@ int registerInterface(const QDeclarativePrivate::RegisterInterface &interface)
if (!type->qmlTypeName().isEmpty())
data->nameToType.insert(type->qmlTypeName(), type);
- if (data->interfaces.size() <= interface.typeId)
- data->interfaces.resize(interface.typeId + 16);
- if (data->lists.size() <= interface.listId)
- data->lists.resize(interface.listId + 16);
- data->interfaces.setBit(interface.typeId, true);
- data->lists.setBit(interface.listId, true);
+ if (data->interfaces.size() <= iface.typeId)
+ data->interfaces.resize(iface.typeId + 16);
+ if (data->lists.size() <= iface.listId)
+ data->lists.resize(iface.listId + 16);
+ data->interfaces.setBit(iface.typeId, true);
+ data->lists.setBit(iface.listId, true);
return index;
}