Make the parent in Partition a QPointer.
This also reverts commit dc9e9651ac59f58516a153c429532cc8c55142fd.