| 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 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 } | 52 } |
| 53 | 53 |
| 54 | 54 |
| 55 void AXTableColumn::setParent(AXObject* parent) | 55 void AXTableColumn::setParent(AXObject* parent) |
| 56 { | 56 { |
| 57 AXMockObject::setParent(parent); | 57 AXMockObject::setParent(parent); |
| 58 | 58 |
| 59 clearChildren(); | 59 clearChildren(); |
| 60 } | 60 } |
| 61 | 61 |
| 62 LayoutRect AXTableColumn::elementRect() const | |
| 63 { | |
| 64 // this will be filled in when addChildren is called | |
| 65 return m_columnRect; | |
| 66 } | |
| 67 | |
| 68 void AXTableColumn::headerObjectsForColumn(AXObjectVector& headers) | 62 void AXTableColumn::headerObjectsForColumn(AXObjectVector& headers) |
| 69 { | 63 { |
| 70 if (!m_parent) | 64 if (!m_parent) |
| 71 return; | 65 return; |
| 72 | 66 |
| 73 LayoutObject* layoutObject = m_parent->getLayoutObject(); | 67 LayoutObject* layoutObject = m_parent->getLayoutObject(); |
| 74 if (!layoutObject) | 68 if (!layoutObject) |
| 75 return; | 69 return; |
| 76 | 70 |
| 77 if (!m_parent->isAXTable()) | 71 if (!m_parent->isAXTable()) |
| (...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 149 for (int i = 0; i < numRows; i++) { | 143 for (int i = 0; i < numRows; i++) { |
| 150 AXTableCell* cell = parentTable->cellForColumnAndRow(m_columnIndex, i); | 144 AXTableCell* cell = parentTable->cellForColumnAndRow(m_columnIndex, i); |
| 151 if (!cell) | 145 if (!cell) |
| 152 continue; | 146 continue; |
| 153 | 147 |
| 154 // make sure the last one isn't the same as this one (rowspan cells) | 148 // make sure the last one isn't the same as this one (rowspan cells) |
| 155 if (m_children.size() > 0 && m_children.last() == cell) | 149 if (m_children.size() > 0 && m_children.last() == cell) |
| 156 continue; | 150 continue; |
| 157 | 151 |
| 158 m_children.append(cell); | 152 m_children.append(cell); |
| 159 m_columnRect.unite(cell->elementRect()); | |
| 160 } | 153 } |
| 161 } | 154 } |
| 162 | 155 |
| 163 } // namespace blink | 156 } // namespace blink |
| OLD | NEW |