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>.
|
#include <qqmlengine_p.h>
Classes | |
struct | Incubator |
Static Public Attributes | |
static bool | baseModulesUninitialized = true |
static const quintptr | profiler = 0 |
static std::atomic< bool > | qml_debugging_enabled {false} |
\qmltype QtObject \instantiates QObject \inqmlmodule QtQml | |
Additional Inherited Members | |
Public Types inherited from QObjectPrivate | |
typedef void(* | StaticMetaCallFunction) (QObject *, QMetaObject::Call, int, void **) |
using | ConnectionDataPointer = QExplicitlySharedDataPointer<ConnectionData> |
Definition at line 100 of file qqmlengine_p.h.
|
inlineexplicit |
Definition at line 104 of file qqmlengine_p.h.
|
override |
Definition at line 200 of file qqmlengine.cpp.
References QQmlMetaType::freeUnusedTypesAndCaches(), incubationController, inProgressCreations, profiler, qDeleteAll(), and qWarning.
|
static |
Definition at line 131 of file qqmlengine.cpp.
Referenced by QQuickDesignerSupport::activateDesignerMode().
QV4::ExecutableCompilationUnit * QQmlEnginePrivate::compilationUnitFromUrl | ( | const QUrl & | url | ) |
Definition at line 1961 of file qqmlengine.cpp.
References QV4::ExecutionEngine::compilationUnitForUrl(), QV4::ExecutionEngine::executableCompilationUnit(), and url.
QQmlRefPointer< QQmlContextData > QQmlEnginePrivate::createInternalContext | ( | const QQmlRefPointer< QV4::ExecutableCompilationUnit > & | unit, |
const QQmlRefPointer< QQmlContextData > & | parentContext, | ||
int | subComponentIndex, | ||
bool | isComponentRoot ) |
Definition at line 1980 of file qqmlengine.cpp.
References QV4::Scoped< T >::asReturnedValue(), QQmlData::context, QQmlContextData::createRefCounted(), i, QQmlContextData::initFromTypeCompilationUnit(), QV4::ExecutionEngine::newArrayObject(), QV4::Object::put(), Q_ASSERT, QQmlContextData::setImportedScripts(), QQmlContextData::setImports(), and QQmlContextData::setInternal().
|
inline |
Definition at line 314 of file qqmlengine_p.h.
References engine, Q_ASSERT, Q_LIKELY, Q_UNLIKELY, scarceResourcesRefCount, and v4engine().
Referenced by QQmlComponentPrivate::beginCreate(), QQmlBinding::evaluate(), QQmlBoundSignalExpression::evaluate(), QQmlIncubatorPrivate::incubate(), QQmlVMEMetaObject::metaCall(), and QQmlExpressionPrivate::value().
|
static |
Definition at line 126 of file qqmlengine.cpp.
Referenced by QAbstractAnimationJob::start(), QQuickBoundaryRule::write(), and QQuickBehavior::write().
void QQmlEnginePrivate::executeRuntimeFunction | ( | const QUrl & | url, |
qsizetype | functionIndex, | ||
QObject * | thisObject, | ||
int | argc = 0, | ||
void ** | args = nullptr, | ||
QMetaType * | types = nullptr ) |
Definition at line 1902 of file qqmlengine.cpp.
void QQmlEnginePrivate::executeRuntimeFunction | ( | const QV4::ExecutableCompilationUnit * | unit, |
qsizetype | functionIndex, | ||
QObject * | thisObject, | ||
int | argc = 0, | ||
void ** | args = nullptr, | ||
QMetaType * | types = nullptr ) |
Definition at line 1912 of file qqmlengine.cpp.
References args, QV4::ExecutionEngine::callInContext(), QV4::QmlContext::create(), QQmlData::get(), Q_ASSERT, QV4::CompilationUnitRuntimeData::runtimeFunctions, and QV4::ExecutionEngine::scriptContext().
|
inlinestatic |
Definition at line 344 of file qqmlengine_p.h.
References Q_ASSERT.
|
inlinestatic |
Definition at line 366 of file qqmlengine_p.h.
References contextEngine().
|
inlinestatic |
Definition at line 361 of file qqmlengine_p.h.
References contextEngine().
|
inlinestatic |
Definition at line 337 of file qqmlengine_p.h.
References Q_ASSERT.
Referenced by CapturePreventer::CapturePreventer(), QQmlExpression::QQmlExpression(), QQmlTranslationBinding::QQmlTranslationBinding(), QQmlIncubationController::~QQmlIncubationController(), QQmlJavaScriptExpression::allocatePropertyChangeTrigger(), QQmlComponentPrivate::beginCreate(), QtQuickPrivate::beginDeferred(), QQmlBindPrivate::buildBindEntries(), QQmlPropertyCapture::captureTranslation(), checkSingletonInstance(), QQmlComponentPrivate::completeCreate(), QtQuickPrivate::completeDeferred(), contextEngine(), QQmlBinding::create(), QQmlComponent::create(), QQmlPropertyBinding::createFromScriptString(), createPixmapDataSync(), QQmlJavaScriptExpression::createQmlBinding(), QtObject::createQmlObject(), QQmlComponentPrivate::createWithProperties(), QQmlBindPrivate::decodeBinding(), QQmlTypeData::done(), QQmlBinding::doUpdate(), QQmlIncubationController::engine(), QQmlProfilerServiceImpl::engineAboutToBeAdded(), enumForSingleton(), QQmlJavaScriptExpression::evalFunction(), QQmlBinding::evaluate(), QQmlBoundSignalExpression::evaluate(), QtObject::exit(), QQmlObjectCreator::finalize(), gc(), gcDone(), get(), QV4::QObjectWrapper::getProperty(), QV4::QQmlContextWrapper::getPropertyAndBase(), QQmlConnectionSlotDispatcher::impl(), QV4::QObjectSlotDispatcher::impl(), QQmlTypeLoader::importDatabase(), QQmlIncubatorPrivate::incubate(), QQmlComponentPrivate::incubateObject(), QQDMIncubationTask::initializeRequiredProperties(), QQmlPropertyPrivate::initProperty(), QQmlGadgetPtrWrapper::instance(), instanceOfQObject(), QQuickPixmap::load(), QQmlPrivate::AOTCompiledContext::loadAttachedLookup(), QQmlPrivate::AOTCompiledContext::loadContextIdLookup(), QQmlComponentPrivate::loadUrl(), QV4::QQmlContextWrapper::lookupIdObject(), QV4::QQmlContextWrapper::lookupInParentContextHierarchy(), QV4::QQmlTypeWrapper::lookupSingletonMethod(), QV4::QQmlTypeWrapper::lookupSingletonProperty(), QQmlVMEMetaObject::metaCall(), QV4::QQmlTypeWrapper::metaObject(), QQmlJavaScriptExpressionGuard::New(), QV4::QQmlTypeWrapper::object(), QQmlPrivate::SingletonInstanceFunctor::operator()(), QQmlComponentPrivate::prepareLoadFromModule(), QQmlPrivate::propertyCapture(), QQmlComponent::qmlAttachedProperties(), qmlAttachedPropertiesFunction(), qmlExecuteDeferred(), qmlsqldatabase_changeVersion(), qQmlTranslationPropertyBindingCreateBinding(), QtObject::quit(), QV4::ExecutionEngine::registerNativeModule(), QQmlScriptData::scriptValueForContext(), QQmlComponent::setData(), QQmlTableInstanceModel::setRequiredProperty(), QV4::QQmlTypeWrapper::singletonObject(), QV4::QmlIncubatorObject::statusChanged(), QV4::QQmlTypeWrapper::toVariant(), QQmlBinding::update(), QQmlExpressionPrivate::value(), QV4::QQmlTypeWrapper::virtualGet(), QV4::QQmlScopedEnumWrapper::virtualGet(), QV4::ModelObject::virtualGet(), QV4::QQmlTypeWrapper::virtualPut(), QV4::QQmlTypeWrapper::virtualResolveLookupGetter(), warning(), warning(), and QQmlPropertyPrivate::write().
|
inlinestatic |
Definition at line 371 of file qqmlengine_p.h.
References Q_ASSERT.
|
inlinestatic |
Definition at line 378 of file qqmlengine_p.h.
References get(), QV4::ExecutionEngine::qmlEngine(), and qmlEngine().
|
inlinestatic |
Definition at line 330 of file qqmlengine_p.h.
References QJSEngine::handle(), and Q_ASSERT.
Referenced by QQuickSpinBoxPrivate::evaluateTextFromValue(), QQuickSpinBoxPrivate::evaluateValueFromText(), and QQuickStackElement::initialize().
QSharedPointer< QQmlImageProviderBase > QQmlEnginePrivate::imageProvider | ( | const QString & | providerId | ) | const |
Definition at line 757 of file qqmlengine.cpp.
References imageProviderMutex, imageProviders, QString::toLower(), and QHash< Key, T >::value().
Referenced by createPixmapDataSync(), and QQuickPixmap::load().
void QQmlEnginePrivate::incubate | ( | QQmlIncubator & | i, |
const QQmlRefPointer< QQmlContextData > & | forContext ) |
Definition at line 11 of file qqmlincubator.cpp.
References QQmlIncubator::Asynchronous, QQmlIncubator::AsynchronousIfNested, i, QQmlIncubationController::incubatingObjectCountChanged(), incubationController, incubatorCount, incubatorList, inProgressCreations, QQmlIncubator::Loading, QQmlIncubator::Synchronous, and watcher.
Referenced by QQmlComponent::create(), and QQmlComponentPrivate::incubateObject().
void QQmlEnginePrivate::init | ( | ) |
Definition at line 468 of file qqmlengine.cpp.
References baseModulesUninitialized, QQmlData::init(), qml_register_types_QML(), qmlProtectModule(), and rootContext.
bool QQmlEnginePrivate::isScriptLoaded | ( | const QUrl & | url | ) | const |
Definition at line 1897 of file qqmlengine.cpp.
References url.
bool QQmlEnginePrivate::isTypeLoaded | ( | const QUrl & | url | ) | const |
Definition at line 1892 of file qqmlengine.cpp.
References url.
QString QQmlEnginePrivate::offlineStorageDatabaseDirectory | ( | ) | const |
Definition at line 1819 of file qqmlengine.cpp.
References QDir::separator().
Referenced by qmlsqldatabase_changeVersion().
QQmlEnginePrivate::Q_OBJECT_BINDABLE_PROPERTY | ( | QQmlEnginePrivate | , |
QString | , | ||
translationLanguage | ) |
|
static |
Definition at line 1582 of file qqmlengine.cpp.
References error, fileName, qPrintable, and qWarning.
Referenced by QQmlScriptBlob::dataReceived(), and QV4::Script::precompile().
|
inline |
Definition at line 305 of file qqmlengine_p.h.
References scarceResourcesRefCount.
Referenced by QQmlComponentPrivate::beginCreate(), QQmlBinding::evaluate(), QQmlBoundSignalExpression::evaluate(), QQmlIncubatorPrivate::incubate(), QQmlVMEMetaObject::metaCall(), and QQmlExpressionPrivate::value().
void QQmlEnginePrivate::sendExit | ( | int | retCode = 0 | ) |
Definition at line 1493 of file qqmlengine.cpp.
void QQmlEnginePrivate::sendQuit | ( | ) |
Definition at line 1484 of file qqmlengine.cpp.
|
inlinestatic |
Definition at line 233 of file qqmlengine_p.h.
References context, QQmlData::get(), Q_ASSERT, and qmlEngine().
Definition at line 1826 of file qqmlengine.cpp.
References arg, QString::asprintf(), component(), QQmlData::ensurePropertyCache(), error, QString::fromUtf8(), QQmlData::get(), QQmlContextData::get(), o, QQmlComponent::PreferSynchronous, Q_ASSERT, qPrintable, QtCriticalMsg, QJSValue::UndefinedValue, and warning().
T QQmlEnginePrivate::singletonInstance | ( | const QQmlType & | type | ) |
Definition at line 390 of file qqmlengine_p.h.
Referenced by QV4::QQmlContextWrapper::getPropertyAndBase(), QV4::QQmlTypeWrapper::lookupSingletonMethod(), QV4::QQmlTypeWrapper::lookupSingletonProperty(), QV4::QQmlTypeWrapper::singletonObject(), QV4::QQmlTypeWrapper::toVariant(), QV4::QQmlTypeWrapper::virtualGet(), QV4::QQmlTypeWrapper::virtualPut(), and QV4::QQmlTypeWrapper::virtualResolveLookupGetter().
|
inline |
Definition at line 132 of file qqmlengine_p.h.
Referenced by QQmlTypeCompiler::compile(), dereferenceScarceResources(), and QQmlPropertyPrivate::write().
|
inline |
Definition at line 207 of file qqmlengine_p.h.
References QSet< T >::cend(), QSet< T >::constFind(), it, and QQmlMetaType::valueType().
Definition at line 1542 of file qqmlengine.cpp.
References dumpwarning(), and emit.
Definition at line 1534 of file qqmlengine.cpp.
References dumpwarning(), emit, and error.
Referenced by QQmlInfo::~QQmlInfo(), QQuickLoaderPrivate::_q_sourceLoaded(), QQmlIncubator::clear(), QQmlComponentPrivate::complete(), QQmlPropertyCacheCreator< ObjectContainer >::createMetaObject(), QQmlJavaScriptExpression::createQmlBinding(), QQmlJavaScriptExpression::evalFunction(), QQuickWorkerScript::event(), QQmlApplicationEnginePrivate::finishLoad(), QV4::generateWarning(), QQmlIncubatorPrivate::incubate(), QQuickLoaderPrivate::incubatorStateChanged(), QQmlVMEMetaObject::metaCall(), and QV4::QmlIncubatorObject::statusChanged().
|
static |
Definition at line 1558 of file qqmlengine.cpp.
References dumpwarning(), engine, error, and get().
|
static |
Definition at line 1550 of file qqmlengine.cpp.
References dumpwarning(), engine, error, and get().
|
static |
Definition at line 1574 of file qqmlengine.cpp.
References dumpwarning(), engine, and error.
|
static |
Definition at line 1566 of file qqmlengine.cpp.
References dumpwarning(), engine, and error.
QQmlObjectCreator* QQmlEnginePrivate::activeObjectCreator = nullptr |
Definition at line 140 of file qqmlengine_p.h.
|
static |
Definition at line 110 of file qqmlengine_p.h.
Referenced by init(), and qmlClearTypeRegistrations().
QUrl QQmlEnginePrivate::baseUrl |
Definition at line 138 of file qqmlengine_p.h.
QQmlDelayedError* QQmlEnginePrivate::erroredBindings = nullptr |
Definition at line 129 of file qqmlengine_p.h.
Referenced by QQmlDelayedError::addError(), QQmlIncubator::clear(), QQmlComponentPrivate::complete(), and QQmlIncubatorPrivate::incubate().
|
mutable |
Definition at line 147 of file qqmlengine_p.h.
Referenced by imageProvider().
QHash<QString,QSharedPointer<QQmlImageProviderBase> > QQmlEnginePrivate::imageProviders |
Definition at line 148 of file qqmlengine_p.h.
Referenced by imageProvider().
QQmlImportDatabase QQmlEnginePrivate::importDatabase |
Definition at line 157 of file qqmlengine_p.h.
QQmlIncubationController* QQmlEnginePrivate::incubationController = nullptr |
Definition at line 169 of file qqmlengine_p.h.
Referenced by ~QQmlEnginePrivate(), QQmlIncubatorPrivate::clear(), and incubate().
unsigned int QQmlEnginePrivate::incubatorCount = 0 |
Definition at line 168 of file qqmlengine_p.h.
Referenced by QQmlIncubatorPrivate::clear(), incubate(), QQmlIncubationController::incubateFor(), QQmlIncubationController::incubateWhile(), and QQmlIncubationController::incubatingObjectCount().
QIntrusiveList<Incubator, &Incubator::next> QQmlEnginePrivate::incubatorList |
Definition at line 167 of file qqmlengine_p.h.
Referenced by incubate(), QQmlIncubationController::incubateFor(), and QQmlIncubationController::incubateWhile().
int QQmlEnginePrivate::inProgressCreations = 0 |
Definition at line 130 of file qqmlengine_p.h.
Referenced by ~QQmlEnginePrivate(), QQmlDelayedError::addError(), QQmlComponentPrivate::beginCreate(), QtQuickPrivate::beginDeferred(), QQmlComponentPrivate::beginDeferred(), QQmlBindPrivate::buildBindEntries(), QQmlIncubator::clear(), QQmlComponentPrivate::complete(), incubate(), and QQmlIncubatorPrivate::incubate().
QRecyclePool<QQmlJavaScriptExpressionGuard> QQmlEnginePrivate::jsExpressionGuardPool |
Definition at line 114 of file qqmlengine_p.h.
|
mutable |
Definition at line 205 of file qqmlengine_p.h.
QString QQmlEnginePrivate::offlineStoragePath |
Definition at line 160 of file qqmlengine_p.h.
Referenced by QQmlEngine::offlineStoragePath().
bool QQmlEnginePrivate::outputWarningsToMsgLog = true |
Definition at line 126 of file qqmlengine_p.h.
|
static |
Definition at line 121 of file qqmlengine_p.h.
Referenced by ~QQmlEnginePrivate().
QQmlPropertyCapture* QQmlEnginePrivate::propertyCapture = nullptr |
Definition at line 112 of file qqmlengine_p.h.
Referenced by CapturePreventer::CapturePreventer(), CapturePreventer::~CapturePreventer(), QQmlJavaScriptExpressionCapture::~QQmlJavaScriptExpressionCapture(), QV4::QObjectWrapper::getProperty(), searchContextProperties(), and QV4::ModelObject::virtualGet().
|
static |
\qmltype QtObject \instantiates QObject \inqmlmodule QtQml
A basic QML type.
The QtObject type is a non-visual element which contains only the objectName property.
It can be useful to create a QtObject if you need an extremely lightweight type to enclose a set of custom properties:
It can also be useful for C++ integration, as it is just a plain QObject. See the QObject documentation for further details.
\qmlproperty string QtObject::objectName This property holds the QObject::objectName for this specific object instance.
This allows a C++ application to locate an item within a QML component using the QObject::findChild() method. For example, the following C++ application locates the child \l Rectangle item and dynamically changes its color
value:
\qml MyRect.qml
import QtQuick 2.0 Item { width: 200; height: 200 Rectangle { anchors.fill: parent color: "red" objectName: "myRect" } } \endqml \code // main.cpp QQuickView view; view.setSource(QUrl::fromLocalFile("MyRect.qml")); view.show(); QQuickItem *item = view.rootObject()->findChild<QQuickItem*>("myRect"); if (item) item->setProperty("color", QColor(Qt::yellow)); \endcode
Definition at line 123 of file qqmlengine_p.h.
QRecyclePool<TriggerList> QQmlEnginePrivate::qPropertyTriggerPool |
Definition at line 115 of file qqmlengine_p.h.
QQmlContext* QQmlEnginePrivate::rootContext = nullptr |
Definition at line 117 of file qqmlengine_p.h.
Referenced by init().
int QQmlEnginePrivate::scarceResourcesRefCount = 0 |
Definition at line 153 of file qqmlengine_p.h.
Referenced by dereferenceScarceResources(), and referenceScarceResources().
QQmlTypeLoader QQmlEnginePrivate::typeLoader |
QList<QQmlAbstractUrlInterceptor *> QQmlEnginePrivate::urlInterceptors |
Definition at line 151 of file qqmlengine_p.h.