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

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

Issue 2674353003: Enable WebViewAccessiblityTest for OOPIF webview. (Closed)
Patch Set: remove change from unrelated cl. Created 3 years, 9 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 <algorithm> 7 #include <algorithm>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 3310 matching lines...) Expand 10 before | Expand all | Expand 10 after
3321 dst->parent_tree_id = RoutingIDToAXTreeID(src.parent_routing_id); 3321 dst->parent_tree_id = RoutingIDToAXTreeID(src.parent_routing_id);
3322 3322
3323 if (browser_plugin_embedder_ax_tree_id_ != ui::AXTreeIDRegistry::kNoAXTreeID) 3323 if (browser_plugin_embedder_ax_tree_id_ != ui::AXTreeIDRegistry::kNoAXTreeID)
3324 dst->parent_tree_id = browser_plugin_embedder_ax_tree_id_; 3324 dst->parent_tree_id = browser_plugin_embedder_ax_tree_id_;
3325 3325
3326 // If this is not the root frame tree node, we're done. 3326 // If this is not the root frame tree node, we're done.
3327 if (frame_tree_node()->parent()) 3327 if (frame_tree_node()->parent())
3328 return; 3328 return;
3329 3329
3330 // For the root frame tree node, also store the AXTreeID of the focused frame. 3330 // For the root frame tree node, also store the AXTreeID of the focused frame.
3331 // TODO(avallee): https://crbug.com/610795: No focus ax events. 3331 auto* focused_frame = static_cast<RenderFrameHostImpl*>(
3332 // This is probably where we need to fix the bug to enable the test. 3332 delegate_->GetFocusedFrameIncludingInnerWebContents());
3333 FrameTreeNode* focused_frame_tree_node = frame_tree_->GetFocusedFrame(); 3333 if (!focused_frame)
3334 if (!focused_frame_tree_node)
3335 return; 3334 return;
3336 RenderFrameHostImpl* focused_frame =
3337 focused_frame_tree_node->current_frame_host();
3338 DCHECK(focused_frame);
3339 dst->focused_tree_id = focused_frame->GetAXTreeID(); 3335 dst->focused_tree_id = focused_frame->GetAXTreeID();
3340 } 3336 }
3341 3337
3342 WebBluetoothServiceImpl* RenderFrameHostImpl::CreateWebBluetoothService( 3338 WebBluetoothServiceImpl* RenderFrameHostImpl::CreateWebBluetoothService(
3343 blink::mojom::WebBluetoothServiceRequest request) { 3339 blink::mojom::WebBluetoothServiceRequest request) {
3344 // RFHI owns |web_bluetooth_services_| and |web_bluetooth_service| owns the 3340 // RFHI owns |web_bluetooth_services_| and |web_bluetooth_service| owns the
3345 // |binding_| which may run the error handler. |binding_| can't run the error 3341 // |binding_| which may run the error handler. |binding_| can't run the error
3346 // handler after it's destroyed so it can't run after the RFHI is destroyed. 3342 // handler after it's destroyed so it can't run after the RFHI is destroyed.
3347 auto web_bluetooth_service = 3343 auto web_bluetooth_service =
3348 base::MakeUnique<WebBluetoothServiceImpl>(this, std::move(request)); 3344 base::MakeUnique<WebBluetoothServiceImpl>(this, std::move(request));
(...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after
3478 // There is no pending NavigationEntry in these cases, so pass 0 as the 3474 // There is no pending NavigationEntry in these cases, so pass 0 as the
3479 // pending_nav_entry_id. If the previous handle was a prematurely aborted 3475 // pending_nav_entry_id. If the previous handle was a prematurely aborted
3480 // navigation loaded via LoadDataWithBaseURL, propagate the entry id. 3476 // navigation loaded via LoadDataWithBaseURL, propagate the entry id.
3481 return NavigationHandleImpl::Create( 3477 return NavigationHandleImpl::Create(
3482 params.url, params.redirects, frame_tree_node_, is_renderer_initiated, 3478 params.url, params.redirects, frame_tree_node_, is_renderer_initiated,
3483 params.was_within_same_page, base::TimeTicks::Now(), 3479 params.was_within_same_page, base::TimeTicks::Now(),
3484 entry_id_for_data_nav, false); // started_from_context_menu 3480 entry_id_for_data_nav, false); // started_from_context_menu
3485 } 3481 }
3486 3482
3487 } // namespace content 3483 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698