Index: content/common/accessibility_messages.h |
diff --git a/content/common/accessibility_messages.h b/content/common/accessibility_messages.h |
index 02af80708cce2f135c17b19427b939521a71fab6..5abf149303d45bf183ef250ee99abae830096660 100644 |
--- a/content/common/accessibility_messages.h |
+++ b/content/common/accessibility_messages.h |
@@ -131,16 +131,32 @@ IPC_MESSAGE_ROUTED1(AccessibilityMsg_HitTest, |
// message was processed and it can send addition events. |
IPC_MESSAGE_ROUTED0(AccessibilityMsg_Events_ACK) |
-// Kill the renderer because we got a fatal error in the accessibility tree. |
+// Tell the renderer to reset and send a new accessibility tree from |
+// scratch because the browser is out of sync. It passes a sequential |
+// reset token. This should be rare, and if we need reset the same renderer |
+// too many times we just kill it. After sending a reset, the browser ignores |
+// incoming accessibility IPCs until it receives one with the matching reset |
+// token. Conversely, it ignores IPCs with a reset token if it was not |
+// expecting a reset. |
+IPC_MESSAGE_ROUTED1(AccessibilityMsg_Reset, |
+ int /* reset token */); |
+ |
+// Kill the renderer because we got a fatal error in the accessibility tree |
+// and we've already reset too many times. |
IPC_MESSAGE_ROUTED0(AccessibilityMsg_FatalError) |
// Messages sent from the renderer to the browser. |
// Sent to notify the browser about renderer accessibility events. |
// The browser responds with a AccessibilityMsg_Events_ACK. |
-IPC_MESSAGE_ROUTED1( |
+// The second parameter, reset_token, is set if this IPC was sent in response |
+// to a reset request from the browser. When the browser requests a reset, |
+// it ignores incoming IPCs until it sees one with the correct reset token. |
+// Any other time, it ignores IPCs with a reset token. |
+IPC_MESSAGE_ROUTED2( |
AccessibilityHostMsg_Events, |
- std::vector<AccessibilityHostMsg_EventParams>) |
+ std::vector<AccessibilityHostMsg_EventParams> /* events */, |
+ int /* reset_token */) |
// Sent to update the browser of the location of accessibility objects. |
IPC_MESSAGE_ROUTED1( |