diff options
author | Martin Jones <martin.jones@nokia.com> | 2009-10-29 05:56:57 (GMT) |
---|---|---|
committer | Martin Jones <martin.jones@nokia.com> | 2009-10-29 05:56:57 (GMT) |
commit | 5b3fc8dfb20934e5a64c111335a292337320195a (patch) | |
tree | 1f3a51415daab55693fd0bca93099a39f1a24e1a /src/declarative/qml/qmlbinding.cpp | |
parent | b624cb89591298b3c786f6ba6dd9fb5c454caf20 (diff) | |
download | Qt-5b3fc8dfb20934e5a64c111335a292337320195a.zip Qt-5b3fc8dfb20934e5a64c111335a292337320195a.tar.gz Qt-5b3fc8dfb20934e5a64c111335a292337320195a.tar.bz2 |
Store filename as a QUrl rather than convert to QString.
Saves about 700KB heap in samegame.
Diffstat (limited to 'src/declarative/qml/qmlbinding.cpp')
-rw-r--r-- | src/declarative/qml/qmlbinding.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/declarative/qml/qmlbinding.cpp b/src/declarative/qml/qmlbinding.cpp index 317a4b3..83ca65b 100644 --- a/src/declarative/qml/qmlbinding.cpp +++ b/src/declarative/qml/qmlbinding.cpp @@ -170,15 +170,15 @@ void QmlBinding::update(QmlMetaProperty::WriteFlags flags) if (!isUndefined && data->property.object() && !data->property.write(value, flags)) { - QString fileName = data->fileName; + QUrl url = data->url; int line = data->line; - if (fileName.isEmpty()) fileName = QLatin1String("<Unknown File>"); + if (url.isEmpty()) url = QUrl(QLatin1String("<Unknown File>")); const char *valueType = 0; if (value.userType() == QVariant::Invalid) valueType = "null"; else valueType = QMetaType::typeName(value.userType()); - data->error.setUrl(fileName); + data->error.setUrl(url); data->error.setLine(line); data->error.setColumn(-1); data->error.setDescription(QLatin1String("Unable to assign ") + |