On 15/12/12 07:07, Thiago Macieira wrote: > On sábado, 15 de dezembro de 2012 06.50.07, Nikos Chantziaras wrote: >> On 15/12/12 06:33, Thiago Macieira wrote: >>> I don't see your point. QObject::connect adds the connection object to a >>> list. QObject::~QObject destroys the list. >> >> What I don't get is how QObject::connect() can tell where it was called >> from. > > It can't.
That's what my question was actually about :) Thanks for confirming. >> How does it get to know that the 'foo' object is doing the >> connection? What if the connection is made from a non-member function? >> [...] > > That's the point. It can't. This connection has absolutely no way of knowing > when the receiver is deleted. It's entirely up to you to deal with it. > > There's an overload that accepts a receiver object and a functor as > parameters. I suppose it's undocumented at the moment then. I was looking for it, since I imagined it would exist, but didn't find it in the docs which prompted me to post the question. _______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest