OLD | NEW |
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 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
189 | 189 |
190 rowRange.first += rowOffset; | 190 rowRange.first += rowOffset; |
191 } | 191 } |
192 | 192 |
193 void AXTableCell::columnIndexRange(pair<unsigned, unsigned>& columnRange) | 193 void AXTableCell::columnIndexRange(pair<unsigned, unsigned>& columnRange) |
194 { | 194 { |
195 if (!m_renderer || !m_renderer->isTableCell()) | 195 if (!m_renderer || !m_renderer->isTableCell()) |
196 return; | 196 return; |
197 | 197 |
198 LayoutTableCell* cell = toLayoutTableCell(m_renderer); | 198 LayoutTableCell* cell = toLayoutTableCell(m_renderer); |
199 columnRange.first = cell->col(); | 199 columnRange.first = cell->table()->colToEffCol(cell->col()); |
200 columnRange.second = cell->colSpan(); | 200 columnRange.second = cell->table()->colToEffCol(cell->col() + cell->colSpan(
)) - columnRange.first; |
201 } | 201 } |
202 | 202 |
203 SortDirection AXTableCell::sortDirection() const | 203 SortDirection AXTableCell::sortDirection() const |
204 { | 204 { |
205 if (roleValue() != RowHeaderRole | 205 if (roleValue() != RowHeaderRole |
206 && roleValue() != ColumnHeaderRole) | 206 && roleValue() != ColumnHeaderRole) |
207 return SortDirectionUndefined; | 207 return SortDirectionUndefined; |
208 | 208 |
209 const AtomicString& ariaSort = getAttribute(aria_sortAttr); | 209 const AtomicString& ariaSort = getAttribute(aria_sortAttr); |
210 if (ariaSort.isEmpty()) | 210 if (ariaSort.isEmpty()) |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
251 return 0; | 251 return 0; |
252 | 252 |
253 Node* cellElement = headerCell->node(); | 253 Node* cellElement = headerCell->node(); |
254 if (!cellElement || !cellElement->hasTagName(thTag)) | 254 if (!cellElement || !cellElement->hasTagName(thTag)) |
255 return 0; | 255 return 0; |
256 | 256 |
257 return axObjectCache()->getOrCreate(headerCell); | 257 return axObjectCache()->getOrCreate(headerCell); |
258 } | 258 } |
259 | 259 |
260 } // namespace blink | 260 } // namespace blink |
OLD | NEW |