| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 #include "content/browser/frame_host/render_frame_host_impl.h" | 5 #include "content/browser/frame_host/render_frame_host_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 1955 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1966 // IPC doesn't have the matching token ID, or if we're not waiting on a | 1966 // IPC doesn't have the matching token ID, or if we're not waiting on a |
| 1967 // reset but this message includes a reset token. | 1967 // reset but this message includes a reset token. |
| 1968 if (accessibility_reset_token_ != reset_token) { | 1968 if (accessibility_reset_token_ != reset_token) { |
| 1969 Send(new AccessibilityMsg_Events_ACK(routing_id_, ack_token)); | 1969 Send(new AccessibilityMsg_Events_ACK(routing_id_, ack_token)); |
| 1970 return; | 1970 return; |
| 1971 } | 1971 } |
| 1972 accessibility_reset_token_ = 0; | 1972 accessibility_reset_token_ = 0; |
| 1973 | 1973 |
| 1974 RenderWidgetHostViewBase* view = GetViewForAccessibility(); | 1974 RenderWidgetHostViewBase* view = GetViewForAccessibility(); |
| 1975 | 1975 |
| 1976 if (frame_tree_node_->IsMainFrame() && view) |
| 1977 view->SetMainFrameAXTreeID(GetAXTreeID()); |
| 1978 |
| 1976 AccessibilityMode accessibility_mode = delegate_->GetAccessibilityMode(); | 1979 AccessibilityMode accessibility_mode = delegate_->GetAccessibilityMode(); |
| 1977 if ((accessibility_mode != AccessibilityModeOff) && view && is_active()) { | 1980 if ((accessibility_mode != AccessibilityModeOff) && view && is_active()) { |
| 1978 if (accessibility_mode & ACCESSIBILITY_MODE_FLAG_NATIVE_APIS) | 1981 if (accessibility_mode & ACCESSIBILITY_MODE_FLAG_NATIVE_APIS) |
| 1979 GetOrCreateBrowserAccessibilityManager(); | 1982 GetOrCreateBrowserAccessibilityManager(); |
| 1980 | 1983 |
| 1981 std::vector<AXEventNotificationDetails> details; | 1984 std::vector<AXEventNotificationDetails> details; |
| 1982 details.reserve(params.size()); | 1985 details.reserve(params.size()); |
| 1983 for (size_t i = 0; i < params.size(); ++i) { | 1986 for (size_t i = 0; i < params.size(); ++i) { |
| 1984 const AccessibilityHostMsg_EventParams& param = params[i]; | 1987 const AccessibilityHostMsg_EventParams& param = params[i]; |
| 1985 AXEventNotificationDetails detail; | 1988 AXEventNotificationDetails detail; |
| (...skipping 1489 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3475 GetUserData(kRenderFrameHostAndroidKey)); | 3478 GetUserData(kRenderFrameHostAndroidKey)); |
| 3476 if (!render_frame_host_android) { | 3479 if (!render_frame_host_android) { |
| 3477 render_frame_host_android = new RenderFrameHostAndroid(this); | 3480 render_frame_host_android = new RenderFrameHostAndroid(this); |
| 3478 SetUserData(kRenderFrameHostAndroidKey, render_frame_host_android); | 3481 SetUserData(kRenderFrameHostAndroidKey, render_frame_host_android); |
| 3479 } | 3482 } |
| 3480 return render_frame_host_android->GetJavaObject(); | 3483 return render_frame_host_android->GetJavaObject(); |
| 3481 } | 3484 } |
| 3482 #endif | 3485 #endif |
| 3483 | 3486 |
| 3484 } // namespace content | 3487 } // namespace content |
| OLD | NEW |