| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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 // This header is meant to be included in multiple passes, hence no traditional | 7 // This header is meant to be included in multiple passes, hence no traditional |
| 8 // header guard. | 8 // header guard. |
| 9 // See ipc_message_macros.h for explanation of the macros and passes. | 9 // See ipc_message_macros.h for explanation of the macros and passes. |
| 10 | 10 |
| (...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 150 | 150 |
| 151 // This message requests the url of the tab with the given handle. | 151 // This message requests the url of the tab with the given handle. |
| 152 // The return value contains a success flag and the URL string. The URL will | 152 // The return value contains a success flag and the URL string. The URL will |
| 153 // be empty on failure, and it still may be empty on success. | 153 // be empty on failure, and it still may be empty on success. |
| 154 IPC_SYNC_MESSAGE_ROUTED1_2(AutomationMsg_TabURL, | 154 IPC_SYNC_MESSAGE_ROUTED1_2(AutomationMsg_TabURL, |
| 155 int /* tab handle */, | 155 int /* tab handle */, |
| 156 bool /* success flag */, | 156 bool /* success flag */, |
| 157 GURL) | 157 GURL) |
| 158 | 158 |
| 159 #if defined(OS_WIN) | 159 #if defined(OS_WIN) |
| 160 // TODO(port): Port these messages. | 160 // TODO(estade): delete this unused message. |
| 161 // | 161 IPC_SYNC_MESSAGE_ROUTED0_0(AutomationMsg_WindowHWND) |
| 162 // This message requests the HWND of the top-level window that corresponds | |
| 163 // to the given automation handle. | |
| 164 // The return value contains the HWND value, which is 0 if the call fails. | |
| 165 IPC_SYNC_MESSAGE_ROUTED1_1(AutomationMsg_WindowHWND, | |
| 166 int /* automation handle */, | |
| 167 HWND /* Win32 handle */ ) | |
| 168 | 162 |
| 169 // This message requests the HWND of the tab that corresponds | 163 // This message requests the HWND of the tab that corresponds |
| 170 // to the given automation handle. | 164 // to the given automation handle. |
| 171 // The return value contains the HWND value, which is 0 if the call fails. | 165 // The return value contains the HWND value, which is 0 if the call fails. |
| 166 // |
| 167 // TODO(estade): The only test that uses this message is |
| 168 // NPAPIVisiblePluginTester.SelfDeletePluginInvokeInSynchronousMouseMove. It |
| 169 // can probably be done in another way, and this can be removed. |
| 172 IPC_SYNC_MESSAGE_ROUTED1_1(AutomationMsg_TabHWND, | 170 IPC_SYNC_MESSAGE_ROUTED1_1(AutomationMsg_TabHWND, |
| 173 int /* tab_handle */, | 171 int /* tab_handle */, |
| 174 HWND /* win32 Window Handle */) | 172 HWND /* win32 Window Handle */) |
| 175 #endif // defined(OS_WIN) | 173 #endif // defined(OS_WIN) |
| 176 | 174 |
| 177 // This message notifies the AutomationProxy that a handle that it has | 175 // This message notifies the AutomationProxy that a handle that it has |
| 178 // previously been given is now invalid. (For instance, if the handle | 176 // previously been given is now invalid. (For instance, if the handle |
| 179 // represented a window which has now been closed.) The parameter | 177 // represented a window which has now been closed.) The parameter |
| 180 // value is the handle. | 178 // value is the handle. |
| 181 IPC_MESSAGE_ROUTED1(AutomationMsg_InvalidateHandle, int) | 179 IPC_MESSAGE_ROUTED1(AutomationMsg_InvalidateHandle, int) |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 273 // bool - true if the resize was successful | 271 // bool - true if the resize was successful |
| 274 IPC_SYNC_MESSAGE_ROUTED2_1(AutomationMsg_SetWindowBounds, int, gfx::Rect, | 272 IPC_SYNC_MESSAGE_ROUTED2_1(AutomationMsg_SetWindowBounds, int, gfx::Rect, |
| 275 bool) | 273 bool) |
| 276 | 274 |
| 277 #if defined(OS_WIN) | 275 #if defined(OS_WIN) |
| 278 // TODO(port): Port these messages. | 276 // TODO(port): Port these messages. |
| 279 // | 277 // |
| 280 // This message requests that a drag be performed in window coordinate space | 278 // This message requests that a drag be performed in window coordinate space |
| 281 // Request: | 279 // Request: |
| 282 // int - the handle of the window that's the context for this drag | 280 // int - the handle of the window that's the context for this drag |
| 283 // std::vector<POINT> - the path of the drag in window coordinate space; | 281 // std::vector<gfx::Point> - the path of the drag in window coordinate |
| 284 // it should have at least 2 points (start and end) | 282 // space; it should have at least 2 points |
| 283 // (start and end) |
| 285 // int - the flags which identify the mouse button(s) for the drag, as | 284 // int - the flags which identify the mouse button(s) for the drag, as |
| 286 // defined in chrome/views/event.h | 285 // defined in chrome/views/event.h |
| 287 // Response: | 286 // Response: |
| 288 // bool - true if the drag could be performed | 287 // bool - true if the drag could be performed |
| 289 IPC_SYNC_MESSAGE_ROUTED4_1(AutomationMsg_WindowDrag, | 288 IPC_SYNC_MESSAGE_ROUTED4_1(AutomationMsg_WindowDrag, |
| 290 int, std::vector<POINT>, int, bool, bool) | 289 int, std::vector<gfx::Point>, int, bool, bool) |
| 291 #endif // defined(OS_WIN) | 290 #endif // defined(OS_WIN) |
| 292 | 291 |
| 293 // Similar to AutomationMsg_InitialLoadsComplete, this indicates that the | 292 // Similar to AutomationMsg_InitialLoadsComplete, this indicates that the |
| 294 // new tab ui has completed the initial load of its data. | 293 // new tab ui has completed the initial load of its data. |
| 295 // Time is how many milliseconds the load took. | 294 // Time is how many milliseconds the load took. |
| 296 IPC_MESSAGE_ROUTED1(AutomationMsg_InitialNewTabUILoadComplete, | 295 IPC_MESSAGE_ROUTED1(AutomationMsg_InitialNewTabUILoadComplete, |
| 297 int /* time */) | 296 int /* time */) |
| 298 | 297 |
| 299 // This message starts a find within a tab corresponding to the supplied | 298 // This message starts a find within a tab corresponding to the supplied |
| 300 // tab handle. The return value contains the number of matches found on the | 299 // tab handle. The return value contains the number of matches found on the |
| (...skipping 560 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 861 // It is a notification that a navigation failed | 860 // It is a notification that a navigation failed |
| 862 // Request: | 861 // Request: |
| 863 // -int : Tab handle | 862 // -int : Tab handle |
| 864 // -int : The status code. | 863 // -int : The status code. |
| 865 // -GURL: The URL we failed to navigate to. | 864 // -GURL: The URL we failed to navigate to. |
| 866 // Response: | 865 // Response: |
| 867 // None expected | 866 // None expected |
| 868 IPC_MESSAGE_ROUTED3(AutomationMsg_NavigationFailed, int, int, GURL) | 867 IPC_MESSAGE_ROUTED3(AutomationMsg_NavigationFailed, int, int, GURL) |
| 869 | 868 |
| 870 #if defined(OS_WIN) | 869 #if defined(OS_WIN) |
| 871 // This message is an outgoing message from an automation client to Chrome. | 870 // TODO(estade): delete this message. It is unused. |
| 872 // It is used to reposition a chrome tab window. | 871 IPC_MESSAGE_ROUTED0(AutomationMsg_TabReposition) |
| 873 IPC_MESSAGE_ROUTED2(AutomationMsg_TabReposition, | |
| 874 int /* tab handle */, | |
| 875 IPC::Reposition_Params /* SetWindowPos params */) | |
| 876 #endif // defined(OS_WIN) | 872 #endif // defined(OS_WIN) |
| 877 | 873 |
| 878 // Gets the title of the top level browser window. | 874 // Gets the title of the top level browser window. |
| 879 IPC_SYNC_MESSAGE_ROUTED1_1(AutomationMsg_WindowTitle, | 875 IPC_SYNC_MESSAGE_ROUTED1_1(AutomationMsg_WindowTitle, |
| 880 int /* automation handle */, | 876 int /* automation handle */, |
| 881 string16 /* title text */ ) | 877 string16 /* title text */ ) |
| 882 | 878 |
| 883 // Tab load complete | 879 // Tab load complete |
| 884 IPC_MESSAGE_ROUTED2(AutomationMsg_TabLoaded, | 880 IPC_MESSAGE_ROUTED2(AutomationMsg_TabLoaded, |
| 885 int, // tab handle | 881 int, // tab handle |
| (...skipping 185 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1071 intptr_t /* cookie */, | 1067 intptr_t /* cookie */, |
| 1072 int /* disposition */) | 1068 int /* disposition */) |
| 1073 | 1069 |
| 1074 // Sent when the automation client connects to an existing tab. | 1070 // Sent when the automation client connects to an existing tab. |
| 1075 IPC_SYNC_MESSAGE_ROUTED1_3(AutomationMsg_ConnectExternalTab, | 1071 IPC_SYNC_MESSAGE_ROUTED1_3(AutomationMsg_ConnectExternalTab, |
| 1076 intptr_t /* cookie */, | 1072 intptr_t /* cookie */, |
| 1077 gfx::NativeWindow /* Tab container window */, | 1073 gfx::NativeWindow /* Tab container window */, |
| 1078 gfx::NativeWindow /* Tab window */, | 1074 gfx::NativeWindow /* Tab window */, |
| 1079 int /* Handle to the new tab */) | 1075 int /* Handle to the new tab */) |
| 1080 | 1076 |
| 1077 #if defined(OS_LINUX) || defined(OS_MACOSX) |
| 1078 // TODO(estade): this should be merged with the windows message of the same |
| 1079 // name. See comment for WindowClick. |
| 1080 IPC_SYNC_MESSAGE_ROUTED4_1(AutomationMsg_WindowDrag, |
| 1081 int, std::vector<gfx::Point>, int, bool, bool) |
| 1082 #endif // defined(OS_LINUX) || defined(OS_MACOSX) |
| 1083 |
| 1084 // This message gets the bounds of the window. |
| 1085 // Request: |
| 1086 // int - the handle of the window to query |
| 1087 // Response: |
| 1088 // gfx::Rect - the bounds of the window |
| 1089 // bool - true if the query was successful |
| 1090 IPC_SYNC_MESSAGE_ROUTED1_2(AutomationMsg_GetWindowBounds, int, gfx::Rect, |
| 1091 bool) |
| 1092 |
| 1093 // Simulate an end of session. Normally this happens when the user |
| 1094 // shuts down the machine or logs off. |
| 1095 // Request: |
| 1096 // int - the handle of the browser |
| 1097 // Response: |
| 1098 // bool - true if succesful |
| 1099 IPC_SYNC_MESSAGE_ROUTED1_1(AutomationMsg_TerminateSession, int, bool) |
| 1100 |
| 1101 // Returns whether the window is maximized. |
| 1102 // Request: |
| 1103 // int - the handle of the window |
| 1104 // Response: |
| 1105 // bool - true if the window is maximized |
| 1106 // bool - true if query is successful |
| 1107 IPC_SYNC_MESSAGE_ROUTED1_2(AutomationMsg_IsWindowMaximized, int, bool, bool) |
| 1108 |
| 1081 IPC_END_MESSAGES(Automation) | 1109 IPC_END_MESSAGES(Automation) |
| OLD | NEW |