Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Side by Side Diff: content/browser/frame_host/render_frame_host_impl.cc

Issue 1232643003: Give automation API access to browser plugin objects. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix compile error Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/containers/hash_tables.h" 9 #include "base/containers/hash_tables.h"
10 #include "base/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 1356 matching lines...) Expand 10 before | Expand all | Expand 10 after
1367 GetOrCreateBrowserAccessibilityManager(); 1367 GetOrCreateBrowserAccessibilityManager();
1368 if (browser_accessibility_manager_) 1368 if (browser_accessibility_manager_)
1369 browser_accessibility_manager_->OnAccessibilityEvents(params); 1369 browser_accessibility_manager_->OnAccessibilityEvents(params);
1370 } 1370 }
1371 1371
1372 // Send the updates to the automation extension API. 1372 // Send the updates to the automation extension API.
1373 std::vector<AXEventNotificationDetails> details; 1373 std::vector<AXEventNotificationDetails> details;
1374 details.reserve(params.size()); 1374 details.reserve(params.size());
1375 for (size_t i = 0; i < params.size(); ++i) { 1375 for (size_t i = 0; i < params.size(); ++i) {
1376 const AccessibilityHostMsg_EventParams& param = params[i]; 1376 const AccessibilityHostMsg_EventParams& param = params[i];
1377 AXEventNotificationDetails detail(param.update.node_id_to_clear, 1377 AXEventNotificationDetails detail(
1378 param.update.nodes, 1378 param.update.node_id_to_clear,
1379 param.event_type, 1379 param.update.nodes,
1380 param.id, 1380 param.event_type,
1381 GetProcess()->GetID(), 1381 param.id,
1382 routing_id_); 1382 param.node_to_browser_plugin_instance_id_map,
1383 GetProcess()->GetID(),
1384 routing_id_);
1383 details.push_back(detail); 1385 details.push_back(detail);
1384 } 1386 }
1385 1387
1386 delegate_->AccessibilityEventReceived(details); 1388 delegate_->AccessibilityEventReceived(details);
1387 } 1389 }
1388 1390
1389 // Always send an ACK or the renderer can be in a bad state. 1391 // Always send an ACK or the renderer can be in a bad state.
1390 Send(new AccessibilityMsg_Events_ACK(routing_id_)); 1392 Send(new AccessibilityMsg_Events_ACK(routing_id_));
1391 1393
1392 // The rest of this code is just for testing; bail out if we're not 1394 // The rest of this code is just for testing; bail out if we're not
(...skipping 726 matching lines...) Expand 10 before | Expand all | Expand 10 after
2119 // We may be returning to an existing NavigationEntry that had been granted 2121 // We may be returning to an existing NavigationEntry that had been granted
2120 // file access. If this is a different process, we will need to grant the 2122 // file access. If this is a different process, we will need to grant the
2121 // access again. The files listed in the page state are validated when they 2123 // access again. The files listed in the page state are validated when they
2122 // are received from the renderer to prevent abuse. 2124 // are received from the renderer to prevent abuse.
2123 if (request_params.page_state.IsValid()) { 2125 if (request_params.page_state.IsValid()) {
2124 render_view_host_->GrantFileAccessFromPageState(request_params.page_state); 2126 render_view_host_->GrantFileAccessFromPageState(request_params.page_state);
2125 } 2127 }
2126 } 2128 }
2127 2129
2128 } // namespace content 2130 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698