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

Side by Side Diff: ui/views/controls/webview/webview.cc

Issue 667713006: Implement automatic load of composed/embedded automation trees (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkcr
Patch Set: Created 6 years, 1 month 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "ui/views/controls/webview/webview.h" 5 #include "ui/views/controls/webview/webview.h"
6 6
7 #include "content/public/browser/browser_accessibility_state.h" 7 #include "content/public/browser/browser_accessibility_state.h"
8 #include "content/public/browser/browser_context.h" 8 #include "content/public/browser/browser_context.h"
9 #include "content/public/browser/navigation_controller.h" 9 #include "content/public/browser/navigation_controller.h"
10 #include "content/public/browser/render_view_host.h" 10 #include "content/public/browser/render_view_host.h"
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 if (web_contents()) 203 if (web_contents())
204 web_contents()->Focus(); 204 web_contents()->Focus();
205 } 205 }
206 206
207 void WebView::AboutToRequestFocusFromTabTraversal(bool reverse) { 207 void WebView::AboutToRequestFocusFromTabTraversal(bool reverse) {
208 if (web_contents()) 208 if (web_contents())
209 web_contents()->FocusThroughTabTraversal(reverse); 209 web_contents()->FocusThroughTabTraversal(reverse);
210 } 210 }
211 211
212 void WebView::GetAccessibleState(ui::AXViewState* state) { 212 void WebView::GetAccessibleState(ui::AXViewState* state) {
213 state->role = ui::AX_ROLE_GROUP; 213 state->role = ui::AX_ROLE_WEB_VIEW;
dmazzoni 2014/10/31 22:20:26 Please map this in NativeViewAccessibilityWin::MSA
David Tseng 2014/11/03 15:45:08 Done.
214 } 214 }
215 215
216 gfx::NativeViewAccessible WebView::GetNativeViewAccessible() { 216 gfx::NativeViewAccessible WebView::GetNativeViewAccessible() {
217 if (web_contents()) { 217 if (web_contents()) {
218 content::RenderWidgetHostView* host_view = 218 content::RenderWidgetHostView* host_view =
219 web_contents()->GetRenderWidgetHostView(); 219 web_contents()->GetRenderWidgetHostView();
220 if (host_view) 220 if (host_view)
221 return host_view->GetNativeViewAccessible(); 221 return host_view->GetNativeViewAccessible();
222 } 222 }
223 return View::GetNativeViewAccessible(); 223 return View::GetNativeViewAccessible();
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
366 if (!contents) { 366 if (!contents) {
367 content::WebContents::CreateParams create_params( 367 content::WebContents::CreateParams create_params(
368 browser_context, NULL); 368 browser_context, NULL);
369 return content::WebContents::Create(create_params); 369 return content::WebContents::Create(create_params);
370 } 370 }
371 371
372 return contents; 372 return contents;
373 } 373 }
374 374
375 } // namespace views 375 } // namespace views
OLDNEW
« ui/accessibility/ax_tree_id_registry.h ('K') | « ui/views/accessibility/ax_view_obj_wrapper.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698