With just a quick read, the only thing that sticks out is this in line 8 of your last code block:
instead of:
Calling delete on a QWidget instance that may still be in use (even though in the previous statement you removed it from what is presumably a parent object) does not allow the Qt event loop to run and process any events associated with either removing the instance or deleting it because delete immediately invalidates the instance and its contents. Calling QObject::deleteLater() schedules the instance for deletion during a future cycle through the event loop, but also allows Qt to first process any events the removal causes using the still-valid instance.Qt Code:
m3DImageHolder->deleteLater();To copy to clipboard, switch view to plain text mode




Reply With Quote

Bookmarks