aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/qml
diff options
context:
space:
mode:
Diffstat (limited to 'src/qml/qml')
-rw-r--r--src/qml/qml/qqmlcomponent.cpp7
-rw-r--r--src/qml/qml/qqmlengine.cpp8
-rw-r--r--src/qml/qml/qqmlimport.cpp6
-rw-r--r--src/qml/qml/qqmlmetatype.cpp4
-rw-r--r--src/qml/qml/qqmlpropertycache.cpp5
-rw-r--r--src/qml/qml/qqmlpropertycache_p.h1
-rw-r--r--src/qml/qml/v8/qv8engine_p.h2
7 files changed, 22 insertions, 11 deletions
diff --git a/src/qml/qml/qqmlcomponent.cpp b/src/qml/qml/qqmlcomponent.cpp
index 679e54c122..bc9669c987 100644
--- a/src/qml/qml/qqmlcomponent.cpp
+++ b/src/qml/qml/qqmlcomponent.cpp
@@ -783,7 +783,7 @@ QObject *QQmlComponent::create(QQmlContext *context)
}
/*!
- This method provides more advanced control over component instance creation.
+ This method provides advanced control over component instance creation.
In general, programmers should use QQmlComponent::create() to create a
component.
@@ -932,11 +932,12 @@ void QQmlComponentPrivate::complete(QQmlEnginePrivate *enginePriv, ConstructionS
}
/*!
- This method provides more advanced control over component instance creation.
+ This method provides advanced control over component instance creation.
In general, programmers should use QQmlComponent::create() to create a
component.
- Complete a component creation begin with QQmlComponent::beginCreate().
+ This function completes the component creation begun with QQmlComponent::beginCreate()
+ and must be called afterwards.
\sa beginCreate()
*/
diff --git a/src/qml/qml/qqmlengine.cpp b/src/qml/qml/qqmlengine.cpp
index b4962a6b1d..f0bf6e4e20 100644
--- a/src/qml/qml/qqmlengine.cpp
+++ b/src/qml/qml/qqmlengine.cpp
@@ -1670,8 +1670,8 @@ void QQmlEngine::addImportPath(const QString& path)
type version mapping and possibly QML extensions plugins.
By default, the list contains the directory of the application executable,
- paths specified in the \c QML_IMPORT_PATH environment variable,
- and the builtin \c ImportsPath from QLibraryInfo.
+ paths specified in the \c QML2_IMPORT_PATH environment variable,
+ and the builtin \c Qml2ImportsPath from QLibraryInfo.
\sa addImportPath(), setImportPathList()
*/
@@ -1686,8 +1686,8 @@ QStringList QQmlEngine::importPathList() const
installed modules in a URL-based directory structure.
By default, the list contains the directory of the application executable,
- paths specified in the \c QML_IMPORT_PATH environment variable,
- and the builtin \c ImportsPath from QLibraryInfo.
+ paths specified in the \c QML2_IMPORT_PATH environment variable,
+ and the builtin \c Qml2ImportsPath from QLibraryInfo.
\sa importPathList(), addImportPath()
*/
diff --git a/src/qml/qml/qqmlimport.cpp b/src/qml/qml/qqmlimport.cpp
index 0b07705cec..7a2f4eaf34 100644
--- a/src/qml/qml/qqmlimport.cpp
+++ b/src/qml/qml/qqmlimport.cpp
@@ -1320,13 +1320,13 @@ QQmlImportDatabase::QQmlImportDatabase(QQmlEngine *e)
{
filePluginPath << QLatin1String(".");
- // Search order is applicationDirPath(), $QML_IMPORT_PATH, QLibraryInfo::ImportsPath
+ // Search order is applicationDirPath(), $QML2_IMPORT_PATH, QLibraryInfo::Qml2ImportsPath
- QString installImportsPath = QLibraryInfo::location(QLibraryInfo::ImportsPath);
+ QString installImportsPath = QLibraryInfo::location(QLibraryInfo::Qml2ImportsPath);
addImportPath(installImportsPath);
// env import paths
- QByteArray envImportPath = qgetenv("QML_IMPORT_PATH");
+ QByteArray envImportPath = qgetenv("QML2_IMPORT_PATH");
if (!envImportPath.isEmpty()) {
#if defined(Q_OS_WIN)
QLatin1Char pathSep(';');
diff --git a/src/qml/qml/qqmlmetatype.cpp b/src/qml/qml/qqmlmetatype.cpp
index 1fdc1b95f1..595f9e8de0 100644
--- a/src/qml/qml/qqmlmetatype.cpp
+++ b/src/qml/qml/qqmlmetatype.cpp
@@ -139,6 +139,10 @@ QQmlMetaTypeData::~QQmlMetaTypeData()
{
for (int i = 0; i < types.count(); ++i)
delete types.at(i);
+
+ TypeModules::const_iterator i = uriToModule.constBegin();
+ for (; i != uriToModule.constEnd(); ++i)
+ delete *i;
}
class QQmlTypePrivate
diff --git a/src/qml/qml/qqmlpropertycache.cpp b/src/qml/qml/qqmlpropertycache.cpp
index c1c4a6c03d..8b023855ab 100644
--- a/src/qml/qml/qqmlpropertycache.cpp
+++ b/src/qml/qml/qqmlpropertycache.cpp
@@ -549,6 +549,11 @@ QQmlPropertyCache *QQmlPropertyCache::parent() const
return _parent;
}
+void QQmlPropertyCache::setParent(QQmlPropertyCache *newParent)
+{
+ _parent = newParent;
+}
+
// Returns the first C++ type's QMetaObject - that is, the first QMetaObject not created by
// QML
const QMetaObject *QQmlPropertyCache::firstCppMetaObject() const
diff --git a/src/qml/qml/qqmlpropertycache_p.h b/src/qml/qml/qqmlpropertycache_p.h
index 14be99045f..2804f66dbe 100644
--- a/src/qml/qml/qqmlpropertycache_p.h
+++ b/src/qml/qml/qqmlpropertycache_p.h
@@ -294,6 +294,7 @@ public:
QString defaultPropertyName() const;
QQmlPropertyData *defaultProperty() const;
QQmlPropertyCache *parent() const;
+ void setParent(QQmlPropertyCache *newParent);
inline QQmlPropertyData *overrideData(QQmlPropertyData *) const;
inline bool isAllowedInRevision(QQmlPropertyData *) const;
diff --git a/src/qml/qml/v8/qv8engine_p.h b/src/qml/qml/v8/qv8engine_p.h
index 1c107bd9bf..8320a89706 100644
--- a/src/qml/qml/v8/qv8engine_p.h
+++ b/src/qml/qml/v8/qv8engine_p.h
@@ -86,7 +86,7 @@
namespace v8 {
// Needed for V8ObjectSet
-inline uint qHash(const v8::Handle<v8::Object> &object, uint seed)
+inline uint qHash(const v8::Handle<v8::Object> &object, uint seed = 0)
{
return (object->GetIdentityHash() ^ seed);
}