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

Side by Side Diff: ui/accessibility/ax_node_data.cc

Issue 2301833005: Get rid of AX_LINE_BREAKS attribute to improve performance. (Closed)
Patch Set: Fixed line length issue. Created 4 years, 3 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 "ui/accessibility/ax_node_data.h" 5 #include "ui/accessibility/ax_node_data.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <algorithm> 9 #include <algorithm>
10 #include <set> 10 #include <set>
(...skipping 674 matching lines...) Expand 10 before | Expand all | Expand 10 after
685 break; 685 break;
686 case AX_ATTR_DESCRIBEDBY_IDS: 686 case AX_ATTR_DESCRIBEDBY_IDS:
687 result += " describedby_ids=" + IntVectorToString(values); 687 result += " describedby_ids=" + IntVectorToString(values);
688 break; 688 break;
689 case AX_ATTR_FLOWTO_IDS: 689 case AX_ATTR_FLOWTO_IDS:
690 result += " flowto_ids=" + IntVectorToString(values); 690 result += " flowto_ids=" + IntVectorToString(values);
691 break; 691 break;
692 case AX_ATTR_LABELLEDBY_IDS: 692 case AX_ATTR_LABELLEDBY_IDS:
693 result += " labelledby_ids=" + IntVectorToString(values); 693 result += " labelledby_ids=" + IntVectorToString(values);
694 break; 694 break;
695 case AX_ATTR_LINE_BREAKS:
dmazzoni 2016/09/13 17:29:38 I'd prefer if AXNodeData dumped the new cached att
696 result += " line_breaks=" + IntVectorToString(values);
697 break;
698 case AX_ATTR_MARKER_TYPES: { 695 case AX_ATTR_MARKER_TYPES: {
699 std::string types_str; 696 std::string types_str;
700 for (size_t i = 0; i < values.size(); ++i) { 697 for (size_t i = 0; i < values.size(); ++i) {
701 auto type = static_cast<AXMarkerType>(values[i]); 698 auto type = static_cast<AXMarkerType>(values[i]);
702 if (type == AX_MARKER_TYPE_NONE) 699 if (type == AX_MARKER_TYPE_NONE)
703 continue; 700 continue;
704 701
705 if (i > 0) 702 if (i > 0)
706 types_str += ','; 703 types_str += ',';
707 704
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
746 } 743 }
747 } 744 }
748 745
749 if (!child_ids.empty()) 746 if (!child_ids.empty())
750 result += " child_ids=" + IntVectorToString(child_ids); 747 result += " child_ids=" + IntVectorToString(child_ids);
751 748
752 return result; 749 return result;
753 } 750 }
754 751
755 } // namespace ui 752 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698