[MessageLoopCurrent] Better ScopedNestableTaskAllower API
Using MessageLoopCurrent* was an incorrect move of the old code. In this case the preferred type would be a MessageLoopCurrent (which is a proxy for a MessageLoop*), but we can't define ScopedNestableTaskAllower with a MessageLoopCurrent member because MessageLoopCurrent isn't fully defined by the time the inner-class is defined. Instead use a MessageLoop* member like before and move the impl to .cc Also deprecating the old constructor which required a pointless indirection: base::MessageLoop* loop = base::MessageLoop::current(); base::MessageLoop::ScopedNestableTaskAllower allow_nested(loop); I will follow-up with a scripted cleanup to remove such usage. R=kylechar@chromium.org, thestig@chromium.org Bug: 825327 Change-Id: I28c68d6450cf7c1743908118ce4dc2b4e09a4e76 Reviewed-on: https://chromium-review.googlesource.com/1014267Reviewed-by:Lei Zhang <thestig@chromium.org> Reviewed-by:
kylechar <kylechar@chromium.org> Commit-Queue: Gabriel Charette <gab@chromium.org> Cr-Commit-Position: refs/heads/master@{#551194}
Showing
Please register or sign in to comment