[qcoreapp] delete event before relocking mutex

Any access to the event loop initiated from event destructor will cause
deadlock because unlocker.relock() will be called earlier then scoped
pointer destructor. So, to fix it w/o changing locking logic another
scoped pointer is created _after_ unlocker to free resources before
relocking. This is exception-safe comparing to option to reset earlier
created pointer after executing sendEvent()

Signed-off-by: Denis Zalevskiy <denis.zalevskiy@jolla.com>