OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * Copyright (C) 2004, 2005, 2006, 2007, 2009 Apple Inc. All rights reserved. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2009 Apple Inc. All rights reserved. |
4 * | 4 * |
5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
9 * | 9 * |
10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
(...skipping 29 matching lines...) Expand all Loading... |
40 LayoutRect replacedContentRect(const LayoutSize* overriddenIntrinsicSize = 0
) const; | 40 LayoutRect replacedContentRect(const LayoutSize* overriddenIntrinsicSize = 0
) const; |
41 | 41 |
42 virtual bool needsPreferredWidthsRecalculation() const OVERRIDE; | 42 virtual bool needsPreferredWidthsRecalculation() const OVERRIDE; |
43 | 43 |
44 protected: | 44 protected: |
45 virtual void willBeDestroyed() OVERRIDE; | 45 virtual void willBeDestroyed() OVERRIDE; |
46 | 46 |
47 virtual void layout() OVERRIDE; | 47 virtual void layout() OVERRIDE; |
48 | 48 |
49 virtual LayoutSize intrinsicSize() const OVERRIDE FINAL { return m_intrinsic
Size; } | 49 virtual LayoutSize intrinsicSize() const OVERRIDE FINAL { return m_intrinsic
Size; } |
50 virtual void computeIntrinsicRatioInformation(FloatSize& intrinsicSize, doub
le& intrinsicRatio, bool& isPercentageIntrinsicSize) const OVERRIDE; | 50 virtual void computeIntrinsicRatioInformation(FloatSize& intrinsicSize, doub
le& intrinsicRatio) const OVERRIDE; |
51 | 51 |
52 virtual void computeIntrinsicLogicalWidths(LayoutUnit& minLogicalWidth, Layo
utUnit& maxLogicalWidth) const OVERRIDE FINAL; | 52 virtual void computeIntrinsicLogicalWidths(LayoutUnit& minLogicalWidth, Layo
utUnit& maxLogicalWidth) const OVERRIDE FINAL; |
53 | 53 |
54 virtual LayoutUnit intrinsicContentLogicalHeight() const { return intrinsicL
ogicalHeight(); } | 54 virtual LayoutUnit intrinsicContentLogicalHeight() const { return intrinsicL
ogicalHeight(); } |
55 | 55 |
56 virtual LayoutUnit minimumReplacedHeight() const { return LayoutUnit(); } | 56 virtual LayoutUnit minimumReplacedHeight() const { return LayoutUnit(); } |
57 | 57 |
58 virtual void setSelectionState(SelectionState) OVERRIDE FINAL; | 58 virtual void setSelectionState(SelectionState) OVERRIDE FINAL; |
59 | 59 |
60 bool isSelected() const; | 60 bool isSelected() const; |
61 | 61 |
62 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) OV
ERRIDE; | 62 virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) OV
ERRIDE; |
63 | 63 |
64 void setIntrinsicSize(const LayoutSize& intrinsicSize) { m_intrinsicSize = i
ntrinsicSize; } | 64 void setIntrinsicSize(const LayoutSize& intrinsicSize) { m_intrinsicSize = i
ntrinsicSize; } |
65 virtual void intrinsicSizeChanged(); | 65 virtual void intrinsicSizeChanged(); |
66 virtual bool hasRelativeIntrinsicLogicalWidth() const { return false; } | |
67 | 66 |
68 virtual void paint(PaintInfo&, const LayoutPoint&) OVERRIDE; | 67 virtual void paint(PaintInfo&, const LayoutPoint&) OVERRIDE; |
69 bool shouldPaint(PaintInfo&, const LayoutPoint&); | 68 bool shouldPaint(PaintInfo&, const LayoutPoint&); |
70 LayoutRect localSelectionRect(bool checkWhetherSelected = true) const; // Th
is is in local coordinates, but it's a physical rect (so the top left corner is
physical top left). | 69 LayoutRect localSelectionRect(bool checkWhetherSelected = true) const; // Th
is is in local coordinates, but it's a physical rect (so the top left corner is
physical top left). |
71 | 70 |
72 private: | 71 private: |
73 virtual RenderBox* embeddedContentBox() const { return 0; } | 72 virtual RenderBox* embeddedContentBox() const { return 0; } |
74 virtual const char* renderName() const OVERRIDE { return "RenderReplaced"; } | 73 virtual const char* renderName() const OVERRIDE { return "RenderReplaced"; } |
75 | 74 |
76 virtual bool canHaveChildren() const OVERRIDE { return false; } | 75 virtual bool canHaveChildren() const OVERRIDE { return false; } |
77 | 76 |
78 virtual void computePreferredLogicalWidths() OVERRIDE FINAL; | 77 virtual void computePreferredLogicalWidths() OVERRIDE FINAL; |
79 virtual void paintReplaced(PaintInfo&, const LayoutPoint&) { } | 78 virtual void paintReplaced(PaintInfo&, const LayoutPoint&) { } |
80 | 79 |
81 virtual LayoutRect clippedOverflowRectForRepaint(const RenderLayerModelObjec
t* repaintContainer) const OVERRIDE; | 80 virtual LayoutRect clippedOverflowRectForRepaint(const RenderLayerModelObjec
t* repaintContainer) const OVERRIDE; |
82 | 81 |
83 virtual PositionWithAffinity positionForPoint(const LayoutPoint&) OVERRIDE F
INAL; | 82 virtual PositionWithAffinity positionForPoint(const LayoutPoint&) OVERRIDE F
INAL; |
84 | 83 |
85 virtual bool canBeSelectionLeaf() const OVERRIDE { return true; } | 84 virtual bool canBeSelectionLeaf() const OVERRIDE { return true; } |
86 | 85 |
87 virtual LayoutRect selectionRectForRepaint(const RenderLayerModelObject* rep
aintContainer, bool clipToVisibleContent = true) OVERRIDE FINAL; | 86 virtual LayoutRect selectionRectForRepaint(const RenderLayerModelObject* rep
aintContainer, bool clipToVisibleContent = true) OVERRIDE FINAL; |
88 void computeAspectRatioInformationForRenderBox(RenderBox*, FloatSize& constr
ainedSize, double& intrinsicRatio, bool& isPercentageIntrinsicSize) const; | 87 void computeAspectRatioInformationForRenderBox(RenderBox*, FloatSize& constr
ainedSize, double& intrinsicRatio) const; |
89 | 88 |
90 mutable LayoutSize m_intrinsicSize; | 89 mutable LayoutSize m_intrinsicSize; |
91 }; | 90 }; |
92 | 91 |
93 } | 92 } |
94 | 93 |
95 #endif | 94 #endif |
OLD | NEW |