mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-25 19:25:43 +00:00
Bug 1456364 part 2 - Remove PropertyParseType. r=emilio
MozReview-Commit-ID: 3JDLVKJAlpv --HG-- extra : source : 29534ace671e8722c5c37cee9dfe3a9f176d6f9a
This commit is contained in:
parent
0d91cc33ac
commit
cc5438b5f8
@ -382,8 +382,8 @@ InspectorUtils::GetCSSPropertyNames(GlobalObject& aGlobalObject,
|
||||
|
||||
uint32_t prop = 0;
|
||||
for ( ; prop < eCSSProperty_COUNT_no_shorthands; ++prop) {
|
||||
if (nsCSSProps::PropertyParseType(nsCSSPropertyID(prop)) !=
|
||||
CSS_PROPERTY_PARSE_INACCESSIBLE) {
|
||||
if (!nsCSSProps::PropHasFlags(nsCSSPropertyID(prop),
|
||||
CSS_PROPERTY_PARSE_INACCESSIBLE)) {
|
||||
appendProperty(prop);
|
||||
}
|
||||
}
|
||||
|
@ -124,10 +124,6 @@
|
||||
|
||||
// Flags for the kFlagsTable bitfield (flags_ in nsCSSPropList.h)
|
||||
|
||||
// Define what mechanism the CSS parser uses for parsing the property.
|
||||
// See CSSParserImpl::ParseProperty(nsCSSPropertyID). Don't use 0 so that
|
||||
// we can verify that every property sets one of the values.
|
||||
#define CSS_PROPERTY_PARSE_PROPERTY_MASK (7<<9)
|
||||
#define CSS_PROPERTY_PARSE_INACCESSIBLE (1<<9)
|
||||
|
||||
// There's a free bit here.
|
||||
@ -289,21 +285,9 @@ public:
|
||||
{
|
||||
MOZ_ASSERT(0 <= aProperty && aProperty < eCSSProperty_COUNT,
|
||||
"out of range");
|
||||
MOZ_ASSERT(!(aFlags & CSS_PROPERTY_PARSE_PROPERTY_MASK),
|
||||
"The CSS_PROPERTY_PARSE_* values are not bitflags; don't pass "
|
||||
"them to PropHasFlags. You probably want PropertyParseType "
|
||||
"instead.");
|
||||
return (nsCSSProps::kFlagsTable[aProperty] & aFlags) == aFlags;
|
||||
}
|
||||
|
||||
static inline uint32_t PropertyParseType(nsCSSPropertyID aProperty)
|
||||
{
|
||||
MOZ_ASSERT(0 <= aProperty && aProperty < eCSSProperty_COUNT,
|
||||
"out of range");
|
||||
return nsCSSProps::kFlagsTable[aProperty] &
|
||||
CSS_PROPERTY_PARSE_PROPERTY_MASK;
|
||||
}
|
||||
|
||||
private:
|
||||
static const uint32_t kParserVariantTable[eCSSProperty_COUNT_no_shorthands];
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user