Bug 1097499 part 3 - Add a separate anonbox for text nodes. r=heycam
MozReview-Commit-ID: 1GfoFEGhyka
This commit is contained in:
@@ -35,6 +35,7 @@
|
||||
#include "nsColor.h"
|
||||
#include "nsCSSPseudoClasses.h"
|
||||
#include "nsCSSPseudoElements.h"
|
||||
#include "nsCSSAnonBoxes.h"
|
||||
#include "nsNameSpaceManager.h"
|
||||
#include "nsXMLNameSpaceMap.h"
|
||||
#include "nsError.h"
|
||||
@@ -5927,6 +5928,13 @@ CSSParserImpl::ParsePseudoSelector(int32_t& aDataMask,
|
||||
return eSelectorParsingStatus_Error;
|
||||
}
|
||||
|
||||
if (nsCSSAnonBoxes::IsNonElement(pseudo)) {
|
||||
// Non-element anonymous boxes should not match any rule.
|
||||
REPORT_UNEXPECTED_TOKEN(PEPseudoSelUnknown);
|
||||
UngetToken();
|
||||
return eSelectorParsingStatus_Error;
|
||||
}
|
||||
|
||||
// We currently allow :-moz-placeholder and ::-moz-placeholder. We have to
|
||||
// be a bit stricter regarding the pseudo-element parsing rules.
|
||||
if (pseudoElementType == CSSPseudoElementType::mozPlaceholder &&
|
||||
|
||||
Reference in New Issue
Block a user