diff options
author | Simon Hausmann <simon.hausmann@digia.com> | 2014-03-27 17:07:06 +0100 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-03-28 15:07:03 +0100 |
commit | 0ed744c1ef955cdb94cbd89c58283663da490d7d (patch) | |
tree | e07da64307bb70331ed0a9cbfa78ecd960b57b14 /src/qml/qml/qqmltypeloader_p.h | |
parent | 6bbd173a9cb36021ed284522ac628400469eab2f (diff) |
Various cleanups
* Encapsulate the string pooling for the V4 data generation into a StringGenerator class.
* Move type reference collection into the IR::Document, where it belongs (as it writes
into the typeReferences there)
* const fixes
* Remove unused methods and members
* Store unit and qml unit sizes right in the generated data structure. That makes copying
easier (like we do when generating the QML data based on the JS fields)
Change-Id: I053146ab0b00cc90ac7f72f867415962d1be121b
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Diffstat (limited to 'src/qml/qml/qqmltypeloader_p.h')
-rw-r--r-- | src/qml/qml/qqmltypeloader_p.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/qml/qml/qqmltypeloader_p.h b/src/qml/qml/qqmltypeloader_p.h index 8335ffa7db..43828c572e 100644 --- a/src/qml/qml/qqmltypeloader_p.h +++ b/src/qml/qml/qqmltypeloader_p.h @@ -293,11 +293,10 @@ public: virtual void dependencyComplete(QQmlDataBlob *); protected: - const QString &stringAt(int index) const { Q_ASSERT(m_stringPool); return m_stringPool->at(index); } + virtual QString stringAt(int) const { return QString(); } QQmlTypeLoader *m_typeLoader; QQmlImports m_importCache; - QStringList *m_stringPool; // used to resolve string indices in imports bool m_isSingleton; QHash<const QV4::CompiledData::Import*, int> m_unresolvedImports; QList<QQmlQmldirData *> m_qmldirs; @@ -451,6 +450,8 @@ protected: virtual void allDependenciesDone(); virtual void downloadProgressChanged(qreal); + virtual QString stringAt(int index) const; + private: void resolveTypes(); void compile(); @@ -542,6 +543,8 @@ protected: virtual void dataReceived(const Data &); virtual void done(); + virtual QString stringAt(int index) const; + private: virtual void scriptImported(QQmlScriptBlob *blob, const QV4::CompiledData::Location &location, const QString &qualifier, const QString &nameSpace); |