diff --git a/mozilla/content/html/style/src/nsHTMLStyleSheet.cpp b/mozilla/content/html/style/src/nsHTMLStyleSheet.cpp
index c28be5ae538..3fcab47be96 100644
--- a/mozilla/content/html/style/src/nsHTMLStyleSheet.cpp
+++ b/mozilla/content/html/style/src/nsHTMLStyleSheet.cpp
@@ -813,22 +813,15 @@ HTMLStyleSheetImpl::RulesMatching(nsIPresContext* aPresContext,
}
} // end link/visited/active rules
} // end A tag
- // add the quirks background compatibility rule if in quirks mode
- // and/or the Table TH rule for handling
differently than |
- else if ((tag == nsHTMLAtoms::td) ||
- (tag == nsHTMLAtoms::th) ||
- (tag == nsHTMLAtoms::tr) ||
- (tag == nsHTMLAtoms::thead) || // Nav4.X doesn't support row groups, but it is a lot
- (tag == nsHTMLAtoms::tbody) || // easier passing from the table to rows this way
- (tag == nsHTMLAtoms::tfoot)) {
- // add the rule to handle text-align for a |
- if (tag == nsHTMLAtoms::th) {
+ // add the rule to handle text-align for a |
+ else if (tag == nsHTMLAtoms::th) {
aRuleWalker->Forward(mTableTHRule);
- }
- nsCompatibility mode;
- aPresContext->GetCompatibilityMode(&mode);
- if (eCompatibility_NavQuirks == mode) {
- if (mDocumentColorRule) {
+ }
+ else if (tag == nsHTMLAtoms::table) {
+ if (mDocumentColorRule) {
+ nsCompatibility mode;
+ aPresContext->GetCompatibilityMode(&mode);
+ if (eCompatibility_NavQuirks == mode) {
aRuleWalker->Forward(mDocumentColorRule);
}
}
diff --git a/mozilla/layout/style/nsHTMLStyleSheet.cpp b/mozilla/layout/style/nsHTMLStyleSheet.cpp
index c28be5ae538..3fcab47be96 100644
--- a/mozilla/layout/style/nsHTMLStyleSheet.cpp
+++ b/mozilla/layout/style/nsHTMLStyleSheet.cpp
@@ -813,22 +813,15 @@ HTMLStyleSheetImpl::RulesMatching(nsIPresContext* aPresContext,
}
} // end link/visited/active rules
} // end A tag
- // add the quirks background compatibility rule if in quirks mode
- // and/or the Table TH rule for handling | differently than |
- else if ((tag == nsHTMLAtoms::td) ||
- (tag == nsHTMLAtoms::th) ||
- (tag == nsHTMLAtoms::tr) ||
- (tag == nsHTMLAtoms::thead) || // Nav4.X doesn't support row groups, but it is a lot
- (tag == nsHTMLAtoms::tbody) || // easier passing from the table to rows this way
- (tag == nsHTMLAtoms::tfoot)) {
- // add the rule to handle text-align for a |
- if (tag == nsHTMLAtoms::th) {
+ // add the rule to handle text-align for a |
+ else if (tag == nsHTMLAtoms::th) {
aRuleWalker->Forward(mTableTHRule);
- }
- nsCompatibility mode;
- aPresContext->GetCompatibilityMode(&mode);
- if (eCompatibility_NavQuirks == mode) {
- if (mDocumentColorRule) {
+ }
+ else if (tag == nsHTMLAtoms::table) {
+ if (mDocumentColorRule) {
+ nsCompatibility mode;
+ aPresContext->GetCompatibilityMode(&mode);
+ if (eCompatibility_NavQuirks == mode) {
aRuleWalker->Forward(mDocumentColorRule);
}
}
|