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

Side by Side Diff: content/renderer/accessibility/renderer_accessibility_complete.cc

Issue 21269002: Make AccessibilityNodeData more compact. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix win test Created 7 years, 4 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 | Annotate | Revision Log
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 "content/renderer/accessibility/renderer_accessibility_complete.h" 5 #include "content/renderer/accessibility/renderer_accessibility_complete.h"
6 6
7 #include <queue> 7 #include <queue>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/message_loop/message_loop.h" 10 #include "base/message_loop/message_loop.h"
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after
398 398
399 AccessibilityHostMsg_NotificationParams notification_msg; 399 AccessibilityHostMsg_NotificationParams notification_msg;
400 notification_msg.notification_type = 400 notification_msg.notification_type =
401 static_cast<AccessibilityNotification>(-1); 401 static_cast<AccessibilityNotification>(-1);
402 notification_msg.id = root_object.axID(); 402 notification_msg.id = root_object.axID();
403 notification_msg.nodes.resize(location_changes.size()); 403 notification_msg.nodes.resize(location_changes.size());
404 for (size_t i = 0; i < location_changes.size(); i++) { 404 for (size_t i = 0; i < location_changes.size(); i++) {
405 AccessibilityNodeData& serialized_node = notification_msg.nodes[i]; 405 AccessibilityNodeData& serialized_node = notification_msg.nodes[i];
406 serialized_node.id = location_changes[i]->id; 406 serialized_node.id = location_changes[i]->id;
407 serialized_node.location = location_changes[i]->location; 407 serialized_node.location = location_changes[i]->location;
408 serialized_node.bool_attributes[ 408 serialized_node.AddBoolAttribute(
409 AccessibilityNodeData::ATTR_UPDATE_LOCATION_ONLY] = true; 409 AccessibilityNodeData::ATTR_UPDATE_LOCATION_ONLY, true);
410 } 410 }
411 411
412 notification_msgs->push_back(notification_msg); 412 notification_msgs->push_back(notification_msg);
413 } 413 }
414 414
415 RendererAccessibilityComplete::BrowserTreeNode* 415 RendererAccessibilityComplete::BrowserTreeNode*
416 RendererAccessibilityComplete::CreateBrowserTreeNode() { 416 RendererAccessibilityComplete::CreateBrowserTreeNode() {
417 return new RendererAccessibilityComplete::BrowserTreeNode(); 417 return new RendererAccessibilityComplete::BrowserTreeNode();
418 } 418 }
419 419
(...skipping 284 matching lines...) Expand 10 before | Expand all | Expand 10 after
704 render_view()->GetWebView()->clearFocusedNode(); 704 render_view()->GetWebView()->clearFocusedNode();
705 else 705 else
706 obj.setFocused(true); 706 obj.setFocused(true);
707 } 707 }
708 708
709 void RendererAccessibilityComplete::OnFatalError() { 709 void RendererAccessibilityComplete::OnFatalError() {
710 CHECK(false) << "Invalid accessibility tree."; 710 CHECK(false) << "Invalid accessibility tree.";
711 } 711 }
712 712
713 } // namespace content 713 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/accessibility/accessibility_node_serializer.cc ('k') | content/test/accessibility_browser_test_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698