Changeset 200952 in webkit
- Timestamp:
- May 16, 2016 11:26:32 AM (8 years ago)
- Location:
- trunk/Source/WebInspectorUI
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebInspectorUI/ChangeLog
r200949 r200952 1 2016-05-16 Antoine Quint <graouts@apple.com> 2 3 Web Inspector: Computed style shows both prefixed and unprefixed variants of properties 4 https://bugs.webkit.org/show_bug.cgi?id=157674 5 <rdar://problem/24339756> 6 7 Reviewed by Timothy Hatcher. 8 9 We make the CSSProperty `implicit` property read-write, and in the case where a computed style 10 has a property marked as explicit, we also check that it's found in matching rules to consider 11 it non-implicit. This correctly filters out variants of properties set explicitly. 12 13 * UserInterface/Models/CSSProperty.js: 14 (WebInspector.CSSProperty.prototype.set implicit): 15 * UserInterface/Models/DOMNodeStyles.js: 16 (WebInspector.DOMNodeStyles.prototype.refresh.fetchedComputedStyle): 17 (WebInspector.DOMNodeStyles.prototype.refresh): 18 (WebInspector.DOMNodeStyles.prototype._isPropertyFoundInMatchingRules): 19 (WebInspector.DOMNodeStyles): 20 1 21 2016-05-14 Timothy Hatcher <timothy@apple.com> 2 22 -
trunk/Source/WebInspectorUI/UserInterface/Models/CSSProperty.js
r196597 r200952 200 200 } 201 201 202 get implicit() 203 { 204 return this._implicit; 205 } 202 get implicit() { return this._implicit; } 203 set implicit(implicit) { this._implicit = implicit; } 206 204 207 205 get anonymous() -
trunk/Source/WebInspectorUI/UserInterface/Models/DOMNodeStyles.js
r196867 r200952 151 151 152 152 var property = this._parseStylePropertyPayload(propertyPayload, NaN, this._computedStyle); 153 if (!property.implicit) 154 property.implicit = !this._isPropertyFoundInMatchingRules(property.name); 153 155 properties.push(property); 154 156 } … … 954 956 } 955 957 } 958 959 _isPropertyFoundInMatchingRules(propertyName) 960 { 961 return this._orderedStyles.some((style) => { 962 return style.properties.some((property) => property.name === propertyName); 963 }); 964 } 956 965 }; 957 966
Note: See TracChangeset
for help on using the changeset viewer.