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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLLIElement.cpp

Issue 2164493002: Renamed Node::attach to Node::attachLayoutTree. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2006, 2007, 2010 Apple Inc. All rights reserved. 4 * Copyright (C) 2006, 2007, 2010 Apple Inc. 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 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 void HTMLLIElement::parseAttribute(const QualifiedName& name, const AtomicString & oldValue, const AtomicString& value) 84 void HTMLLIElement::parseAttribute(const QualifiedName& name, const AtomicString & oldValue, const AtomicString& value)
85 { 85 {
86 if (name == valueAttr) { 86 if (name == valueAttr) {
87 if (layoutObject() && layoutObject()->isListItem()) 87 if (layoutObject() && layoutObject()->isListItem())
88 parseValue(value); 88 parseValue(value);
89 } else { 89 } else {
90 HTMLElement::parseAttribute(name, oldValue, value); 90 HTMLElement::parseAttribute(name, oldValue, value);
91 } 91 }
92 } 92 }
93 93
94 void HTMLLIElement::attach(const AttachContext& context) 94 void HTMLLIElement::attachLayoutTree(const AttachContext& context)
95 { 95 {
96 HTMLElement::attach(context); 96 HTMLElement::attachLayoutTree(context);
97 97
98 if (layoutObject() && layoutObject()->isListItem()) { 98 if (layoutObject() && layoutObject()->isListItem()) {
99 LayoutLIItem liLayoutItem = LayoutLIItem(toLayoutListItem(layoutObject() )); 99 LayoutLIItem liLayoutItem = LayoutLIItem(toLayoutListItem(layoutObject() ));
100 100
101 ASSERT(!document().childNeedsDistributionRecalc()); 101 ASSERT(!document().childNeedsDistributionRecalc());
102 102
103 // Find the enclosing list node. 103 // Find the enclosing list node.
104 Element* listNode = 0; 104 Element* listNode = 0;
105 Element* current = this; 105 Element* current = this;
106 while (!listNode) { 106 while (!listNode) {
(...skipping 19 matching lines...) Expand all
126 126
127 bool valueOK; 127 bool valueOK;
128 int requestedValue = value.toInt(&valueOK); 128 int requestedValue = value.toInt(&valueOK);
129 if (valueOK) 129 if (valueOK)
130 toLayoutListItem(layoutObject())->setExplicitValue(requestedValue); 130 toLayoutListItem(layoutObject())->setExplicitValue(requestedValue);
131 else 131 else
132 toLayoutListItem(layoutObject())->clearExplicitValue(); 132 toLayoutListItem(layoutObject())->clearExplicitValue();
133 } 133 }
134 134
135 } // namespace blink 135 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698