Showing the changes to libraries/script-engine/src/ScriptEngine.cpp (1 of 1 file). Show all
Unified · Split
| @@ -666,14 +666,11 @@ void avatarDataFromScriptValue(const QScriptValue& object, ScriptAvatarData*& ou · 665 unmodified lines | ||
| 666 | 666 | } |
| 667 | 667 | |
| 668 | 668 | QScriptValue externalResourceBucketToScriptValue(QScriptEngine* engine, ExternalResource::Bucket const& in) { |
| 669 | − //return engine->newQObject(in, QScriptEngine::ScriptOwnership, DEFAULT_QOBJECT_WRAP_OPTIONS); | |
| 670 | 669 | return QScriptValue((int)in); |
| 671 | 670 | } |
| 672 | 671 | |
| 673 | 672 | void externalResourceBucketFromScriptValue(const QScriptValue& object, ExternalResource::Bucket& out) { |
| 674 | − // This is not implemented because there are no slots/properties that take an AvatarSharedPointer from a script | |
| 675 | − assert(false); | |
| 676 | − out = ExternalResource::Bucket::Assets; | |
| 673 | + out = static_cast<ExternalResource::Bucket>(object.toInt32()); | |
| 677 | 674 | } |
| 678 | 675 | |
| 679 | 676 | void ScriptEngine::resetModuleCache(bool deleteScriptCache) { |