From 3fa1ee3c6b04d0793ccca3f903797625f7a08d03 Mon Sep 17 00:00:00 2001 From: Elvis Angelaccio Date: Sun, 30 Apr 2017 15:19:31 +0200 Subject: Port to categorized logging This greatly reduces the noise made by quaternion. To enable full logging, export the following variable: QT_LOGGING_RULES="libqmatrixclient.*.debug=true" --- connection.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'connection.cpp') diff --git a/connection.cpp b/connection.cpp index 25786361..0fc23f2f 100644 --- a/connection.cpp +++ b/connection.cpp @@ -74,7 +74,7 @@ Connection::Connection() Connection::~Connection() { - qDebug() << "deconstructing connection object for" << d->userId; + qCDebug(MAIN) << "deconstructing connection object for" << d->userId; delete d; } @@ -121,10 +121,10 @@ void Connection::connectWithToken(QString userId, QString token) d->isConnected = true; d->userId = userId; d->data->setToken(token); - qDebug() << "Accessing" << d->data->baseUrl() + qCDebug(MAIN) << "Accessing" << d->data->baseUrl() << "by user" << userId << "with the following access token:"; - qDebug() << token; + qCDebug(MAIN) << token; emit connected(); } @@ -307,7 +307,7 @@ Room* Connection::provideRoom(QString id) { if (id.isEmpty()) { - qDebug() << "Connection::provideRoom() with empty id, doing nothing"; + qCDebug(MAIN) << "Connection::provideRoom() with empty id, doing nothing"; return nullptr; } -- cgit v1.2.3