Don't call metaObject() redundantly
The desired meta-object is already stored in a local variable. Change-Id: I40c7840f07f5dbd67110e2f7d5bb618cbb269047 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
d0c0360392
commit
ec508e9a6a
@ -3220,7 +3220,7 @@ void QMetaObject::connectSlotsByName(QObject *o)
|
|||||||
if (sigIndex < 0) { // search for compatible signals
|
if (sigIndex < 0) { // search for compatible signals
|
||||||
const QMetaObject *smo = co->metaObject();
|
const QMetaObject *smo = co->metaObject();
|
||||||
int slotlen = qstrlen(slot + len + 4) - 1;
|
int slotlen = qstrlen(slot + len + 4) - 1;
|
||||||
for (int k = 0; k < co->metaObject()->methodCount(); ++k) {
|
for (int k = 0; k < smo->methodCount(); ++k) {
|
||||||
QMetaMethod method = smo->method(k);
|
QMetaMethod method = smo->method(k);
|
||||||
if (method.methodType() != QMetaMethod::Signal)
|
if (method.methodType() != QMetaMethod::Signal)
|
||||||
continue;
|
continue;
|
||||||
|
Loading…
Reference in New Issue
Block a user