| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Nikita Vasilyev. All rights reserved. | 2 * Copyright (C) 2010 Nikita Vasilyev. All rights reserved. |
| 3 * Copyright (C) 2010 Joseph Pecoraro. All rights reserved. | 3 * Copyright (C) 2010 Joseph Pecoraro. All rights reserved. |
| 4 * Copyright (C) 2010 Google Inc. All rights reserved. | 4 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions are | 7 * modification, are permitted provided that the following conditions are |
| 8 * met: | 8 * met: |
| 9 * | 9 * |
| 10 * * Redistributions of source code must retain the above copyright | 10 * * Redistributions of source code must retain the above copyright |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 131 var hasSupportedProperties = WebInspector.CSSMetadata.cssPropertiesMetainfo.
_values.length > 0; | 131 var hasSupportedProperties = WebInspector.CSSMetadata.cssPropertiesMetainfo.
_values.length > 0; |
| 132 if (!match || (hasSupportedProperties && !propertiesSet.hasOwnProperty(match
[1].toLowerCase()))) | 132 if (!match || (hasSupportedProperties && !propertiesSet.hasOwnProperty(match
[1].toLowerCase()))) |
| 133 return name.toLowerCase(); | 133 return name.toLowerCase(); |
| 134 return match[1].toLowerCase(); | 134 return match[1].toLowerCase(); |
| 135 } | 135 } |
| 136 | 136 |
| 137 /** | 137 /** |
| 138 * @param {string} propertyName | 138 * @param {string} propertyName |
| 139 * @return {boolean} | 139 * @return {boolean} |
| 140 */ | 140 */ |
| 141 WebInspector.CSSMetadata.isCSSPropertyName = function(propertyName) |
| 142 { |
| 143 if (propertyName.startsWith("-moz-") || propertyName.startsWith("-o-") || pr
opertyName.startsWith("-webkit-") || propertyName.startsWith("-ms-")) |
| 144 return true; |
| 145 var hasSupportedProperties = WebInspector.CSSMetadata.cssPropertiesMetainfo.
_values.length > 0; |
| 146 return !hasSupportedProperties || WebInspector.CSSMetadata.cssPropertiesMeta
infoKeySet().hasOwnProperty(propertyName); |
| 147 } |
| 148 |
| 149 /** |
| 150 * @param {string} propertyName |
| 151 * @return {boolean} |
| 152 */ |
| 141 WebInspector.CSSMetadata.isPropertyInherited = function(propertyName) | 153 WebInspector.CSSMetadata.isPropertyInherited = function(propertyName) |
| 142 { | 154 { |
| 143 return !!(WebInspector.CSSMetadata.InheritedProperties[WebInspector.CSSMetad
ata.canonicalPropertyName(propertyName)] | 155 return !!(WebInspector.CSSMetadata.InheritedProperties[WebInspector.CSSMetad
ata.canonicalPropertyName(propertyName)] |
| 144 || WebInspector.CSSMetadata.NonStandardInheritedProperties[propertyN
ame.toLowerCase()]); | 156 || WebInspector.CSSMetadata.NonStandardInheritedProperties[propertyN
ame.toLowerCase()]); |
| 145 } | 157 } |
| 146 | 158 |
| 147 WebInspector.CSSMetadata._distanceProperties = [ | 159 WebInspector.CSSMetadata._distanceProperties = [ |
| 148 'background-position', 'border-spacing', 'bottom', 'font-size', 'height', 'l
eft', 'letter-spacing', 'max-height', 'max-width', 'min-height', | 160 'background-position', 'border-spacing', 'bottom', 'font-size', 'height', 'l
eft', 'letter-spacing', 'max-height', 'max-width', 'min-height', |
| 149 'min-width', 'right', 'text-indent', 'top', 'width', 'word-spacing' | 161 'min-width', 'right', 'text-indent', 'top', 'width', 'word-spacing' |
| 150 ]; | 162 ]; |
| (...skipping 910 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1061 * @param {string} longhand | 1073 * @param {string} longhand |
| 1062 * @return {?Array.<string>} | 1074 * @return {?Array.<string>} |
| 1063 */ | 1075 */ |
| 1064 shorthands: function(longhand) | 1076 shorthands: function(longhand) |
| 1065 { | 1077 { |
| 1066 return this._shorthands[longhand]; | 1078 return this._shorthands[longhand]; |
| 1067 } | 1079 } |
| 1068 } | 1080 } |
| 1069 | 1081 |
| 1070 WebInspector.CSSMetadata.initializeWithSupportedProperties([]); | 1082 WebInspector.CSSMetadata.initializeWithSupportedProperties([]); |
| OLD | NEW |