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 11 matching lines...) Expand all Loading... |
22 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; | 22 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
23 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND | 23 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
24 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 24 * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | 25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
27 */ | 27 */ |
28 | 28 |
29 #include "config.h" | 29 #include "config.h" |
30 #include "modules/accessibility/AXTableRow.h" | 30 #include "modules/accessibility/AXTableRow.h" |
31 | 31 |
| 32 #include "core/dom/AXObjectCache.h" |
32 #include "core/rendering/RenderTableRow.h" | 33 #include "core/rendering/RenderTableRow.h" |
33 #include "modules/accessibility/AXTableCell.h" | 34 #include "modules/accessibility/AXTableCell.h" |
34 | 35 |
35 | 36 |
36 namespace blink { | 37 namespace blink { |
37 | 38 |
38 using namespace HTMLNames; | 39 using namespace HTMLNames; |
39 | 40 |
40 AXTableRow::AXTableRow(RenderObject* renderer) | 41 AXTableRow::AXTableRow(RenderObject* renderer, AXObjectCache* axObjectCache) |
41 : AXRenderObject(renderer) | 42 : AXRenderObject(renderer, axObjectCache) |
42 { | 43 { |
43 } | 44 } |
44 | 45 |
45 AXTableRow::~AXTableRow() | 46 AXTableRow::~AXTableRow() |
46 { | 47 { |
47 } | 48 } |
48 | 49 |
49 PassRefPtr<AXTableRow> AXTableRow::create(RenderObject* renderer) | 50 PassRefPtr<AXTableRow> AXTableRow::create(RenderObject* renderer, AXObjectCache*
axObjectCache) |
50 { | 51 { |
51 return adoptRef(new AXTableRow(renderer)); | 52 return adoptRef(new AXTableRow(renderer, axObjectCache)); |
52 } | 53 } |
53 | 54 |
54 AccessibilityRole AXTableRow::determineAccessibilityRole() | 55 AccessibilityRole AXTableRow::determineAccessibilityRole() |
55 { | 56 { |
56 if (!isTableRow()) | 57 if (!isTableRow()) |
57 return AXRenderObject::determineAccessibilityRole(); | 58 return AXRenderObject::determineAccessibilityRole(); |
58 | 59 |
59 m_ariaRole = determineAriaRoleAttribute(); | 60 m_ariaRole = determineAriaRoleAttribute(); |
60 | 61 |
61 AccessibilityRole ariaRole = ariaRoleAttribute(); | 62 AccessibilityRole ariaRole = ariaRoleAttribute(); |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
122 return 0; | 123 return 0; |
123 | 124 |
124 Node* cellNode = cellRenderer->node(); | 125 Node* cellNode = cellRenderer->node(); |
125 if (!cellNode || !cellNode->hasTagName(thTag)) | 126 if (!cellNode || !cellNode->hasTagName(thTag)) |
126 return 0; | 127 return 0; |
127 | 128 |
128 return cell; | 129 return cell; |
129 } | 130 } |
130 | 131 |
131 } // namespace blink | 132 } // namespace blink |
OLD | NEW |