Makes bindings work with nested message loops

Dispatching a message may result in a nested message loop. When
dispatching a message we need to start a wait before dispatch, so that
if a nested message loop does result we continue dispatching messages.

BUG=none
TEST=covered by tests.
R=yzshen@chromium.org

Review URL: https://codereview.chromium.org/1576603002

Cr-Commit-Position: refs/heads/master@{#368608}


CrOS-Libchrome-Original-Commit: f8701563b0f1e831028676042eb59e2cd27374be
4 files changed
tree: 9baad9c91dd6cbc56115248024d000df2d57e570
  1. base/
  2. build/
  3. components/
  4. dbus/
  5. device/
  6. ipc/
  7. mojo/
  8. testing/
  9. third_party/
  10. ui/