| OLD | NEW |
| 1 /* | 1 /* |
| 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) | 2 * (C) 1999-2003 Lars Knoll (knoll@kde.org) |
| 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All r
ights reserved. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All r
ights reserved. |
| 4 * Copyright (C) 2011 Research In Motion Limited. All rights reserved. | 4 * Copyright (C) 2011 Research In Motion Limited. All rights reserved. |
| 5 * | 5 * |
| 6 * This library is free software; you can redistribute it and/or | 6 * This library is free software; you can redistribute it and/or |
| 7 * modify it under the terms of the GNU Library General Public | 7 * modify it under the terms of the GNU Library General Public |
| 8 * License as published by the Free Software Foundation; either | 8 * License as published by the Free Software Foundation; either |
| 9 * version 2 of the License, or (at your option) any later version. | 9 * version 2 of the License, or (at your option) any later version. |
| 10 * | 10 * |
| (...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 293 void AbstractPropertySetCSSStyleDeclaration::setPropertyInternal( | 293 void AbstractPropertySetCSSStyleDeclaration::setPropertyInternal( |
| 294 CSSPropertyID unresolvedProperty, | 294 CSSPropertyID unresolvedProperty, |
| 295 const String& customPropertyName, | 295 const String& customPropertyName, |
| 296 const String& value, | 296 const String& value, |
| 297 bool important, | 297 bool important, |
| 298 ExceptionState&) { | 298 ExceptionState&) { |
| 299 StyleAttributeMutationScope mutationScope(this); | 299 StyleAttributeMutationScope mutationScope(this); |
| 300 willMutate(); | 300 willMutate(); |
| 301 | 301 |
| 302 bool changed = false; | 302 bool changed = false; |
| 303 if (unresolvedProperty == CSSPropertyVariable) | 303 if (unresolvedProperty == CSSPropertyVariable) { |
| 304 bool isAnimationTainted = isKeyframeStyle(); |
| 304 changed = propertySet().setProperty(AtomicString(customPropertyName), value, | 305 changed = propertySet().setProperty(AtomicString(customPropertyName), value, |
| 305 important, contextStyleSheet()); | 306 important, contextStyleSheet(), |
| 306 else | 307 isAnimationTainted); |
| 308 } else { |
| 307 changed = propertySet().setProperty(unresolvedProperty, value, important, | 309 changed = propertySet().setProperty(unresolvedProperty, value, important, |
| 308 contextStyleSheet()); | 310 contextStyleSheet()); |
| 311 } |
| 309 | 312 |
| 310 didMutate(changed ? PropertyChanged : NoChanges); | 313 didMutate(changed ? PropertyChanged : NoChanges); |
| 311 | 314 |
| 312 if (!changed) | 315 if (!changed) |
| 313 return; | 316 return; |
| 314 | 317 |
| 315 Element* parent = parentElement(); | 318 Element* parent = parentElement(); |
| 316 if (parent) | 319 if (parent) |
| 317 parent->document().styleEngine().attributeChangedForElement( | 320 parent->document().styleEngine().attributeChangedForElement( |
| 318 HTMLNames::styleAttr, *parent); | 321 HTMLNames::styleAttr, *parent); |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 392 return m_parentElement ? &m_parentElement->document().elementSheet() | 395 return m_parentElement ? &m_parentElement->document().elementSheet() |
| 393 : nullptr; | 396 : nullptr; |
| 394 } | 397 } |
| 395 | 398 |
| 396 DEFINE_TRACE(InlineCSSStyleDeclaration) { | 399 DEFINE_TRACE(InlineCSSStyleDeclaration) { |
| 397 visitor->trace(m_parentElement); | 400 visitor->trace(m_parentElement); |
| 398 AbstractPropertySetCSSStyleDeclaration::trace(visitor); | 401 AbstractPropertySetCSSStyleDeclaration::trace(visitor); |
| 399 } | 402 } |
| 400 | 403 |
| 401 } // namespace blink | 404 } // namespace blink |
| OLD | NEW |