OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // Defines the IPC messages used by the automation interface. | 5 // Defines the IPC messages used by the automation interface. |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/string16.h" | 10 #include "base/string16.h" |
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
126 int, | 126 int, |
127 int) | 127 int) |
128 | 128 |
129 // This message requests the the title of the tab with the given handle. | 129 // This message requests the the title of the tab with the given handle. |
130 // The return value contains the size of the title string. On error, this | 130 // The return value contains the size of the title string. On error, this |
131 // value should be -1 and empty string. Note that the title can be empty in | 131 // value should be -1 and empty string. Note that the title can be empty in |
132 // which case the size would be 0. | 132 // which case the size would be 0. |
133 IPC_SYNC_MESSAGE_CONTROL1_2(AutomationMsg_TabTitle, | 133 IPC_SYNC_MESSAGE_CONTROL1_2(AutomationMsg_TabTitle, |
134 int, | 134 int, |
135 int, | 135 int, |
136 std::wstring) | 136 string16) |
137 | 137 |
138 // This message requests the url of the tab with the given handle. | 138 // This message requests the url of the tab with the given handle. |
139 // The return value contains a success flag and the URL string. The URL will | 139 // The return value contains a success flag and the URL string. The URL will |
140 // be empty on failure, and it still may be empty on success. | 140 // be empty on failure, and it still may be empty on success. |
141 IPC_SYNC_MESSAGE_CONTROL1_2(AutomationMsg_TabURL, | 141 IPC_SYNC_MESSAGE_CONTROL1_2(AutomationMsg_TabURL, |
142 int /* tab handle */, | 142 int /* tab handle */, |
143 bool /* success flag */, | 143 bool /* success flag */, |
144 GURL) | 144 GURL) |
145 | 145 |
146 // This message notifies the AutomationProxy that a handle that it has | 146 // This message notifies the AutomationProxy that a handle that it has |
147 // previously been given is now invalid. (For instance, if the handle | 147 // previously been given is now invalid. (For instance, if the handle |
148 // represented a window which has now been closed.) The parameter | 148 // represented a window which has now been closed.) The parameter |
149 // value is the handle. | 149 // value is the handle. |
150 IPC_MESSAGE_CONTROL1(AutomationMsg_InvalidateHandle, | 150 IPC_MESSAGE_CONTROL1(AutomationMsg_InvalidateHandle, |
151 int) | 151 int) |
152 | 152 |
153 // This message notifies the AutomationProvider that a handle is no | 153 // This message notifies the AutomationProvider that a handle is no |
154 // longer being used, so it can stop paying attention to the | 154 // longer being used, so it can stop paying attention to the |
155 // associated resource. The parameter value is the handle. | 155 // associated resource. The parameter value is the handle. |
156 IPC_MESSAGE_CONTROL1(AutomationMsg_HandleUnused, | 156 IPC_MESSAGE_CONTROL1(AutomationMsg_HandleUnused, |
157 int) | 157 int) |
158 | 158 |
159 // This message tells the AutomationProvider to provide the given | 159 // This message tells the AutomationProvider to provide the given |
160 // authentication data to the specified tab, in response to an HTTP/FTP | 160 // authentication data to the specified tab, in response to an HTTP/FTP |
161 // authentication challenge. | 161 // authentication challenge. |
162 IPC_SYNC_MESSAGE_CONTROL3_1(AutomationMsg_SetAuth, | 162 IPC_SYNC_MESSAGE_CONTROL3_1(AutomationMsg_SetAuth, |
163 int /* tab handle */, | 163 int /* tab handle */, |
164 std::wstring /* username */, | 164 string16 /* username */, |
165 std::wstring /* password */, | 165 string16 /* password */, |
166 AutomationMsg_NavigationResponseValues /* status */) | 166 AutomationMsg_NavigationResponseValues /* status */) |
167 | 167 |
168 // This message tells the AutomationProvider to cancel the login in the | 168 // This message tells the AutomationProvider to cancel the login in the |
169 // specified tab. | 169 // specified tab. |
170 IPC_SYNC_MESSAGE_CONTROL1_1(AutomationMsg_CancelAuth, | 170 IPC_SYNC_MESSAGE_CONTROL1_1(AutomationMsg_CancelAuth, |
171 int /* tab handle */, | 171 int /* tab handle */, |
172 AutomationMsg_NavigationResponseValues /* status */) | 172 AutomationMsg_NavigationResponseValues /* status */) |
173 | 173 |
174 // Requests that the automation provider ask history for the most recent | 174 // Requests that the automation provider ask history for the most recent |
175 // chain of redirects coming from the given URL. The response must be | 175 // chain of redirects coming from the given URL. The response must be |
(...skipping 12 matching lines...) Expand all Loading... |
188 int /* tab handle */, | 188 int /* tab handle */, |
189 bool /* status */) | 189 bool /* status */) |
190 | 190 |
191 // This message requests that the AutomationProvider executes a JavaScript, | 191 // This message requests that the AutomationProvider executes a JavaScript, |
192 // which is sent embedded in a 'javascript:' URL. | 192 // which is sent embedded in a 'javascript:' URL. |
193 // The javascript is executed in context of child frame whose xpath | 193 // The javascript is executed in context of child frame whose xpath |
194 // is passed as parameter (context_frame). The execution results in | 194 // is passed as parameter (context_frame). The execution results in |
195 // a serialized JSON string response. | 195 // a serialized JSON string response. |
196 IPC_SYNC_MESSAGE_CONTROL3_1(AutomationMsg_DomOperation, | 196 IPC_SYNC_MESSAGE_CONTROL3_1(AutomationMsg_DomOperation, |
197 int /* tab handle */, | 197 int /* tab handle */, |
198 std::wstring /* context_frame */, | 198 string16 /* context_frame */, |
199 std::wstring /* the javascript to be executed */, | 199 string16 /* the javascript to be executed */, |
200 std::string /* the serialized json string containg | 200 std::string /* the serialized json string containg |
201 the result of a javascript | 201 the result of a javascript |
202 execution */) | 202 execution */) |
203 | 203 |
204 // Is the Download Shelf visible for the specified browser? | 204 // Is the Download Shelf visible for the specified browser? |
205 IPC_SYNC_MESSAGE_CONTROL1_1(AutomationMsg_ShelfVisibility, | 205 IPC_SYNC_MESSAGE_CONTROL1_1(AutomationMsg_ShelfVisibility, |
206 int /* browser_handle */, | 206 int /* browser_handle */, |
207 bool /* is_visible */) | 207 bool /* is_visible */) |
208 | 208 |
209 // This message requests the number of constrained windows in the tab with | 209 // This message requests the number of constrained windows in the tab with |
(...skipping 1019 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1229 IPC_SYNC_MESSAGE_CONTROL1_1(AutomationMsg_WaitForBookmarkModelToLoad, | 1229 IPC_SYNC_MESSAGE_CONTROL1_1(AutomationMsg_WaitForBookmarkModelToLoad, |
1230 int /* browser_handle */, | 1230 int /* browser_handle */, |
1231 bool /* success */) | 1231 bool /* success */) |
1232 | 1232 |
1233 // Bookmark addition, modification, and removal. | 1233 // Bookmark addition, modification, and removal. |
1234 // Bookmarks are indexed by their id. | 1234 // Bookmarks are indexed by their id. |
1235 IPC_SYNC_MESSAGE_CONTROL4_1(AutomationMsg_AddBookmarkGroup, | 1235 IPC_SYNC_MESSAGE_CONTROL4_1(AutomationMsg_AddBookmarkGroup, |
1236 int /* browser_handle */, | 1236 int /* browser_handle */, |
1237 int64 /* parent_id */, | 1237 int64 /* parent_id */, |
1238 int /* index */, | 1238 int /* index */, |
1239 std::wstring /* title */, | 1239 string16 /* title */, |
1240 bool /* success */) | 1240 bool /* success */) |
1241 IPC_SYNC_MESSAGE_CONTROL5_1(AutomationMsg_AddBookmarkURL, | 1241 IPC_SYNC_MESSAGE_CONTROL5_1(AutomationMsg_AddBookmarkURL, |
1242 int /* browser_handle */, | 1242 int /* browser_handle */, |
1243 int64 /* parent_id */, | 1243 int64 /* parent_id */, |
1244 int /* index */, | 1244 int /* index */, |
1245 std::wstring /* title */, | 1245 string16 /* title */, |
1246 GURL /* url */, | 1246 GURL /* url */, |
1247 bool /* success */) | 1247 bool /* success */) |
1248 IPC_SYNC_MESSAGE_CONTROL4_1(AutomationMsg_ReparentBookmark, | 1248 IPC_SYNC_MESSAGE_CONTROL4_1(AutomationMsg_ReparentBookmark, |
1249 int /* browser_handle */, | 1249 int /* browser_handle */, |
1250 int64 /* id */, | 1250 int64 /* id */, |
1251 int64 /* new_parent_id */, | 1251 int64 /* new_parent_id */, |
1252 int /* index */, | 1252 int /* index */, |
1253 bool /* success */) | 1253 bool /* success */) |
1254 IPC_SYNC_MESSAGE_CONTROL3_1(AutomationMsg_SetBookmarkTitle, | 1254 IPC_SYNC_MESSAGE_CONTROL3_1(AutomationMsg_SetBookmarkTitle, |
1255 int /* browser_handle */, | 1255 int /* browser_handle */, |
1256 int64 /* id */, | 1256 int64 /* id */, |
1257 std::wstring /* title */, | 1257 string16 /* title */, |
1258 bool /* success */) | 1258 bool /* success */) |
1259 IPC_SYNC_MESSAGE_CONTROL3_1(AutomationMsg_SetBookmarkURL, | 1259 IPC_SYNC_MESSAGE_CONTROL3_1(AutomationMsg_SetBookmarkURL, |
1260 int /* browser_handle */, | 1260 int /* browser_handle */, |
1261 int64 /* id */, | 1261 int64 /* id */, |
1262 GURL /* url */, | 1262 GURL /* url */, |
1263 bool /* success */) | 1263 bool /* success */) |
1264 IPC_SYNC_MESSAGE_CONTROL2_1(AutomationMsg_RemoveBookmark, | 1264 IPC_SYNC_MESSAGE_CONTROL2_1(AutomationMsg_RemoveBookmark, |
1265 int /* browser_handle */, | 1265 int /* browser_handle */, |
1266 int64 /* id */, | 1266 int64 /* id */, |
1267 bool /* success */) | 1267 bool /* success */) |
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1443 // while performing stress testing. | 1443 // while performing stress testing. |
1444 IPC_MESSAGE_ROUTED3(AutomationMsg_JavaScriptStressTestControl, | 1444 IPC_MESSAGE_ROUTED3(AutomationMsg_JavaScriptStressTestControl, |
1445 int /* tab handle */, | 1445 int /* tab handle */, |
1446 int /* command */, | 1446 int /* command */, |
1447 int /* type or run */) | 1447 int /* type or run */) |
1448 | 1448 |
1449 // This message posts a task to the PROCESS_LAUNCHER thread. Once processed | 1449 // This message posts a task to the PROCESS_LAUNCHER thread. Once processed |
1450 // the response is sent back. This is useful when you want to make sure all | 1450 // the response is sent back. This is useful when you want to make sure all |
1451 // changes to the number of processes have completed. | 1451 // changes to the number of processes have completed. |
1452 IPC_SYNC_MESSAGE_CONTROL0_0(AutomationMsg_WaitForProcessLauncherThreadToGoIdle) | 1452 IPC_SYNC_MESSAGE_CONTROL0_0(AutomationMsg_WaitForProcessLauncherThreadToGoIdle) |
OLD | NEW |