Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(257)

Unified Diff: Source/bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp

Issue 19555002: Translate viewport related meta tags into @viewport descriptors as suggested by the CSS Device Adap… (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp
diff --git a/Source/bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp b/Source/bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp
index 70649751ef792a9ab85c0bf235e44dfea68328c4..96196273617320ad4307c36d883ebf5b41ffb0b9 100644
--- a/Source/bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp
+++ b/Source/bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp
@@ -117,18 +117,19 @@ static CSSPropertyInfo* cssPropertyInfo(v8::Handle<v8::String> v8PropertyName)
unsigned i = 0;
- if (hasCSSPropertyNamePrefix(propertyName, "css"))
+ if (hasCSSPropertyNamePrefix(propertyName, "css")) {
i += 3;
- else if (hasCSSPropertyNamePrefix(propertyName, "pixel")) {
+ } else if (hasCSSPropertyNamePrefix(propertyName, "pixel")) {
i += 5;
hadPixelOrPosPrefix = true;
} else if (hasCSSPropertyNamePrefix(propertyName, "pos")) {
i += 3;
hadPixelOrPosPrefix = true;
- } else if (hasCSSPropertyNamePrefix(propertyName, "webkit"))
+ } else if (hasCSSPropertyNamePrefix(propertyName, "webkit")) {
builder.append('-');
- else if (isASCIIUpper(propertyName[0]))
+ } else if (hasCSSPropertyNamePrefix(propertyName, "internal") || isASCIIUpper(propertyName[0])) {
return 0;
+ }
builder.append(toASCIILower(propertyName[i++]));
@@ -163,8 +164,11 @@ void V8CSSStyleDeclaration::namedPropertyEnumeratorCustom(const v8::PropertyCall
if (propertyNames.isEmpty()) {
for (int id = firstCSSProperty; id <= lastCSSProperty; ++id) {
CSSPropertyID propertyId = static_cast<CSSPropertyID>(id);
- if (RuntimeCSSEnabled::isCSSPropertyEnabled(propertyId))
- propertyNames.append(getJSPropertyName(propertyId));
+ if (RuntimeCSSEnabled::isCSSPropertyEnabled(propertyId)) {
+ String propertyName = getJSPropertyName(propertyId);
+ if (!hasCSSPropertyNamePrefix(propertyName, "internal"))
+ propertyNames.append(propertyName);
+ }
}
sort(propertyNames.begin(), propertyNames.end(), codePointCompareLessThan);
propertyNamesLength = propertyNames.size();

Powered by Google App Engine
This is Rietveld 408576698