commit | 7a19caba2b657dcdffba1b6f9e856bd2244051a7 | [log] [tgz] |
---|---|---|
author | manuk <manukh@chromium.org> | Thu May 16 17:22:27 2019 |
committer | Commit Bot <commit-bot@chromium.org> | Thu May 16 17:22:27 2019 |
tree | 52c3c15e52fdbfecea3b51e01c9a51378cb2cb6e | |
parent | d6f5bf1c8cf3561ec223b1784a5b3c2f6e1284a5 [diff] |
[omnibox debug]: Track request completion and associate with response Currently, the browser proxy that sends requests to and receives responses from the page handler uses callbacks that don't track the requests they correspond to. Additionally, sending a request cancels previous requests. This makes it difficult to track a request's completion and associate responses with particular requests. With this CL, when making a request from the debug page a promise is returned which resolves with the last response value when the last associated response is received (a request can have multiple responses). Interrupted requests will not resolve. Additionally, this CL wires in the request's input text to the browser proxy's handleNewAutocompleteQuery callback in order to allow it to determine which request the query pertains to. This param is not wired into the similar handleNewAutocompleteResponse callback, as that function's param includes a response which in turn includes the request's input text already (via the host field). Additionally, a few mojom callback handlers which were small enough to justify defining as anonymous functions during the browser proxy's construction have now grown and have been extracted to non-anon functions on the browser proxy class with proper closure annotations. Bug: 963596 Change-Id: Ifbfb86750f272c20e70693bb2539d74e0be09f8a Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1613878 Commit-Queue: manuk hovanesian <manukh@chromium.org> Reviewed-by: Tommy Li <tommycli@chromium.org> Reviewed-by: Dominick Ng <dominickn@chromium.org> Cr-Commit-Position: refs/heads/master@{#660451}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure .