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

Side by Side Diff: Source/WebCore/rendering/RenderListItem.cpp

Issue 10914111: Merge 125737 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1229/
Patch Set: Created 8 years, 3 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
« no previous file with comments | « Source/WebCore/rendering/RenderListItem.h ('k') | Source/WebCore/rendering/RenderObject.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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) 2003, 2004, 2005, 2006, 2010 Apple Inc. All rights reserved. 4 * Copyright (C) 2003, 2004, 2005, 2006, 2010 Apple Inc. All rights reserved.
5 * Copyright (C) 2006 Andrew Wellington (proton@wiretapped.net) 5 * Copyright (C) 2006 Andrew Wellington (proton@wiretapped.net)
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 69
70 void RenderListItem::willBeDestroyed() 70 void RenderListItem::willBeDestroyed()
71 { 71 {
72 if (m_marker) { 72 if (m_marker) {
73 m_marker->destroy(); 73 m_marker->destroy();
74 m_marker = 0; 74 m_marker = 0;
75 } 75 }
76 RenderBlock::willBeDestroyed(); 76 RenderBlock::willBeDestroyed();
77 } 77 }
78 78
79 void RenderListItem::insertedIntoTree()
80 {
81 RenderBlock::insertedIntoTree();
82
83 updateListMarkerNumbers();
84 }
85
79 static bool isList(Node* node) 86 static bool isList(Node* node)
80 { 87 {
81 return (node->hasTagName(ulTag) || node->hasTagName(olTag)); 88 return (node->hasTagName(ulTag) || node->hasTagName(olTag));
82 } 89 }
83 90
84 static Node* enclosingList(const RenderListItem* listItem) 91 static Node* enclosingList(const RenderListItem* listItem)
85 { 92 {
86 Node* firstNode = 0; 93 Node* firstNode = 0;
87 94
88 for (const RenderObject* renderer = listItem->parent(); renderer; renderer = renderer->parent()) { 95 for (const RenderObject* renderer = listItem->parent(); renderer; renderer = renderer->parent()) {
(...skipping 389 matching lines...) Expand 10 before | Expand all | Expand 10 after
478 // assume that all the following ones have too. 485 // assume that all the following ones have too.
479 // This gives us the opportunity to stop here and avoid 486 // This gives us the opportunity to stop here and avoid
480 // marking the same nodes again. 487 // marking the same nodes again.
481 break; 488 break;
482 } 489 }
483 item->updateValue(); 490 item->updateValue();
484 } 491 }
485 } 492 }
486 493
487 } // namespace WebCore 494 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/WebCore/rendering/RenderListItem.h ('k') | Source/WebCore/rendering/RenderObject.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698