In early Qt 5 versions I have to disconnect lambdas from signals as shown here: "Disconnecting lambda functions in Qt5".
Here I found the following statement: There is no automatic disconnection when the 'receiver' is destroyed because it's a functor with no QObject. However, since 5.2 there is an overload which adds a "context object". When that object is destroyed, the connection is broken (the context is also used for the thread affinity: the lambda will be called in the thread of the event loop of the object used as context).
- Does it mean I have no longer to disconnect lambdas with Qt5.2 or later?
- Do I have to pass that context or is that done automatically?