Index: Source/core/accessibility/AccessibilityTableColumn.h |
diff --git a/Source/core/accessibility/AccessibilityTableColumn.h b/Source/core/accessibility/AccessibilityTableColumn.h |
index 09de7ecab27c28c40214e26cd7d443739c06b421..bf0ffd3dacbfa6396d7c1bf73305935bf3954011 100644 |
--- a/Source/core/accessibility/AccessibilityTableColumn.h |
+++ b/Source/core/accessibility/AccessibilityTableColumn.h |
@@ -60,10 +60,26 @@ private: |
unsigned m_columnIndex; |
LayoutRect m_columnRect; |
+ virtual bool isTableCol() const OVERRIDE { return true; } |
AccessibilityObject* headerObjectForSection(RenderTableSection*, bool thTagRequired); |
virtual bool computeAccessibilityIsIgnored() const OVERRIDE; |
}; |
+inline AccessibilityTableColumn* toAccessibilityTableColumn(AccessibilityObject* object) |
+{ |
+ ASSERT_WITH_SECURITY_IMPLICATION(!object || object->isTableCol()); |
+ return static_cast<AccessibilityTableColumn*>(object); |
+} |
+ |
+inline const AccessibilityTableColumn* toAccessibilityTableColumn(const AccessibilityObject* object) |
+{ |
+ ASSERT_WITH_SECURITY_IMPLICATION(!object || object->isTableCol()); |
+ return static_cast<const AccessibilityTableColumn*>(object); |
+} |
+ |
+// This will catch anyone doing an unnecessary cast. |
+void toAccessibilityTableColumn(const AccessibilityTableColumn*); |
+ |
} // namespace WebCore |
#endif // AccessibilityTableColumn_h |