Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qv4qmlcontext.cpp File Reference

(e19750538268c4d45fc6c60d2c90b17dd25c81e8)

#include "qv4qmlcontext_p.h"
#include <private/qjsvalue_p.h>
#include <private/qqmlcontext_p.h>
#include <private/qqmlengine_p.h>
#include <private/qqmlglobal_p.h>
#include <private/qqmljavascriptexpression_p.h>
#include <private/qqmllistwrapper_p.h>
#include <private/qqmltypewrapper_p.h>
#include <private/qv4compileddata_p.h>
#include <private/qv4engine_p.h>
#include <private/qv4function_p.h>
#include <private/qv4identifiertable_p.h>
#include <private/qv4lookup_p.h>
#include <private/qv4mm_p.h>
#include <private/qv4module_p.h>
#include <private/qv4objectproto_p.h>
#include <private/qv4qobjectwrapper_p.h>
#include <private/qv4stackframe_p.h>
#include <private/qv4value_p.h>
#include <QtCore/qloggingcategory.h>
+ Include dependency graph for qv4qmlcontext.cpp:

Go to the source code of this file.

Functions

QT_BEGIN_NAMESPACE Q_LOGGING_CATEGORY (lcQmlContext, "qt.qml.context")
 
 DEFINE_OBJECT_VTABLE (QQmlContextWrapper)
 
 DEFINE_MANAGED_VTABLE (QmlContext)
 
static OptionalReturnedValue searchContextProperties (QV4::ExecutionEngine *v4, const QQmlRefPointer< QQmlContextData > &context, String *name, bool *hasProperty, Value *base, QV4::Lookup *lookup, QV4::Lookup *originalLookup, QQmlEnginePrivate *ep)
 
template<typename Lookup >
bool performLookup (ScopedValue *result, bool *hasProperty, const Lookup &lookup)
 
static QV4::QObjectWrapper::Flags getQmlPropertyFlags (const Lookup *l)
 
static ReturnedValue revertObjectPropertyLookup (Lookup *l, ExecutionEngine *engine, Value *base)
 
static ReturnedValue revertObjectMethodLookup (Lookup *l, ExecutionEngine *engine, Value *base)
 
template<typename Call >
ReturnedValue callWithScopeObject (ExecutionEngine *engine, Value *base, Call c)
 
template<typename Call >
ReturnedValue callWithContextObject (ExecutionEngine *engine, Value *base, Call c)
 

Function Documentation

◆ callWithContextObject()

template<typename Call >
ReturnedValue callWithContextObject ( ExecutionEngine * engine,
Value * base,
Call c )

Definition at line 685 of file qv4qmlcontext.cpp.

References base, context, engine, qmlContext(), QV4::Encode::undefined(), QQmlData::wasDeleted(), and QV4::QObjectWrapper::wrap().

Referenced by QV4::QQmlContextWrapper::lookupContextObjectMethod(), and QV4::QQmlContextWrapper::lookupContextObjectProperty().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ callWithScopeObject()

template<typename Call >
ReturnedValue callWithScopeObject ( ExecutionEngine * engine,
Value * base,
Call c )

Definition at line 638 of file qv4qmlcontext.cpp.

References base, engine, qmlContext(), QV4::Encode::undefined(), QQmlData::wasDeleted(), and QV4::QObjectWrapper::wrap().

Referenced by QV4::QQmlContextWrapper::lookupScopeObjectMethod(), and QV4::QQmlContextWrapper::lookupScopeObjectProperty().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ DEFINE_MANAGED_VTABLE()

DEFINE_MANAGED_VTABLE ( QmlContext )

◆ DEFINE_OBJECT_VTABLE()

DEFINE_OBJECT_VTABLE ( QQmlContextWrapper )

◆ getQmlPropertyFlags()

static QV4::QObjectWrapper::Flags getQmlPropertyFlags ( const Lookup * l)
static

Definition at line 107 of file qv4qmlcontext.cpp.

References QV4::QObjectWrapper::AttachMethods, QV4::QObjectWrapper::CheckRevision, and QV4::Lookup::forCall.

Referenced by QV4::QQmlContextWrapper::getPropertyAndBase(), and QV4::QQmlContextWrapper::lookupInParentContextHierarchy().

+ Here is the caller graph for this function:

◆ performLookup()

template<typename Lookup >
bool performLookup ( ScopedValue * result,
bool * hasProperty,
const Lookup & lookup )

Definition at line 96 of file qv4qmlcontext.cpp.

Referenced by QV4::QQmlContextWrapper::getPropertyAndBase().

+ Here is the caller graph for this function:

◆ Q_LOGGING_CATEGORY()

QT_BEGIN_NAMESPACE Q_LOGGING_CATEGORY ( lcQmlContext ,
"qt.qml.context"  )

◆ revertObjectMethodLookup()

static ReturnedValue revertObjectMethodLookup ( Lookup * l,
ExecutionEngine * engine,
Value * base )
static

Definition at line 629 of file qv4qmlcontext.cpp.

References base, engine, QV4::Lookup::qmlContextPropertyGetter, QV4::Lookup::qobjectMethodLookup, and QV4::QQmlContextWrapper::resolveQmlContextPropertyLookupGetter().

Referenced by QV4::QQmlContextWrapper::lookupContextObjectMethod(), and QV4::QQmlContextWrapper::lookupScopeObjectMethod().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ revertObjectPropertyLookup()

static ReturnedValue revertObjectPropertyLookup ( Lookup * l,
ExecutionEngine * engine,
Value * base )
static

Definition at line 621 of file qv4qmlcontext.cpp.

References base, engine, QV4::Lookup::qmlContextPropertyGetter, QV4::Lookup::qobjectLookup, and QV4::QQmlContextWrapper::resolveQmlContextPropertyLookupGetter().

Referenced by QV4::QQmlContextWrapper::lookupContextObjectProperty(), and QV4::QQmlContextWrapper::lookupScopeObjectProperty().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ searchContextProperties()

static OptionalReturnedValue searchContextProperties ( QV4::ExecutionEngine * v4,
const QQmlRefPointer< QQmlContextData > & context,
String * name,
bool * hasProperty,
Value * base,
QV4::Lookup * lookup,
QV4::Lookup * originalLookup,
QQmlEnginePrivate * ep )
static