mirror of
https://github.com/overte-org/overte.git
synced 2025-08-08 00:10:52 +02:00
Removed json callback
This commit is contained in:
parent
3acbaa7ab6
commit
90a27bb118
1 changed files with 1 additions and 8 deletions
|
@ -83,17 +83,10 @@ void UserActivityLogger::close(int delayTime) {
|
||||||
|
|
||||||
// In order to get the end of the session, we need to give the account manager enough time to send the packet.
|
// In order to get the end of the session, we need to give the account manager enough time to send the packet.
|
||||||
QEventLoop loop;
|
QEventLoop loop;
|
||||||
// Here we connect the callbacks to stop the event loop
|
|
||||||
JSONCallbackParameters params;
|
|
||||||
params.jsonCallbackReceiver = &loop;
|
|
||||||
params.errorCallbackReceiver = &loop;
|
|
||||||
params.jsonCallbackMethod = "quit";
|
|
||||||
params.errorCallbackMethod = "quit";
|
|
||||||
// In case something goes wrong, we also setup a timer so that the delai is not greater than delayTime
|
|
||||||
QTimer timer;
|
QTimer timer;
|
||||||
connect(&timer, &QTimer::timeout, &loop, &QEventLoop::quit);
|
connect(&timer, &QTimer::timeout, &loop, &QEventLoop::quit);
|
||||||
// Now we can log it
|
// Now we can log it
|
||||||
logAction(ACTION_NAME, QJsonObject(), params);
|
logAction(ACTION_NAME, QJsonObject());
|
||||||
timer.start(delayTime);
|
timer.start(delayTime);
|
||||||
loop.exec();
|
loop.exec();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue