[SCM] ktp-common-internals packaging branch, master, updated. debian/15.12.1-2-1839-gf0635e9
Maximiliano Curia
maxy at moszumanska.debian.org
Mon May 9 09:07:27 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-common-internals.git;a=commitdiff;h=ff3a2d6
The following commit has been merged in the master branch:
commit ff3a2d626ace980c57888fbb3048091de156fae2
Author: Vishesh Handa <handa.vish at gmail.com>
Date: Thu Feb 16 18:31:49 2012 +0530
Minor cleanup: Remove unnecessary debug statements
---
kpeople/nepomuk-feeder/account.cpp | 6 ++----
kpeople/nepomuk-feeder/contact.cpp | 2 +-
kpeople/nepomuk-feeder/nepomuk-storage.cpp | 33 ++++++++++++++----------------
3 files changed, 18 insertions(+), 23 deletions(-)
diff --git a/kpeople/nepomuk-feeder/account.cpp b/kpeople/nepomuk-feeder/account.cpp
index ebba079..4fef2b2 100644
--- a/kpeople/nepomuk-feeder/account.cpp
+++ b/kpeople/nepomuk-feeder/account.cpp
@@ -114,7 +114,7 @@ void Account::onConnectionChanged(const Tp::ConnectionPtr &connection)
void Account::onContactManagerStateChanged(Tp::ContactListState state)
{
- kDebug() << "contact manager state changed to " << state;
+// kDebug() << "contact manager state changed to " << state;
if (state == Tp::ContactListStateSuccess) {
Tp::Contacts contacts = m_connection->contactManager()->allKnownContacts();
@@ -130,10 +130,9 @@ void Account::onContactManagerStateChanged(Tp::ContactListState state)
// Create wrapper objects for all the Contacts.
foreach (const Tp::ContactPtr &contact, contacts) {
- kDebug();
onNewContact(contact);
}
- kDebug() << "Loop over.";
+// kDebug() << "Loop over.";
}
}
@@ -164,7 +163,6 @@ void Account::onAllKnownContactsChanged(const Tp::Contacts& added, const Tp::Con
void Account::onNewContact(const Tp::ContactPtr &contact)
{
- kDebug();
// Only create a new contact if one doesn't already exist.
if (!m_contacts.contains(contact)) {
// Create a new Contact wrapper objectPath
diff --git a/kpeople/nepomuk-feeder/contact.cpp b/kpeople/nepomuk-feeder/contact.cpp
index b182173..9bc953d 100644
--- a/kpeople/nepomuk-feeder/contact.cpp
+++ b/kpeople/nepomuk-feeder/contact.cpp
@@ -34,7 +34,7 @@ Contact::Contact(const Tp::ContactPtr &contact, QObject *parent)
{
// Do nothing here because the signals/slots need to be connected in our
// parent class before we start doing stuff.
- kDebug() << "Creating new contact";
+ //kDebug() << "Creating new contact";
}
void Contact::init()
diff --git a/kpeople/nepomuk-feeder/nepomuk-storage.cpp b/kpeople/nepomuk-feeder/nepomuk-storage.cpp
index 7a64bf1..bb70366 100644
--- a/kpeople/nepomuk-feeder/nepomuk-storage.cpp
+++ b/kpeople/nepomuk-feeder/nepomuk-storage.cpp
@@ -508,26 +508,26 @@ void NepomukStorage::onContactsQueryNewEntries(const QList< Nepomuk::Query::Resu
QUrl foundImAccountAccessedBy(result.additionalBinding("accessedBy").toUrl());
QString foundImAccountIdentifier(result.additionalBinding("accountIdentifier").toString());
- kDebug() << "Account Identifier: " << foundImAccountIdentifier;
- kDebug() << "PIMO:Person" << foundPerson;
+ //kDebug() << "Account Identifier: " << foundImAccountIdentifier;
+ //kDebug() << "PIMO:Person" << foundPerson;
// Check that the IM account only has one ID.
QStringList accountIDs = result.additionalBinding("imIds").toStringList();
if (accountIDs.size() != 1) {
kWarning() << "Account does not have 1 ID. Oops. Ignoring."
- << "Number of Identifiers: "
- << accountIDs.size();
+ << "Number of Identifiers: "
+ << accountIDs.size();
continue;
}
- kDebug() << "IM ID:" << accountIDs.first();
+ //kDebug() << "IM ID:" << accountIDs.first();
// Cache the contact
m_contacts.insert(ContactIdentifier(foundImAccountIdentifier,
accountIDs.first()),
ContactResources(foundPerson, foundPersonContact, foundImAccount));
- kDebug() << "Contact found in Nepomuk. Caching.";
+ //kDebug() << "Contact found in Nepomuk. Caching.";
}
}
@@ -559,9 +559,6 @@ void NepomukStorage::onContactsQueryFinishedListing()
void NepomukStorage::cleanupAccounts(const QList<QString> &paths)
{
- kDebug() << paths;
- kDebug() << "Our list: " << m_accounts.keys();
-
QSet<QString> pathSet = paths.toSet();
// Go through all our accounts and remove all the ones that are not there in the path
@@ -579,20 +576,22 @@ void NepomukStorage::cleanupAccounts(const QList<QString> &paths)
// TODO: Do this properly once the ontology supports this
// TODO: What do we do with an account in nepomuk which the use has removed?
// For now we're just deleting them
- KJob *job = Nepomuk::removeResources( removedAccounts, Nepomuk::RemoveSubResoures );
- job->exec();
- if( job->error() ) {
- kWarning() << job->errorString();
+ if( !removedAccounts.isEmpty() ) {
+ KJob *job = Nepomuk::removeResources( removedAccounts, Nepomuk::RemoveSubResoures );
+ job->exec();
+ if( job->error() ) {
+ kWarning() << job->errorString();
+ }
}
// Go through all the accounts that we have received from the controller and create any
// new ones in neponmuk. Do this as a batch job to improve performance.
- foreach (const QString &path, paths) {
+ /*foreach (const QString &path, paths) {
if (!m_accounts.keys().contains(path)) {
// TODO: Implement me to do this as a batch job???
// For now, we just let the constructed signal do this one at a time.
}
- }
+ }*/
}
void NepomukStorage::createAccount(const QString &path, const QString &id, const QString &protocol)
@@ -709,8 +708,6 @@ void NepomukStorage::fireGraphTimer()
void NepomukStorage::cleanupAccountContacts(const QString &path, const QList<QString> &ids)
{
- kDebug() << path << ids;
-
QSet<QString> idSet = ids.toSet();
// Go through all the contacts in the cache and make any that are not in the list we
@@ -728,7 +725,7 @@ void NepomukStorage::cleanupAccountContacts(const QString &path, const QList<QSt
}
// Go through all the contacts that we have received from the account and create any
- // new ones in Nepomuk. Do this as a batch job to improve performance.
+ // new ones in Nepomuk.
QSet<QString> nepomukIds;
foreach( const ContactIdentifier& ci, m_contacts.keys() )
nepomukIds.insert( ci.contactId() );
--
ktp-common-internals packaging
More information about the pkg-kde-commits
mailing list