Coalesce load state changes in MojoProxyResolverImpl.

When the load state of a ProxyResolver changes from DNS resolution to
running the proxy script, the time before either the script completing
or making another DNS request is usually short: <1ms. Since the load
state is used only for UI, these updates are triggering wasteful IPCs.
This CL fixes this by adding a wait of 10ms before reporting load state
changes, coalescing them with later changes if they occur during that
wait.

BUG=11746

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

Cr-Commit-Position: refs/heads/master@{#320258}
7 files changed