| Index: third_party/WebKit/Source/core/dom/Element.h
|
| diff --git a/third_party/WebKit/Source/core/dom/Element.h b/third_party/WebKit/Source/core/dom/Element.h
|
| index 11609296c0342b452b9a1a758c2dc39cc0702cd3..e2690fe9ff02dfaa8eeb833a46e4bf58eec57ae6 100644
|
| --- a/third_party/WebKit/Source/core/dom/Element.h
|
| +++ b/third_party/WebKit/Source/core/dom/Element.h
|
| @@ -356,13 +356,24 @@ class CORE_EXPORT Element : public ContainerNode {
|
| // For exposing to DOM only.
|
| NamedNodeMap* attributesForBindings() const;
|
|
|
| - enum AttributeModificationReason { ModifiedDirectly, ModifiedByCloning };
|
| -
|
| - // This method is called whenever an attribute is added, changed or removed.
|
| + enum class AttributeModificationReason { kDirectly, kByParser, kByCloning };
|
| +
|
| + // |attributeChanged| is called whenever an attribute is added, changed or
|
| + // removed. It handles very common attributes such as id, class, name, style,
|
| + // and slot.
|
| + //
|
| + // While the owner document is parsed, this function is called after all
|
| + // attributes in a start tag were added to the element.
|
| virtual void attributeChanged(const QualifiedName&,
|
| const AtomicString& oldValue,
|
| const AtomicString& newValue,
|
| - AttributeModificationReason = ModifiedDirectly);
|
| + AttributeModificationReason);
|
| +
|
| + // |parseAttribute| is called by |attributeChanged|. If an element
|
| + // implementation needs to check an attribute update, override this function.
|
| + //
|
| + // While the owner document is parsed, this function is called after all
|
| + // attributes in a start tag were added to the element.
|
| virtual void parseAttribute(const QualifiedName&,
|
| const AtomicString& oldValue,
|
| const AtomicString& newValue);
|
|
|