[Paint Preview] Change PaintPreviewClient callback thread
The callbacks passed to PaintPreviewClient were getting run on an arbitrary thread via PostTask. This is a problem as they should be run on the calling thread such that WeakPtrs bound to them are valid. Fix - Make the callbacks run on the same thread that called capture. - Explicitly run CapturePaintPreviewInternal on the UI thread. Follow-up - Make a dedicated SequencedTaskRunner for executing captures. Bug: 1058079 Change-Id: I1dfa969de613112b4bd1650051e394094dffda5e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2083567 Commit-Queue: Calder Kitagawa <ckitagawa@chromium.org> Reviewed-by:Mehran Mahmoudi <mahmoudi@chromium.org> Cr-Commit-Position: refs/heads/master@{#746517}
Showing
Please register or sign in to comment