Fix potential deadlook in threaded renderloop.

Change-Id: I415e632aa4e584c8fca745581f25a676db0eae42
Reviewed-by: Giulio Camuffo <giulio.camuffo@jollamobile.com>
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
The cached objects can be deleted, so keep them in a QPointer.

Change-Id: Ieaebd2e7b9823cbe22efc331e42ceab8fbbda0e8
Task-number: QTBUG-40201
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Merge pull request #42 from sletta/selected-changes

[qtdeclarative] Fix potential renderloop lockup and a crash with repeaters.