qt: fix use after free in `CompositorVideo`
This is intended to replace !7195 (closed) without the controversial changes.
I initially wanted to call destroyCb()
in a queued call, so that CompositorVideo::windowDestroy()
returns before the CompositorVideo
instance is potentially destroyed. However, the IsoCpp FAQ
finds it not evil, so I did not do that:
"Is it legal (and moral) for a member function to say delete this?" "As long as you’re careful, it’s okay (not evil) for an object to commit suicide (delete this)."
Request review @chub.