diff options
author | Kent Hansen <kent.hansen@nokia.com> | 2012-02-23 20:41:53 +0100 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-04-18 11:47:17 +0200 |
commit | 6d3676e877da86d9ec8d4c5094ec19c38a6649e7 (patch) | |
tree | bdcd861841b385f1f28f90404055ed5bf3bd7f02 /src/imports | |
parent | d2e40f5dbd6d1a550bc70a7adb8511788eeca031 (diff) |
Adapt to Qt5 meta-object changes
QMetaMethod::signature() has been renamed to methodSignature(), and
returns a QByteArray, not const char *.
Thew new function QMetaMethod::isValid() should be used to check
whether a method is valid (it's a lot cheaper than calling
signature()).
Also use the new QMetaObject::checkConnectArgs() overload that
takes QMetaMethods, not strings, as arguments.
Further improvements can be made by using the new functions
QMetaMethod::name(), parameterCount() and parameterTypes(), but
that will be done in separate commits.
Change-Id: I3e4cfbdc7799d8bce747ef37f07d0d097370e409
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Andrew den Exter <andrew.den-exter@nokia.com>
Diffstat (limited to 'src/imports')
-rw-r--r-- | src/imports/shaders/shadereffectitem.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/imports/shaders/shadereffectitem.cpp b/src/imports/shaders/shadereffectitem.cpp index 9c25aa78..ae44b312 100644 --- a/src/imports/shaders/shadereffectitem.cpp +++ b/src/imports/shaders/shadereffectitem.cpp @@ -785,7 +785,7 @@ void ShaderEffectItem::connectPropertySignals() if (!mp.hasNotifySignal()) qWarning("ShaderEffectItem: property '%s' does not have notification method!", it->constData()); QByteArray signalName("2"); - signalName.append(mp.notifySignal().signature()); + signalName.append(mp.notifySignal().methodSignature()); connect(this, signalName, this, SLOT(markDirty())); } else { qWarning("ShaderEffectItem: '%s' does not have a matching property!", it->constData()); @@ -797,7 +797,7 @@ void ShaderEffectItem::connectPropertySignals() if (pi >= 0) { QMetaProperty mp = metaObject()->property(pi); QByteArray signalName("2"); - signalName.append(mp.notifySignal().signature()); + signalName.append(mp.notifySignal().methodSignature()); connect(this, signalName, source.mapper, SLOT(map())); source.mapper->setMapping(this, i); connect(source.mapper, SIGNAL(mapped(int)), this, SLOT(changeSource(int))); |