Make the destroy method optional
Make the destroy method optional

This allows us to avoid calling a destructor on objects
that don't require one. After the memberData change this
should be most objects.

Also fix a bug where we didn't call the destroy() method on
large objects, potentially leaking memory.

Change-Id: I1708055d568d85b0a3876899d35e8c3eb92dd222
Reviewed-by: Simon Hausmann <a975102812d593b3191088e3d0aeaeb6f11dbcf5@digia.com>

mgrunditz/qtdeclarative-2d,qmlc/qtdeclarative,mgrunditz/qtdeclarative-2d,mgrunditz/qtdeclarative-2d,mgrunditz/qtdeclarative-2d,qmlc/qtdeclarative,qmlc/qtdeclarative,qmlc/qtdeclarative,qmlc/qtdeclarative,mgrunditz/qtdeclarative-2d,mgrunditz/qtdeclarative-2d,mgrunditz/qtdeclarative-2d,qmlc/qtdeclarative,qmlc/qtdeclarative,qmlc/qtdeclarative