#ifndef RenderContainer_h
#define RenderContainer_h
#include "RenderBox.h"
namespace WebCore {
class RenderContainer : public RenderBox {
public:
RenderContainer(Node*);
virtual ~RenderContainer();
virtual RenderObject* firstChild() const { return m_firstChild; }
virtual RenderObject* lastChild() const { return m_lastChild; }
virtual bool canHaveChildren() const;
virtual void addChild(RenderObject* newChild, RenderObject* beforeChild = 0);
virtual void removeChild(RenderObject*);
virtual void destroy();
void destroyLeftoverChildren();
virtual RenderObject* removeChildNode(RenderObject*, bool fullRemove = true);
virtual void appendChildNode(RenderObject*, bool fullAppend = true);
virtual void insertChildNode(RenderObject* child, RenderObject* before, bool fullInsert = true);
virtual void moveChildNode(RenderObject* child) { appendChildNode(child->parent()->removeChildNode(child, false), false); }
virtual void layout();
virtual void calcPrefWidths() { setPrefWidthsDirty(false); }
virtual void removeLeftoverAnonymousBlock(RenderBlock* child);
RenderObject* beforeAfterContainer(RenderStyle::PseudoId);
virtual void updateBeforeAfterContent(RenderStyle::PseudoId);
void updateBeforeAfterContentForContainer(RenderStyle::PseudoId, RenderContainer*);
bool isAfterContent(RenderObject* child) const;
virtual VisiblePosition positionForCoordinates(int x, int y);
virtual void addLineBoxRects(Vector<IntRect>&, unsigned startOffset = 0, unsigned endOffset = UINT_MAX);
private:
RenderObject* m_firstChild;
RenderObject* m_lastChild;
};
}
#endif // RenderContainer_h