Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 41b79e21 authored by Laurent Montel's avatar Laurent Montel 😁

Use Q_EMIT

parent 2f5ab618
......@@ -43,7 +43,7 @@ class Q_DECL_HIDDEN LdapConfigWidget::Private
{
public:
Private(LdapConfigWidget *parent)
: mParent(parent), mFeatures(W_ALL), mProg(nullptr)
: mParent(parent)
{
mainLayout = new QGridLayout(mParent);
mainLayout->setMargin(0);
......@@ -62,7 +62,7 @@ public:
void initWidget();
LdapConfigWidget *mParent = nullptr;
WinFlags mFeatures;
WinFlags mFeatures = W_ALL;
QStringList mQResult;
QString mAttr;
......
......@@ -29,7 +29,6 @@ class LdapControlPrivate : public QSharedData
{
public:
LdapControlPrivate()
: mCritical(false)
{
}
......@@ -43,7 +42,7 @@ public:
QString mOid;
QByteArray mValue;
bool mCritical;
bool mCritical = false;
};
LdapControl::LdapControl()
......
......@@ -165,7 +165,7 @@ void LdapModel::LdapModelPrivate::gotSearchResult(KLDAP::LdapSearch *search)
//emit( layoutChanged() );
// Let the world know we are ready for action
emit m_parent->ready();
Q_EMIT m_parent->ready();
break;
}
......@@ -186,7 +186,7 @@ void LdapModel::LdapModelPrivate::gotSearchResult(KLDAP::LdapSearch *search)
}
m_parent->endInsertRows();
emit m_parent->layoutChanged();
Q_EMIT m_parent->layoutChanged();
}
// Flag that we are no longer searching
......
......@@ -82,7 +82,7 @@ void LdapSearchPrivate::result()
//error happened, but no timeout
mError = mConn->ldapErrorCode();
mErrorString = mConn->ldapErrorString();
emit mParent->result(mParent);
Q_EMIT mParent->result(mParent);
return;
}
......@@ -116,7 +116,7 @@ void LdapSearchPrivate::result()
mError = mConn->ldapErrorCode();
mErrorString = mConn->ldapErrorString();
}
emit mParent->result(mParent);
Q_EMIT mParent->result(mParent);
return;
}
QTimer::singleShot(0, mParent, [this]() { result(); });
......@@ -147,7 +147,7 @@ void LdapSearchPrivate::result()
if (mId == -1) {
mError = mConn->ldapErrorCode();
mErrorString = mConn->ldapErrorString();
emit mParent->result(mParent);
Q_EMIT mParent->result(mParent);
return;
}
//continue with the next page
......@@ -156,13 +156,13 @@ void LdapSearchPrivate::result()
}
}
mFinished = true;
emit mParent->result(mParent);
Q_EMIT mParent->result(mParent);
return;
}
//Found an entry
if (res == LdapOperation::RES_SEARCH_ENTRY) {
emit mParent->data(mParent, mOp.object());
Q_EMIT mParent->data(mParent, mOp.object());
mCount++;
}
......@@ -173,7 +173,7 @@ void LdapSearchPrivate::result()
//If reached the requested entries, indicate it
if (mMaxCount > 0 && mCount == mMaxCount) {
qCDebug(LDAP_LOG) << mCount << " entries reached";
emit mParent->result(mParent);
Q_EMIT mParent->result(mParent);
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment