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

Side by Side Diff: Source/modules/accessibility/AXTableColumn.cpp

Issue 874963002: Before conversion to AXTableCell, isTableCell() should be called. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebaseline changes Created 5 years, 11 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
« no previous file with comments | « no previous file | 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 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 LayoutTableCell* layoutCell = tableSection->primaryCellAt(r, m_colum nIndex); 83 LayoutTableCell* layoutCell = tableSection->primaryCellAt(r, m_colum nIndex);
84 if (!layoutCell) 84 if (!layoutCell)
85 continue; 85 continue;
86 86
87 // Whenever cell's col is less then current column index, we've foun d the cell with colspan. 87 // Whenever cell's col is less then current column index, we've foun d the cell with colspan.
88 // We do not need to add this cell, it's already been added. 88 // We do not need to add this cell, it's already been added.
89 if (layoutCell->col() < m_columnIndex) 89 if (layoutCell->col() < m_columnIndex)
90 continue; 90 continue;
91 91
92 AXObject* cell = axObjectCache()->getOrCreate(layoutCell->node()); 92 AXObject* cell = axObjectCache()->getOrCreate(layoutCell->node());
93 if (!cell) 93 if (!cell || !cell->isTableCell())
94 continue; 94 continue;
95 95
96 if (toAXTableCell(cell)->scanToDecideHeaderRole() == ColumnHeaderRol e) 96 if (toAXTableCell(cell)->scanToDecideHeaderRole() == ColumnHeaderRol e)
97 headers.append(cell); 97 headers.append(cell);
98 } 98 }
99 } 99 }
100 } 100 }
101 101
102 AXObject* AXTableColumn::headerObject() 102 AXObject* AXTableColumn::headerObject()
103 { 103 {
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 // make sure the last one isn't the same as this one (rowspan cells) 210 // make sure the last one isn't the same as this one (rowspan cells)
211 if (m_children.size() > 0 && m_children.last() == cell) 211 if (m_children.size() > 0 && m_children.last() == cell)
212 continue; 212 continue;
213 213
214 m_children.append(cell); 214 m_children.append(cell);
215 m_columnRect.unite(cell->elementRect()); 215 m_columnRect.unite(cell->elementRect());
216 } 216 }
217 } 217 }
218 218
219 } // namespace blink 219 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698