diff options
Diffstat (limited to 'src/imports/audioengine')
-rw-r--r-- | src/imports/audioengine/qdeclarative_audioengine_p.cpp | 10 | ||||
-rw-r--r-- | src/imports/audioengine/qdeclarative_audioengine_p.h | 10 | ||||
-rw-r--r-- | src/imports/audioengine/qdeclarative_sound_p.cpp | 6 | ||||
-rw-r--r-- | src/imports/audioengine/qdeclarative_sound_p.h | 10 |
4 files changed, 18 insertions, 18 deletions
diff --git a/src/imports/audioengine/qdeclarative_audioengine_p.cpp b/src/imports/audioengine/qdeclarative_audioengine_p.cpp index 659cf655c..dce97f87e 100644 --- a/src/imports/audioengine/qdeclarative_audioengine_p.cpp +++ b/src/imports/audioengine/qdeclarative_audioengine_p.cpp @@ -175,14 +175,14 @@ QDeclarativeSoundInstance* QDeclarativeAudioEngine::newDeclarativeSoundInstance( m_managedDeclSndInstancePool.pop_back(); } else { instance = new QDeclarativeSoundInstance(this); - qmlEngine(instance)->setObjectOwnership(instance, QDeclarativeEngine::CppOwnership); + qmlEngine(instance)->setObjectOwnership(instance, QQmlEngine::CppOwnership); instance->setEngine(this); } m_managedDeclSoundInstances.push_back(instance); } else { instance = new QDeclarativeSoundInstance(); instance->setEngine(this); - qmlEngine(instance)->setObjectOwnership(instance, QDeclarativeEngine::JavaScriptOwnership); + qmlEngine(instance)->setObjectOwnership(instance, QQmlEngine::JavaScriptOwnership); } return instance; } @@ -333,7 +333,7 @@ void QDeclarativeAudioEngine::updateSoundInstances() m_updateTimer.stop(); } -void QDeclarativeAudioEngine::appendFunction(QDeclarativeListProperty<QObject> *property, QObject *value) +void QDeclarativeAudioEngine::appendFunction(QQmlListProperty<QObject> *property, QObject *value) { QDeclarativeAudioEngine* engine = static_cast<QDeclarativeAudioEngine*>(property->object); if (engine->m_complete) { @@ -401,9 +401,9 @@ void QDeclarativeAudioEngine::appendFunction(QDeclarativeListProperty<QObject> * qWarning("Unknown child type for AudioEngine!"); } -QDeclarativeListProperty<QObject> QDeclarativeAudioEngine::bank() +QQmlListProperty<QObject> QDeclarativeAudioEngine::bank() { - return QDeclarativeListProperty<QObject>(this, 0, appendFunction); + return QQmlListProperty<QObject>(this, 0, appendFunction); } /*! diff --git a/src/imports/audioengine/qdeclarative_audioengine_p.h b/src/imports/audioengine/qdeclarative_audioengine_p.h index 527426a7e..c99b3417c 100644 --- a/src/imports/audioengine/qdeclarative_audioengine_p.h +++ b/src/imports/audioengine/qdeclarative_audioengine_p.h @@ -88,7 +88,7 @@ public: //This is used for tracking all objects declared inside AudioEngine //see appendFunction - QDeclarativeListProperty<QObject> bank(); + QQmlListProperty<QObject> bank(); QObject* categories(); QObject* samples(); @@ -136,13 +136,13 @@ private: bool m_complete; //see bank() - static void appendFunction(QDeclarativeListProperty<QObject> *property, QObject *value); + static void appendFunction(QQmlListProperty<QObject> *property, QObject *value); QDeclarativeAudioListener *m_listener; QDeclarativeAudioCategory* m_defaultCategory; - QDeclarativePropertyMap m_categories; - QDeclarativePropertyMap m_samples; - QDeclarativePropertyMap m_sounds; + QQmlPropertyMap m_categories; + QQmlPropertyMap m_samples; + QQmlPropertyMap m_sounds; //Use strong type here since no need to for AttenuationModel to be accessible directly by user //after config stage diff --git a/src/imports/audioengine/qdeclarative_sound_p.cpp b/src/imports/audioengine/qdeclarative_sound_p.cpp index 37980c117..5b333c22d 100644 --- a/src/imports/audioengine/qdeclarative_sound_p.cpp +++ b/src/imports/audioengine/qdeclarative_sound_p.cpp @@ -360,9 +360,9 @@ void QDeclarativeSound::setCategoryObject(QDeclarativeAudioCategory *categoryObj m_categoryObject = categoryObject; } -QDeclarativeListProperty<QDeclarativePlayVariation> QDeclarativeSound::playVariationlist() +QQmlListProperty<QDeclarativePlayVariation> QDeclarativeSound::playVariationlist() { - return QDeclarativeListProperty<QDeclarativePlayVariation>(this, 0, appendFunction); + return QQmlListProperty<QDeclarativePlayVariation>(this, 0, appendFunction); } QList<QDeclarativePlayVariation*>& QDeclarativeSound::playlist() @@ -370,7 +370,7 @@ QList<QDeclarativePlayVariation*>& QDeclarativeSound::playlist() return m_playlist; } -void QDeclarativeSound::appendFunction(QDeclarativeListProperty<QDeclarativePlayVariation> *property, QDeclarativePlayVariation *value) +void QDeclarativeSound::appendFunction(QQmlListProperty<QDeclarativePlayVariation> *property, QDeclarativePlayVariation *value) { QDeclarativeSound *sound = static_cast<QDeclarativeSound*>(property->object); if (sound->m_complete) { diff --git a/src/imports/audioengine/qdeclarative_sound_p.h b/src/imports/audioengine/qdeclarative_sound_p.h index 7184af97b..7f826b38a 100644 --- a/src/imports/audioengine/qdeclarative_sound_p.h +++ b/src/imports/audioengine/qdeclarative_sound_p.h @@ -84,18 +84,18 @@ private: qreal m_outerGain; }; -class QDeclarativeSound : public QObject, public QDeclarativeParserStatus +class QDeclarativeSound : public QObject, public QQmlParserStatus { friend class QDeclarativeSoundCone; Q_OBJECT - Q_INTERFACES(QDeclarativeParserStatus) + Q_INTERFACES(QQmlParserStatus) Q_PROPERTY(QString name READ name WRITE setName) Q_PROPERTY(PlayType playType READ playType WRITE setPlayType) Q_PROPERTY(QString category READ category WRITE setCategory) Q_PROPERTY(QDeclarativeSoundCone* cone READ cone CONSTANT) Q_PROPERTY(QString attenuationModel READ attenuationModel WRITE setAttenuationModel) - Q_PROPERTY(QDeclarativeListProperty<QDeclarativePlayVariation> playVariationlist READ playVariationlist CONSTANT) + Q_PROPERTY(QQmlListProperty<QDeclarativePlayVariation> playVariationlist READ playVariationlist CONSTANT) Q_CLASSINFO("DefaultProperty", "playVariationlist") Q_ENUMS(PlayType) @@ -135,7 +135,7 @@ public: QDeclarativePlayVariation* getVariation(int index); //This is used for tracking new PlayVariation declared inside Sound - QDeclarativeListProperty<QDeclarativePlayVariation> playVariationlist(); + QQmlListProperty<QDeclarativePlayVariation> playVariationlist(); QList<QDeclarativePlayVariation*>& playlist(); public Q_SLOTS: @@ -156,7 +156,7 @@ public Q_SLOTS: private: Q_DISABLE_COPY(QDeclarativeSound) QDeclarativeSoundInstance* newInstance(bool managed); - static void appendFunction(QDeclarativeListProperty<QDeclarativePlayVariation> *property, QDeclarativePlayVariation *value); + static void appendFunction(QQmlListProperty<QDeclarativePlayVariation> *property, QDeclarativePlayVariation *value); bool m_complete; PlayType m_playType; QString m_name; |