| OLD | NEW |
| 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) 2010 Apple Inc. All rights reserved. | 4 * Copyright (C) 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 14 matching lines...) Expand all Loading... |
| 25 | 25 |
| 26 #include "CSSPropertyNames.h" | 26 #include "CSSPropertyNames.h" |
| 27 #include "CSSValueKeywords.h" | 27 #include "CSSValueKeywords.h" |
| 28 #include "HTMLNames.h" | 28 #include "HTMLNames.h" |
| 29 #include "core/rendering/RenderListItem.h" | 29 #include "core/rendering/RenderListItem.h" |
| 30 | 30 |
| 31 namespace WebCore { | 31 namespace WebCore { |
| 32 | 32 |
| 33 using namespace HTMLNames; | 33 using namespace HTMLNames; |
| 34 | 34 |
| 35 HTMLOListElement::HTMLOListElement(const QualifiedName& tagName, Document* docum
ent) | 35 HTMLOListElement::HTMLOListElement(const QualifiedName& tagName, Document& docum
ent) |
| 36 : HTMLElement(tagName, document) | 36 : HTMLElement(tagName, document) |
| 37 , m_start(0xBADBEEF) | 37 , m_start(0xBADBEEF) |
| 38 , m_itemCount(0) | 38 , m_itemCount(0) |
| 39 , m_hasExplicitStart(false) | 39 , m_hasExplicitStart(false) |
| 40 , m_isReversed(false) | 40 , m_isReversed(false) |
| 41 , m_shouldRecalculateItemCount(false) | 41 , m_shouldRecalculateItemCount(false) |
| 42 { | 42 { |
| 43 ASSERT(hasTagName(olTag)); | 43 ASSERT(hasTagName(olTag)); |
| 44 ScriptWrappable::init(this); | 44 ScriptWrappable::init(this); |
| 45 } | 45 } |
| 46 | 46 |
| 47 PassRefPtr<HTMLOListElement> HTMLOListElement::create(Document* document) | 47 PassRefPtr<HTMLOListElement> HTMLOListElement::create(Document& document) |
| 48 { | 48 { |
| 49 return adoptRef(new HTMLOListElement(olTag, document)); | 49 return adoptRef(new HTMLOListElement(olTag, document)); |
| 50 } | 50 } |
| 51 | 51 |
| 52 PassRefPtr<HTMLOListElement> HTMLOListElement::create(const QualifiedName& tagNa
me, Document* document) | 52 PassRefPtr<HTMLOListElement> HTMLOListElement::create(const QualifiedName& tagNa
me, Document& document) |
| 53 { | 53 { |
| 54 return adoptRef(new HTMLOListElement(tagName, document)); | 54 return adoptRef(new HTMLOListElement(tagName, document)); |
| 55 } | 55 } |
| 56 | 56 |
| 57 bool HTMLOListElement::isPresentationAttribute(const QualifiedName& name) const | 57 bool HTMLOListElement::isPresentationAttribute(const QualifiedName& name) const |
| 58 { | 58 { |
| 59 if (name == typeAttr) | 59 if (name == typeAttr) |
| 60 return true; | 60 return true; |
| 61 return HTMLElement::isPresentationAttribute(name); | 61 return HTMLElement::isPresentationAttribute(name); |
| 62 } | 62 } |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 RenderListItem::updateItemValuesForOrderedList(this); | 109 RenderListItem::updateItemValuesForOrderedList(this); |
| 110 } | 110 } |
| 111 | 111 |
| 112 void HTMLOListElement::recalculateItemCount() | 112 void HTMLOListElement::recalculateItemCount() |
| 113 { | 113 { |
| 114 m_itemCount = RenderListItem::itemCountForOrderedList(this); | 114 m_itemCount = RenderListItem::itemCountForOrderedList(this); |
| 115 m_shouldRecalculateItemCount = false; | 115 m_shouldRecalculateItemCount = false; |
| 116 } | 116 } |
| 117 | 117 |
| 118 } | 118 } |
| OLD | NEW |