Bug 1081683 - Check for table cells correctly when warning about positioned table parts. r=bz
authorSeth Fowler <seth@mozilla.com>
Mon, 13 Oct 2014 15:49:16 -0700
changeset 210271 3be7879798a27ff6625c5161543064f3cb859b74
parent 210270 212571e28648a736581a3ee54877bd037fbfb95c
child 210272 f5c56af59b28d1b5df7e0eeeddc159e4f29d63a8
push id1
push userroot
push dateMon, 20 Oct 2014 17:29:22 +0000
reviewersbz
bugs1081683
milestone35.0a1
Bug 1081683 - Check for table cells correctly when warning about positioned table parts. r=bz
layout/tables/nsTableFrame.cpp
--- a/layout/tables/nsTableFrame.cpp
+++ b/layout/tables/nsTableFrame.cpp
@@ -268,17 +268,17 @@ nsTableFrame::DestroyPositionedTablePart
 
 /* static */ void
 nsTableFrame::RegisterPositionedTablePart(nsIFrame* aFrame)
 {
   // Supporting relative positioning for table parts other than table cells has
   // the potential to break sites that apply 'position: relative' to those
   // parts, expecting nothing to happen. We warn at the console to make tracking
   // down the issue easy.
-  if (nsGkAtoms::tableCellFrame != aFrame->GetType()) {
+  if (!IS_TABLE_CELL(aFrame->GetType())) {
     nsIContent* content = aFrame->GetContent();
     nsPresContext* presContext = aFrame->PresContext();
     if (content && !presContext->HasWarnedAboutPositionedTableParts()) {
       presContext->SetHasWarnedAboutPositionedTableParts();
       nsContentUtils::ReportToConsole(nsIScriptError::warningFlag,
                                       NS_LITERAL_CSTRING("Layout: Tables"),
                                       content->OwnerDoc(),
                                       nsContentUtils::eLAYOUT_PROPERTIES,