Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
qgs3daxis: Fix object root memory leak
If an object root entity (`mCubeRoot` or `mAxisRoot`) is not enabled, it means that it does not have a parent because of the `setEnableCube()` and `setEnableAxis()` logic. In that case, it will never be automatically deleted by Qt. Therefore, it creates a memory leak. This issue is fixed by adding a check in the destructor. If an object is not enabled, then it is disabled.
- Loading branch information