: Object(engine)
, m_object(object)
{
- this->v8Engine = QV8Engine::get(engine->publicEngine);
vtbl = &static_vtbl;
prototype = engine->objectPrototype;
}
QHashedV4String propertystring(QV4::Value::fromString(name));
+ QV8Engine *v8Engine = QV8Engine::get(ctx->engine->publicEngine);
QQmlContextData *context = QV4::QmlContextWrapper::callingContext(ctx->engine);
QHashedV4String propertystring(QV4::Value::fromString(name));
- QV8Engine *v8engine = that->v8Engine;
- QQmlContextData *context = v8engine->callingContext();
+ QQmlContextData *context = QV4::QmlContextWrapper::callingContext(ctx->engine);
+ QV8Engine *v8engine = QV8Engine::get(ctx->engine->publicEngine);
bool result = QV8QObjectWrapper::SetProperty(v8engine, object, propertystring, context, value, QV4::QObjectWrapper::IgnoreRevision);
if (!result) {
QStringList result;
- QQmlEnginePrivate *ep = that->v8Engine->engine()
- ? QQmlEnginePrivate::get(that->v8Engine->engine())
+ QV8Engine *v8Engine = QV8Engine::get(that->engine()->publicEngine);
+ QQmlEnginePrivate *ep = v8Engine->engine()
+ ? QQmlEnginePrivate::get(v8Engine->engine())
: 0;
QQmlPropertyCache *cache = 0;
Q_ASSERT(pdata->isWritable() || pdata->isQList());
- StoreProperty(wrapper->v8Engine, object, pdata, value);
+ StoreProperty(QV8Engine::get(wrapper->engine()->publicEngine), object, pdata, value);
}
static void FastValueSetterReadOnly(v8::Handle<v8::String> property, v8::Handle<v8::Value>,
if (QQmlData::wasDeleted(wrapper->object()))
return;
- QV8Engine *v8engine = wrapper->v8Engine;
+ QV8Engine *v8engine = QV8Engine::get(wrapper->engine()->publicEngine);
QString error = QLatin1String("Cannot assign to read-only property \"") +
property->v4Value().toQString() + QLatin1Char('\"');
~QObjectWrapper();
- QV8Engine *v8Engine; // ### Remove again.
-
QObject *object() const { return m_object.data(); }
void deleteQObject(bool deleteInstantly = false);
static Value wrap(ExecutionEngine *engine, QQmlData *ddata, QObject *object);
private:
- QObjectWrapper(ExecutionEngine *v8Engine, QObject *object);
+ QObjectWrapper(ExecutionEngine *engine, QObject *object);
QQmlGuard<QObject> m_object;
String *m_destroy;