summaryrefslogtreecommitdiffstats
path: root/src/script
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-10-29 16:06:02 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-10-29 16:06:02 (GMT)
commit1cb7e3503a907719aebb98096c302a8327e9804d (patch)
tree451df6118fc8155793ecf32051eb7e2562f94826 /src/script
parent0af9699f95bed1d5bd66c2f3e787622674ca22a8 (diff)
parent8cd4b7622ea425f8fef316ae4ae91133f29f53c5 (diff)
downloadQt-1cb7e3503a907719aebb98096c302a8327e9804d.zip
Qt-1cb7e3503a907719aebb98096c302a8327e9804d.tar.gz
Qt-1cb7e3503a907719aebb98096c302a8327e9804d.tar.bz2
Merge branch 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into master-integration
* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1: Add autotest for QScriptExtensionPlugin Improve QtScript test coverage Don't crash when null-pointer is passed to qScriptValueFromValue() Simplify object lifetime management when moving objects to a QThread samegame: white space Move list of trusted benchmarks out of QA dungeon and into Qt Don't put Objective-C sources in SOURCES mkspecs: Emit warning when including g++.conf directly
Diffstat (limited to 'src/script')
-rw-r--r--src/script/api/qscriptengine.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/script/api/qscriptengine.h b/src/script/api/qscriptengine.h
index 830d477..24c8c13 100644
--- a/src/script/api/qscriptengine.h
+++ b/src/script/api/qscriptengine.h
@@ -332,10 +332,7 @@ inline QScriptValue qScriptValueFromValue(QScriptEngine *engine, const T &t)
template <>
inline QScriptValue qScriptValueFromValue<QVariant>(QScriptEngine *engine, const QVariant &v)
{
- QScriptValue result = qScriptValueFromValue_helper(engine, v.userType(), v.data());
- if (!result.isValid())
- result = engine->newVariant(v);
- return result;
+ return qScriptValueFromValue_helper(engine, v.userType(), v.data());
}
inline bool qscriptvalue_cast_helper(const QScriptValue &value, int type, void *ptr)