| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1997 Martin Jones (mjones@kde.org) | 2 * Copyright (C) 1997 Martin Jones (mjones@kde.org) |
| 3 * (C) 1997 Torben Weis (weis@kde.org) | 3 * (C) 1997 Torben Weis (weis@kde.org) |
| 4 * (C) 1998 Waldo Bastian (bastian@kde.org) | 4 * (C) 1998 Waldo Bastian (bastian@kde.org) |
| 5 * (C) 1999 Lars Knoll (knoll@kde.org) | 5 * (C) 1999 Lars Knoll (knoll@kde.org) |
| 6 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 6 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 7 * Copyright (C) 2003, 2004, 2005, 2006, 2009 Apple Inc. All rights reserved. | 7 * Copyright (C) 2003, 2004, 2005, 2006, 2009 Apple Inc. All rights reserved. |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 public: | 64 public: |
| 65 RenderTableSection(Element*); | 65 RenderTableSection(Element*); |
| 66 virtual ~RenderTableSection(); | 66 virtual ~RenderTableSection(); |
| 67 | 67 |
| 68 RenderObject* firstChild() const { ASSERT(children() == virtualChildren());
return children()->firstChild(); } | 68 RenderObject* firstChild() const { ASSERT(children() == virtualChildren());
return children()->firstChild(); } |
| 69 RenderObject* lastChild() const { ASSERT(children() == virtualChildren()); r
eturn children()->lastChild(); } | 69 RenderObject* lastChild() const { ASSERT(children() == virtualChildren()); r
eturn children()->lastChild(); } |
| 70 | 70 |
| 71 const RenderObjectChildList* children() const { return &m_children; } | 71 const RenderObjectChildList* children() const { return &m_children; } |
| 72 RenderObjectChildList* children() { return &m_children; } | 72 RenderObjectChildList* children() { return &m_children; } |
| 73 | 73 |
| 74 virtual void addChild(RenderObject* child, RenderObject* beforeChild = 0); | 74 virtual void addChild(RenderObject* child, RenderObject* beforeChild = 0) OV
ERRIDE; |
| 75 | 75 |
| 76 virtual int firstLineBoxBaseline() const OVERRIDE; | 76 virtual int firstLineBoxBaseline() const OVERRIDE; |
| 77 | 77 |
| 78 void addCell(RenderTableCell*, RenderTableRow* row); | 78 void addCell(RenderTableCell*, RenderTableRow* row); |
| 79 | 79 |
| 80 int calcRowLogicalHeight(); | 80 int calcRowLogicalHeight(); |
| 81 void layoutRows(); | 81 void layoutRows(); |
| 82 void computeOverflowFromCells(); | 82 void computeOverflowFromCells(); |
| 83 | 83 |
| 84 RenderTable* table() const { return toRenderTable(parent()); } | 84 RenderTable* table() const { return toRenderTable(parent()); } |
| (...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 211 | 211 |
| 212 static RenderTableSection* createAnonymousWithParentRenderer(const RenderObj
ect*); | 212 static RenderTableSection* createAnonymousWithParentRenderer(const RenderObj
ect*); |
| 213 virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject* pare
nt) const OVERRIDE | 213 virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject* pare
nt) const OVERRIDE |
| 214 { | 214 { |
| 215 return createAnonymousWithParentRenderer(parent); | 215 return createAnonymousWithParentRenderer(parent); |
| 216 } | 216 } |
| 217 | 217 |
| 218 virtual void paint(PaintInfo&, const LayoutPoint&) OVERRIDE; | 218 virtual void paint(PaintInfo&, const LayoutPoint&) OVERRIDE; |
| 219 | 219 |
| 220 protected: | 220 protected: |
| 221 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle); | 221 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) OV
ERRIDE; |
| 222 | 222 |
| 223 private: | 223 private: |
| 224 virtual RenderObjectChildList* virtualChildren() { return children(); } | 224 virtual RenderObjectChildList* virtualChildren() OVERRIDE { return children(
); } |
| 225 virtual const RenderObjectChildList* virtualChildren() const { return childr
en(); } | 225 virtual const RenderObjectChildList* virtualChildren() const OVERRIDE { retu
rn children(); } |
| 226 | 226 |
| 227 virtual const char* renderName() const { return (isAnonymous() || isPseudoEl
ement()) ? "RenderTableSection (anonymous)" : "RenderTableSection"; } | 227 virtual const char* renderName() const OVERRIDE { return (isAnonymous() || i
sPseudoElement()) ? "RenderTableSection (anonymous)" : "RenderTableSection"; } |
| 228 | 228 |
| 229 virtual bool isTableSection() const { return true; } | 229 virtual bool isTableSection() const OVERRIDE { return true; } |
| 230 | 230 |
| 231 virtual void willBeRemovedFromTree() OVERRIDE; | 231 virtual void willBeRemovedFromTree() OVERRIDE; |
| 232 | 232 |
| 233 virtual void layout(); | 233 virtual void layout() OVERRIDE; |
| 234 | 234 |
| 235 virtual void paintCell(RenderTableCell*, PaintInfo&, const LayoutPoint&); | 235 void paintCell(RenderTableCell*, PaintInfo&, const LayoutPoint&); |
| 236 virtual void paintObject(PaintInfo&, const LayoutPoint&); | 236 virtual void paintObject(PaintInfo&, const LayoutPoint&) OVERRIDE; |
| 237 | 237 |
| 238 virtual void imageChanged(WrappedImagePtr, const IntRect* = 0); | 238 virtual void imageChanged(WrappedImagePtr, const IntRect* = 0) OVERRIDE; |
| 239 | 239 |
| 240 virtual bool nodeAtPoint(const HitTestRequest&, HitTestResult&, const HitTes
tLocation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAct
ion) OVERRIDE; | 240 virtual bool nodeAtPoint(const HitTestRequest&, HitTestResult&, const HitTes
tLocation& locationInContainer, const LayoutPoint& accumulatedOffset, HitTestAct
ion) OVERRIDE; |
| 241 | 241 |
| 242 int borderSpacingForRow(unsigned row) const { return m_grid[row].rowRenderer
? table()->vBorderSpacing() : 0; } | 242 int borderSpacingForRow(unsigned row) const { return m_grid[row].rowRenderer
? table()->vBorderSpacing() : 0; } |
| 243 | 243 |
| 244 void ensureRows(unsigned); | 244 void ensureRows(unsigned); |
| 245 | 245 |
| 246 bool rowHasOnlySpanningCells(unsigned); | 246 bool rowHasOnlySpanningCells(unsigned); |
| 247 unsigned calcRowHeightHavingOnlySpanningCells(unsigned); | 247 unsigned calcRowHeightHavingOnlySpanningCells(unsigned); |
| 248 void updateRowsHeightHavingOnlySpanningCells(RenderTableCell*, struct Spanni
ngRowsHeight&); | 248 void updateRowsHeightHavingOnlySpanningCells(RenderTableCell*, struct Spanni
ngRowsHeight&); |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 306 // This map holds the collapsed border values for cells with collapsed borde
rs. | 306 // This map holds the collapsed border values for cells with collapsed borde
rs. |
| 307 // It is held at RenderTableSection level to spare memory consumption by tab
le cells. | 307 // It is held at RenderTableSection level to spare memory consumption by tab
le cells. |
| 308 HashMap<pair<const RenderTableCell*, int>, CollapsedBorderValue > m_cellsCol
lapsedBorders; | 308 HashMap<pair<const RenderTableCell*, int>, CollapsedBorderValue > m_cellsCol
lapsedBorders; |
| 309 }; | 309 }; |
| 310 | 310 |
| 311 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderTableSection, isTableSection()); | 311 DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderTableSection, isTableSection()); |
| 312 | 312 |
| 313 } // namespace WebCore | 313 } // namespace WebCore |
| 314 | 314 |
| 315 #endif // RenderTableSection_h | 315 #endif // RenderTableSection_h |
| OLD | NEW |