connection is normally returned from Qt's connect, and the caller may want to
track the connection to manually disconnect it.
(cherry picked from commit 41b2b35ce3)
c-toxcore calls the groupCallCallback from it's main thread instead of
the ToxAV thread as expected, this was triggering an assertion.
Aditionally the destructors of Core and CoreAV were fixed, because they
now either crashed or deadlocked qTox when it was closed while a group
call was still running.
(cherry picked from commit 141cbf8870)
This actually fixes two problems:
1) CoreAV and Audio thread both locked the callsLock and audioLock in
different orders, resulting in a deadlock of both threads. This fixed by
using a ReadWriteLock in the CoreAV thread.
2) Multiple functions were emitting signals while holding a lock. This
is unsafe, because the connected slot may acquire any other lock. This
is fixed by releasing the locks before emitting signals.
(cherry picked from commit 4b9e4a571d)
It doesn't really make sense to assert that the callbacks are coming
from any other thread than CoreAV, when we actually want to ensure the
callback is coming from Core thread.
Remove over agressive assert from sendGroupCallAudio(...), this function
should be callable from any thread.
(cherry picked from commit 9499925fb2)
We we're calling toxav_* functions without synchronizing to any of the
Tox threads.
Additionally remove the call timeout, it creates timers from different
threads, which causes errors.
(cherry picked from commit 98cfe9838f)
This commit fixes the behavior when a message is received while the
chatlog is scrolled to the bottom. With this change, the chatlog will
stick to the bottom when it is scrolled all the way down. If it is
somewhere in the middle (e.g. for search) the chatlog will not change
its position.
In other applications chatrooms allow you to idle in a call and have
people hop in and out as desired. If a user is the only one presently
online in a group but knows someone will be joining shortly they should
be able to join the call ahead of time.
Qt doesn't support QObject multiple inheritance, so use our existing interface
macros to declare signals in the interface without QObject, and implement them
in child classes.