diff --git a/accessible/xpcom/xpcAccessibleTable.cpp b/accessible/xpcom/xpcAccessibleTable.cpp index 080c5bdd835f..0bb541bfaa0c 100644 --- a/accessible/xpcom/xpcAccessibleTable.cpp +++ b/accessible/xpcom/xpcAccessibleTable.cpp @@ -6,8 +6,8 @@ #include "xpcAccessibleTable.h" -#include "LocalAccessible.h" -#include "TableAccessible.h" +#include "mozilla/a11y/Accessible.h" +#include "mozilla/a11y/TableAccessibleBase.h" #include "nsIMutableArray.h" #include "nsComponentManagerUtils.h" diff --git a/accessible/xpcom/xpcAccessibleTable.h b/accessible/xpcom/xpcAccessibleTable.h index 5517a43a84e6..5cdb5e5b3f4f 100644 --- a/accessible/xpcom/xpcAccessibleTable.h +++ b/accessible/xpcom/xpcAccessibleTable.h @@ -12,6 +12,7 @@ namespace mozilla { namespace a11y { +class TableAccessibleBase; /** * XPCOM wrapper around TableAccessible class. @@ -65,9 +66,7 @@ class xpcAccessibleTable : public xpcAccessibleHyperText, virtual ~xpcAccessibleTable() {} private: - TableAccessible* Intl() { - return mIntl->IsLocal() ? mIntl->AsLocal()->AsTable() : nullptr; - } + TableAccessibleBase* Intl() { return mIntl->AsTableBase(); } xpcAccessibleTable(const xpcAccessibleTable&) = delete; xpcAccessibleTable& operator=(const xpcAccessibleTable&) = delete; diff --git a/accessible/xpcom/xpcAccessibleTableCell.cpp b/accessible/xpcom/xpcAccessibleTableCell.cpp index 2c2e28027f20..2577e63e8cfd 100644 --- a/accessible/xpcom/xpcAccessibleTableCell.cpp +++ b/accessible/xpcom/xpcAccessibleTableCell.cpp @@ -6,10 +6,10 @@ #include "xpcAccessibleTableCell.h" -#include "LocalAccessible.h" +#include "mozilla/a11y/Accessible.h" +#include "mozilla/a11y/TableAccessibleBase.h" +#include "mozilla/a11y/TableCellAccessibleBase.h" #include "nsIAccessibleTable.h" -#include "TableAccessible.h" -#include "TableCellAccessible.h" #include "nsComponentManagerUtils.h" #include "nsIMutableArray.h" @@ -34,7 +34,7 @@ xpcAccessibleTableCell::GetTable(nsIAccessibleTable** aTable) { if (!Intl()) return NS_ERROR_FAILURE; - TableAccessible* table = Intl()->Table(); + TableAccessibleBase* table = Intl()->Table(); if (!table) return NS_ERROR_FAILURE; nsCOMPtr xpcTable = do_QueryInterface( diff --git a/accessible/xpcom/xpcAccessibleTableCell.h b/accessible/xpcom/xpcAccessibleTableCell.h index e1fad4550ee6..b0f1ebb547cf 100644 --- a/accessible/xpcom/xpcAccessibleTableCell.h +++ b/accessible/xpcom/xpcAccessibleTableCell.h @@ -13,6 +13,7 @@ namespace mozilla { namespace a11y { +class TableCellAccessibleBase; /** * XPCOM wrapper around TableAccessibleCell class. @@ -39,13 +40,7 @@ class xpcAccessibleTableCell : public xpcAccessibleHyperText, virtual ~xpcAccessibleTableCell() {} private: - TableCellAccessible* Intl() { - if (LocalAccessible* acc = mIntl->AsLocal()) { - return acc->AsTableCell(); - } - - return nullptr; - } + TableCellAccessibleBase* Intl() { return mIntl->AsTableCellBase(); } xpcAccessibleTableCell(const xpcAccessibleTableCell&) = delete; xpcAccessibleTableCell& operator=(const xpcAccessibleTableCell&) = delete;