[plugins/contacts] Unify coding style

This commit is contained in:
Nicolas Fella 2019-05-04 16:15:49 +02:00
parent aff3d20e7e
commit 137d504b58
2 changed files with 23 additions and 25 deletions

View file

@ -53,7 +53,7 @@ ContactsPlugin::ContactsPlugin (QObject* parent, const QVariantList& args) :
qCWarning(KDECONNECT_PLUGIN_CONTACTS) << "handleResponseVCards:" << "Unable to create VCard directory";
}
this->synchronizeRemoteWithLocal();
synchronizeRemoteWithLocal();
qCDebug(KDECONNECT_PLUGIN_CONTACTS) << "Contacts constructor for device " << device()->name();
}
@ -68,9 +68,9 @@ bool ContactsPlugin::receivePacket (const NetworkPacket& np) {
//qCDebug(KDECONNECT_PLUGIN_CONTACTS) << np.body();
if (np.type() == PACKAGE_TYPE_CONTACTS_RESPONSE_UIDS_TIMESTAMPS) {
return this->handleResponseUIDsTimestamps(np);
return handleResponseUIDsTimestamps(np);
} else if (np.type() == PACKET_TYPE_CONTACTS_RESPONSE_VCARDS) {
return this->handleResponseVCards(np);
return handleResponseVCards(np);
} else {
// Is this check necessary?
qCDebug(KDECONNECT_PLUGIN_CONTACTS) << "Unknown package type received from device: "
@ -80,7 +80,7 @@ bool ContactsPlugin::receivePacket (const NetworkPacket& np) {
}
void ContactsPlugin::synchronizeRemoteWithLocal() {
this->sendRequest(PACKET_TYPE_CONTACTS_REQUEST_ALL_UIDS_TIMESTAMP);
sendRequest(PACKET_TYPE_CONTACTS_REQUEST_ALL_UIDS_TIMESTAMP);
}
bool ContactsPlugin::handleResponseUIDsTimestamps(const NetworkPacket& np) {
@ -150,7 +150,7 @@ bool ContactsPlugin::handleResponseUIDsTimestamps (const NetworkPacket& np) {
toDelete.remove();
}
this->sendRequestWithIDs(PACKET_TYPE_CONTACTS_REQUEST_VCARDS_BY_UIDS, uIDsToUpdate);
sendRequestWithIDs(PACKET_TYPE_CONTACTS_REQUEST_VCARDS_BY_UIDS, uIDsToUpdate);
return true;
}

View file

@ -113,8 +113,7 @@ public Q_SLOTS:
* Update any contacts which are known locally but have an older timestamp
* Add any contacts which are not known locally but are reported by the remote
*/
Q_SCRIPTABLE
void synchronizeRemoteWithLocal ();
Q_SCRIPTABLE void synchronizeRemoteWithLocal();
public:
Q_SIGNALS:
@ -123,8 +122,7 @@ Q_SIGNALS:
*
* @param newContacts The list of just-synchronized contacts
*/
Q_SCRIPTABLE
void localCacheSynchronized (const uIDList_t& newContacts);
Q_SCRIPTABLE void localCacheSynchronized(const uIDList_t& newContacts);
protected: