Let Screenshot Parent get destroyed on the main thread.

Currently the reference to Screenshot Parent is held by the
LayerRenderArea class. That object loses its last reference on the
binder thread so the Screenshot Parent is destroyed on the binder
thread. To keep things consistent, it's best if the Layer is destroyed
on the main thread, like other layers.

By removing the reference to Screenshot Parent in LayerRenderArea and
only having a reference in RenderForDrawing, it ensures that the last
reference to the Screenshot Parent is dropped on the main thread.

Test: Screenshot Parent destructor is called on main thread.
Change-Id: I82f641a063102584d0a2eddb8a6b11546ed777b2
1 file changed