summaryrefslogtreecommitdiffstats
path: root/src/declarative/qml/qmlbinding.cpp
diff options
context:
space:
mode:
authorMartin Jones <martin.jones@nokia.com>2009-10-29 05:56:57 (GMT)
committerMartin Jones <martin.jones@nokia.com>2009-10-29 05:56:57 (GMT)
commit5b3fc8dfb20934e5a64c111335a292337320195a (patch)
tree1f3a51415daab55693fd0bca93099a39f1a24e1a /src/declarative/qml/qmlbinding.cpp
parentb624cb89591298b3c786f6ba6dd9fb5c454caf20 (diff)
downloadQt-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.cpp6
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 ") +