| 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 17 matching lines...) Expand all Loading... |
| 28 | 28 |
| 29 #ifndef AXTableRow_h | 29 #ifndef AXTableRow_h |
| 30 #define AXTableRow_h | 30 #define AXTableRow_h |
| 31 | 31 |
| 32 #include "modules/accessibility/AXLayoutObject.h" | 32 #include "modules/accessibility/AXLayoutObject.h" |
| 33 | 33 |
| 34 namespace blink { | 34 namespace blink { |
| 35 | 35 |
| 36 class AXObjectCacheImpl; | 36 class AXObjectCacheImpl; |
| 37 | 37 |
| 38 class AXTableRow : public AXLayoutObject { | 38 class MODULES_EXPORT AXTableRow : public AXLayoutObject { |
| 39 | 39 |
| 40 protected: | 40 protected: |
| 41 AXTableRow(LayoutObject*, AXObjectCacheImpl&); | 41 AXTableRow(LayoutObject*, AXObjectCacheImpl&); |
| 42 | 42 |
| 43 public: | 43 public: |
| 44 static AXTableRow* create(LayoutObject*, AXObjectCacheImpl&); | 44 static AXTableRow* create(LayoutObject*, AXObjectCacheImpl&); |
| 45 ~AXTableRow() override; | 45 ~AXTableRow() override; |
| 46 | 46 |
| 47 void addChildren() final; |
| 47 bool isTableRow() const final; | 48 bool isTableRow() const final; |
| 48 | 49 |
| 49 // retrieves the "row" header (a th tag in the rightmost column) | 50 // retrieves the "row" header (a th tag in the rightmost column) |
| 50 virtual AXObject* headerObject(); | 51 virtual AXObject* headerObject(); |
| 51 // retrieves the "row" headers (th, scope) from left to right for the each r
ow. | 52 // retrieves the "row" headers (th, scope) from left to right for the each r
ow. |
| 52 virtual void headerObjectsForRow(AXObjectVector&); | 53 virtual void headerObjectsForRow(AXObjectVector&); |
| 53 AXObject* parentTable() const; | 54 AXObject* parentTable() const; |
| 54 | 55 |
| 55 void setRowIndex(int rowIndex) { m_rowIndex = rowIndex; } | 56 void setRowIndex(int rowIndex) { m_rowIndex = rowIndex; } |
| 56 int rowIndex() const { return m_rowIndex; } | 57 int rowIndex() const { return m_rowIndex; } |
| 57 | 58 |
| 59 unsigned ariaColumnIndex() const; |
| 60 unsigned ariaRowIndex() const; |
| 61 |
| 62 // allows the table to add other children that may not originate |
| 63 // in the row, but their col/row spans overlap into it |
| 64 void appendChild(AXObject*); |
| 65 |
| 58 protected: | 66 protected: |
| 59 AccessibilityRole determineAccessibilityRole() final; | 67 AccessibilityRole determineAccessibilityRole() final; |
| 60 | 68 |
| 61 private: | 69 private: |
| 62 int m_rowIndex; | 70 int m_rowIndex; |
| 63 | 71 |
| 64 bool computeAccessibilityIsIgnored(IgnoredReasons* = nullptr) const final; | 72 bool computeAccessibilityIsIgnored(IgnoredReasons* = nullptr) const final; |
| 65 }; | 73 }; |
| 66 | 74 |
| 67 DEFINE_AX_OBJECT_TYPE_CASTS(AXTableRow, isTableRow()); | 75 DEFINE_AX_OBJECT_TYPE_CASTS(AXTableRow, isTableRow()); |
| 68 | 76 |
| 69 } // namespace blink | 77 } // namespace blink |
| 70 | 78 |
| 71 #endif // AXTableRow_h | 79 #endif // AXTableRow_h |
| OLD | NEW |