[filesapp] Use |value| in DevToolsListener::DispatchProtocolMessage
The DevtoolsListener sends CDP commands to devtools to control it, and uses host->DispatchProtocolMessage to do that via a SendCommandMessage helper see CL:2473621. The signature of DevToolsListener::DispatchProtocolMessage causes some confusion when compared to host->DispatchProtocolMessage: has the same name, is defined by the base class content::DevToolsAgentHostClient so we can't change it, but the TL:DR; is it handles the reverse direction of the devtools interaction - where the devtools host wants to tell us about something (eg., Debugger.scriptParsed) or provide the "response" to a DevtoolsListener CDP command. Call whatever devtools emits a |value|, rather than a response. Values in DevToolsListener::DispatchProtocolMessage are 1) a "message", which always have a "method" in their value or else 2) a command "response", which have an "id" in their value. The "id" is uniquely defined by the associated DevtoolsListener CDP command. Name change only response => value, no change in behavior. And this to add some git blame details about DispatchProtocolMessage. Tbr: benreich Bug: 1113941 Change-Id: I4835eddf1bb3435ad82cdbdf786d9450b08e29ab Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2474214Reviewed-by:Noel Gordon <noel@chromium.org> Commit-Queue: Noel Gordon <noel@chromium.org> Cr-Commit-Position: refs/heads/master@{#817406}
Showing
Please register or sign in to comment