Den mån 5 nov. 2018 kl 21:35 skrev Thiago Macieira <thiago.macie...@intel.com>: > > On Monday, 5 November 2018 12:07:15 PST Elvis Stansvik wrote: > > If it is to be the same as all other QObjects, then it should maintain > > its current behavior I think. The destruction of children happens in > > the QObject destructor. I don't even think one have to look at the > > QObject destructor docs to understand that - where else would it be > > done, considering the parent/child mechanism is a mechanism common to > > all QObject-derived classes > > Ah, but there's an exception: QWidget's destructor destroys its children, so > that they get to see their parent before the QWidget ceases to be a QWidget.
Ah yes, I was talking about QObjects in general. QWidget is an exception. Having hardly ever relied on that behavior more than indirectly, I almost forgot about it. But seems to me it would be a slippery slope to accept more exceptions. What's next, will I have to implement the destruction myself in my own widgets? :) Elvis > > -- > Thiago Macieira - thiago.macieira (AT) intel.com > Software Architect - Intel Open Source Technology Center > > > > _______________________________________________ > Development mailing list > Development@qt-project.org > http://lists.qt-project.org/mailman/listinfo/development _______________________________________________ Development mailing list Development@qt-project.org http://lists.qt-project.org/mailman/listinfo/development