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

Side by Side Diff: content/shell/renderer/test_runner/accessibility_controller.cc

Issue 684093003: Replace deprecated updateBackingStoreAndCheckValidity to updateLayoutAndCheckValidity (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
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
« no previous file with comments | « content/renderer/accessibility/renderer_accessibility_complete.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/shell/renderer/test_runner/accessibility_controller.h" 5 #include "content/shell/renderer/test_runner/accessibility_controller.h"
6 6
7 #include "gin/handle.h" 7 #include "gin/handle.h"
8 #include "gin/object_template_builder.h" 8 #include "gin/object_template_builder.h"
9 #include "gin/wrappable.h" 9 #include "gin/wrappable.h"
10 #include "third_party/WebKit/public/web/WebElement.h" 10 #include "third_party/WebKit/public/web/WebElement.h"
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
236 if (root_element_.isNull()) 236 if (root_element_.isNull())
237 root_element_ = web_view_->accessibilityObject(); 237 root_element_ = web_view_->accessibilityObject();
238 return elements_.CreateRoot(root_element_); 238 return elements_.CreateRoot(root_element_);
239 } 239 }
240 240
241 v8::Handle<v8::Object> 241 v8::Handle<v8::Object>
242 AccessibilityController::AccessibleElementById(const std::string& id) { 242 AccessibilityController::AccessibleElementById(const std::string& id) {
243 if (root_element_.isNull()) 243 if (root_element_.isNull())
244 root_element_ = web_view_->accessibilityObject(); 244 root_element_ = web_view_->accessibilityObject();
245 245
246 if (!root_element_.updateBackingStoreAndCheckValidity()) 246 if (!root_element_.updateLayoutAndCheckValidity())
247 return v8::Handle<v8::Object>(); 247 return v8::Handle<v8::Object>();
248 248
249 return FindAccessibleElementByIdRecursive( 249 return FindAccessibleElementByIdRecursive(
250 root_element_, blink::WebString::fromUTF8(id.c_str())); 250 root_element_, blink::WebString::fromUTF8(id.c_str()));
251 } 251 }
252 252
253 v8::Handle<v8::Object> 253 v8::Handle<v8::Object>
254 AccessibilityController::FindAccessibleElementByIdRecursive( 254 AccessibilityController::FindAccessibleElementByIdRecursive(
255 const blink::WebAXObject& obj, const blink::WebString& id) { 255 const blink::WebAXObject& obj, const blink::WebString& id) {
256 if (obj.isNull() || obj.isDetached()) 256 if (obj.isNull() || obj.isDetached())
(...skipping 12 matching lines...) Expand all
269 v8::Handle<v8::Object> result = 269 v8::Handle<v8::Object> result =
270 FindAccessibleElementByIdRecursive(obj.childAt(i), id); 270 FindAccessibleElementByIdRecursive(obj.childAt(i), id);
271 if (*result) 271 if (*result)
272 return result; 272 return result;
273 } 273 }
274 274
275 return v8::Handle<v8::Object>(); 275 return v8::Handle<v8::Object>();
276 } 276 }
277 277
278 } // namespace content 278 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/accessibility/renderer_accessibility_complete.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698