aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4objectiterator.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@digia.com>2013-09-12 22:37:41 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-09-18 13:13:55 +0200
commita2d115fbaffee282a1d32ed92c6700e6c3dd811b (patch)
tree7694e53751edd605d99d1d8eb19c9cd5d6d8188a /src/qml/jsruntime/qv4objectiterator.cpp
parent399f88f6b75bb842be8e9d3671ace5114e115542 (diff)
Convert most remaining return values from Value to ReturnedValue
Change-Id: If8b0c3b91be50678693868c10fefc3678008834d Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Diffstat (limited to 'src/qml/jsruntime/qv4objectiterator.cpp')
-rw-r--r--src/qml/jsruntime/qv4objectiterator.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/qml/jsruntime/qv4objectiterator.cpp b/src/qml/jsruntime/qv4objectiterator.cpp
index 8fdf281c7f..f03c2d6b86 100644
--- a/src/qml/jsruntime/qv4objectiterator.cpp
+++ b/src/qml/jsruntime/qv4objectiterator.cpp
@@ -92,38 +92,38 @@ Property *ObjectIterator::next(String **name, uint *index, PropertyAttributes *a
return 0;
}
-Value ObjectIterator::nextPropertyName(Value *value)
+ReturnedValue ObjectIterator::nextPropertyName(Value *value)
{
PropertyAttributes attrs;
uint index;
String *name;
Property *p = next(&name, &index, &attrs);
if (!p)
- return Value::nullValue();
+ return Encode::null();
if (value)
*value = Value::fromReturnedValue(object->getValue(p, attrs));
if (name)
- return Value::fromString(name);
+ return Value::fromString(name).asReturnedValue();
assert(index < UINT_MAX);
- return Value::fromDouble(index);
+ return Encode(index);
}
-Value ObjectIterator::nextPropertyNameAsString(Value *value)
+ReturnedValue ObjectIterator::nextPropertyNameAsString(Value *value)
{
PropertyAttributes attrs;
uint index;
String *name;
Property *p = next(&name, &index, &attrs);
if (!p)
- return Value::nullValue();
+ return Encode::null();
if (value)
*value = Value::fromReturnedValue(object->getValue(p, attrs));
if (name)
- return Value::fromString(name);
+ return Value::fromString(name).asReturnedValue();
assert(index < UINT_MAX);
- return Value::fromString(object->engine()->newString(QString::number(index)));
+ return Value::fromString(object->engine()->newString(QString::number(index))).asReturnedValue();
}