Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(418)

Unified Diff: Source/core/accessibility/AccessibilityTable.cpp

Issue 24752002: Cleanup <static_cast>: Switch to toFoo for Accessibility Objects. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/accessibility/AccessibilityTable.cpp
diff --git a/Source/core/accessibility/AccessibilityTable.cpp b/Source/core/accessibility/AccessibilityTable.cpp
index 0eb08321ed049b2080e7194691027f44de9fd088..0e7590de9429f267532d477aec34d94922385693 100644
--- a/Source/core/accessibility/AccessibilityTable.cpp
+++ b/Source/core/accessibility/AccessibilityTable.cpp
@@ -354,7 +354,7 @@ void AccessibilityTable::addChildren()
if (!rowObject->isTableRow())
continue;
- AccessibilityTableRow* row = static_cast<AccessibilityTableRow*>(rowObject);
+ AccessibilityTableRow* row = toAccessibilityTableRow(rowObject);
// We need to check every cell for a new row, because cell spans
// can cause us to miss rows if we just check the first column.
if (appendedRows.contains(row))
@@ -373,7 +373,7 @@ void AccessibilityTable::addChildren()
// make the columns based on the number of columns in the first body
unsigned length = initialTableSection->numColumns();
for (unsigned i = 0; i < length; ++i) {
- AccessibilityTableColumn* column = static_cast<AccessibilityTableColumn*>(axCache->getOrCreate(ColumnRole));
+ AccessibilityTableColumn* column = toAccessibilityTableColumn(axCache->getOrCreate(ColumnRole));
column->setColumnIndex((int)i);
column->setParent(this);
m_columns.append(column);
@@ -421,7 +421,7 @@ void AccessibilityTable::columnHeaders(AccessibilityChildrenVector& headers)
unsigned colCount = m_columns.size();
for (unsigned k = 0; k < colCount; ++k) {
- AccessibilityObject* header = static_cast<AccessibilityTableColumn*>(m_columns[k].get())->headerObject();
+ AccessibilityObject* header = toAccessibilityTableColumn(m_columns[k].get())->headerObject();
if (!header)
continue;
headers.append(header);
@@ -488,7 +488,7 @@ AccessibilityTableCell* AccessibilityTable::cellForColumnAndRow(unsigned column,
pair<unsigned, unsigned> columnRange;
pair<unsigned, unsigned> rowRange;
- AccessibilityTableCell* tableCellChild = static_cast<AccessibilityTableCell*>(child);
+ AccessibilityTableCell* tableCellChild = toAccessibilityTableCell(child);
tableCellChild->columnIndexRange(columnRange);
tableCellChild->rowIndexRange(rowRange);
« no previous file with comments | « Source/core/accessibility/AccessibilityScrollbar.h ('k') | Source/core/accessibility/AccessibilityTableCell.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698