OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // This header is meant to be included in multiple passes, hence no traditional | |
6 // header guard. | |
7 // See ipc_message_macros.h for explanation of the macros and passes. | |
8 | |
9 // Developer tools consist of the following parts: | 5 // Developer tools consist of the following parts: |
10 // | 6 // |
11 // DevToolsAgent lives in the renderer of an inspected page and provides access | 7 // DevToolsAgent lives in the renderer of an inspected page and provides access |
12 // to the pages resources, DOM, v8 etc. by means of IPC messages. | 8 // to the pages resources, DOM, v8 etc. by means of IPC messages. |
13 // | 9 // |
14 // DevToolsClient is a thin delegate that lives in the tools front-end | 10 // DevToolsClient is a thin delegate that lives in the tools front-end |
15 // renderer and converts IPC messages to frontend method calls and allows the | 11 // renderer and converts IPC messages to frontend method calls and allows the |
16 // frontend to send messages to the DevToolsAgent. | 12 // frontend to send messages to the DevToolsAgent. |
17 // | 13 // |
18 // All the messages are routed through browser process. There is a | 14 // All the messages are routed through browser process. There is a |
(...skipping 18 matching lines...) Expand all Loading... |
37 // --------------------------+-------- | 33 // --------------------------+-------- |
38 // | inspected page <--> DevToolsAgent | | 34 // | inspected page <--> DevToolsAgent | |
39 // | | | 35 // | | |
40 // | (inspected page renderer process) | | 36 // | (inspected page renderer process) | |
41 // ----------------------------------- | 37 // ----------------------------------- |
42 // | 38 // |
43 // This file describes developer tools message types. | 39 // This file describes developer tools message types. |
44 | 40 |
45 #include "ipc/ipc_message_macros.h" | 41 #include "ipc/ipc_message_macros.h" |
46 | 42 |
| 43 #define IPC_MESSAGE_START DevToolsMsgStart |
| 44 |
47 // These are messages sent from DevToolsAgent to DevToolsClient through the | 45 // These are messages sent from DevToolsAgent to DevToolsClient through the |
48 // browser. | 46 // browser. |
49 IPC_BEGIN_MESSAGES(DevToolsClient) | 47 // WebKit-level transport. |
| 48 IPC_MESSAGE_CONTROL1(DevToolsClientMsg_DispatchOnInspectorFrontend, |
| 49 std::string /* message */) |
50 | 50 |
51 // WebKit-level transport. | 51 // Legacy debugger output message. |
52 IPC_MESSAGE_CONTROL1(DevToolsClientMsg_DispatchOnInspectorFrontend, | 52 IPC_MESSAGE_CONTROL1(DevToolsClientMsg_DebuggerOutput, |
53 std::string /* message */) | 53 std::string /* message */) |
54 | 54 |
55 // Legacy debugger output message. | 55 // Legacy APU dispatch message. |
56 IPC_MESSAGE_CONTROL1(DevToolsClientMsg_DebuggerOutput, | 56 IPC_MESSAGE_CONTROL1(DevToolsClientMsg_DispatchToAPU, |
57 std::string /* message */) | 57 std::string /* message */) |
58 | |
59 // Legacy APU dispatch message. | |
60 IPC_MESSAGE_CONTROL1(DevToolsClientMsg_DispatchToAPU, | |
61 std::string /* message */) | |
62 | |
63 IPC_END_MESSAGES(DevToolsClient) | |
64 | 58 |
65 | 59 |
66 //----------------------------------------------------------------------------- | 60 //----------------------------------------------------------------------------- |
67 // These are messages sent from DevToolsClient to DevToolsAgent through the | 61 // These are messages sent from DevToolsClient to DevToolsAgent through the |
68 // browser. | 62 // browser. |
69 IPC_BEGIN_MESSAGES(DevToolsAgent) | 63 // Tells agent that there is a client host connected to it. |
| 64 IPC_MESSAGE_CONTROL1(DevToolsAgentMsg_Attach, |
| 65 DevToolsRuntimeProperties /* properties */) |
70 | 66 |
71 // Tells agent that there is a client host connected to it. | 67 // Tells agent that there is no longer a client host connected to it. |
72 IPC_MESSAGE_CONTROL1(DevToolsAgentMsg_Attach, | 68 IPC_MESSAGE_CONTROL0(DevToolsAgentMsg_Detach) |
73 DevToolsRuntimeProperties /* properties */) | |
74 | 69 |
75 // Tells agent that there is no longer a client host connected to it. | 70 // Tells agent that the front-end has been loaded |
76 IPC_MESSAGE_CONTROL0(DevToolsAgentMsg_Detach) | 71 IPC_MESSAGE_CONTROL0(DevToolsAgentMsg_FrontendLoaded) |
77 | 72 |
78 // Tells agent that the front-end has been loaded | 73 // WebKit-level transport. |
79 IPC_MESSAGE_CONTROL0(DevToolsAgentMsg_FrontendLoaded) | 74 IPC_MESSAGE_CONTROL1(DevToolsAgentMsg_DispatchOnInspectorBackend, |
| 75 std::string /* message */) |
80 | 76 |
81 // WebKit-level transport. | 77 // Send debugger command to the debugger agent. Debugger commands should |
82 IPC_MESSAGE_CONTROL1(DevToolsAgentMsg_DispatchOnInspectorBackend, | 78 // be handled on IO thread(while all other devtools messages are handled in |
83 std::string /* message */) | 79 // the render thread) to allow executing the commands when v8 is on a |
| 80 // breakpoint. |
| 81 IPC_MESSAGE_CONTROL1(DevToolsAgentMsg_DebuggerCommand, |
| 82 std::string /* command */) |
84 | 83 |
85 // Send debugger command to the debugger agent. Debugger commands should | 84 // Inspect element with the given coordinates. |
86 // be handled on IO thread(while all other devtools messages are handled in | 85 IPC_MESSAGE_CONTROL2(DevToolsAgentMsg_InspectElement, |
87 // the render thread) to allow executing the commands when v8 is on a | 86 int /* x */, |
88 // breakpoint. | 87 int /* y */) |
89 IPC_MESSAGE_CONTROL1(DevToolsAgentMsg_DebuggerCommand, | |
90 std::string /* command */) | |
91 | 88 |
92 // Inspect element with the given coordinates. | 89 // Enables/disables the apu agent. |
93 IPC_MESSAGE_CONTROL2(DevToolsAgentMsg_InspectElement, | 90 IPC_MESSAGE_CONTROL1(DevToolsAgentMsg_SetApuAgentEnabled, bool /* enabled */) |
94 int /* x */, | |
95 int /* y */) | |
96 | |
97 // Enables/disables the apu agent. | |
98 IPC_MESSAGE_CONTROL1(DevToolsAgentMsg_SetApuAgentEnabled, bool /* enabled */) | |
99 | |
100 IPC_END_MESSAGES(DevToolsAgent) | |
OLD | NEW |