| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved. | 2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. | 4 * Portions are Copyright (C) 1998 Netscape Communications Corporation. |
| 5 * | 5 * |
| 6 * Other contributors: | 6 * Other contributors: |
| 7 * Robert O'Callahan <roc+@cs.cmu.edu> | 7 * Robert O'Callahan <roc+@cs.cmu.edu> |
| 8 * David Baron <dbaron@fas.harvard.edu> | 8 * David Baron <dbaron@fas.harvard.edu> |
| 9 * Christian Biesinger <cbiesinger@web.de> | 9 * Christian Biesinger <cbiesinger@web.de> |
| 10 * Randall Jesup <rjesup@wgate.com> | 10 * Randall Jesup <rjesup@wgate.com> |
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 120 void paintOverflowControls(GraphicsContext*, const IntPoint& paintOffset, co
nst IntRect& damageRect, bool paintingOverlayControls); | 120 void paintOverflowControls(GraphicsContext*, const IntPoint& paintOffset, co
nst IntRect& damageRect, bool paintingOverlayControls); |
| 121 void positionOverflowControls(const IntSize& offsetFromRoot); | 121 void positionOverflowControls(const IntSize& offsetFromRoot); |
| 122 | 122 |
| 123 LayoutRect exposeRect(const LayoutRect&, const ScrollAlignment& alignX, cons
t ScrollAlignment& alignY); | 123 LayoutRect exposeRect(const LayoutRect&, const ScrollAlignment& alignX, cons
t ScrollAlignment& alignY); |
| 124 | 124 |
| 125 // Returns true our scrollable area is in the FrameView's collection of scro
llable areas. This can | 125 // Returns true our scrollable area is in the FrameView's collection of scro
llable areas. This can |
| 126 // only happen if we're both scrollable, and we do in fact overflow. This me
ans that overflow: hidden | 126 // only happen if we're both scrollable, and we do in fact overflow. This me
ans that overflow: hidden |
| 127 // layers never get added to the FrameView's collection. | 127 // layers never get added to the FrameView's collection. |
| 128 bool scrollsOverflow() const { return m_scrollsOverflow; } | 128 bool scrollsOverflow() const { return m_scrollsOverflow; } |
| 129 | 129 |
| 130 void updateNeedsCompositedScrolling(); | 130 // FIXME(sky): Remove |
| 131 bool needsCompositedScrolling() const { return m_needsCompositedScrolling; } | 131 bool needsCompositedScrolling() const { return m_needsCompositedScrolling; } |
| 132 | 132 |
| 133 // These are used during compositing updates to determine if the overflow | 133 // These are used during compositing updates to determine if the overflow |
| 134 // controls need to be repositioned in the GraphicsLayer tree. | 134 // controls need to be repositioned in the GraphicsLayer tree. |
| 135 void setTopmostScrollChild(RenderLayer*); | 135 void setTopmostScrollChild(RenderLayer*); |
| 136 RenderLayer* topmostScrollChild() const { ASSERT(!m_nextTopmostScrollChild);
return m_topmostScrollChild; } | 136 RenderLayer* topmostScrollChild() const { ASSERT(!m_nextTopmostScrollChild);
return m_topmostScrollChild; } |
| 137 | 137 |
| 138 private: | 138 private: |
| 139 bool hasHorizontalOverflow() const; | 139 bool hasHorizontalOverflow() const; |
| 140 bool hasVerticalOverflow() const; | 140 bool hasVerticalOverflow() const; |
| (...skipping 18 matching lines...) Expand all Loading... |
| 159 void setHasHorizontalScrollbar(bool hasScrollbar); | 159 void setHasHorizontalScrollbar(bool hasScrollbar); |
| 160 void setHasVerticalScrollbar(bool hasScrollbar); | 160 void setHasVerticalScrollbar(bool hasScrollbar); |
| 161 | 161 |
| 162 bool overflowControlsIntersectRect(const IntRect& localRect) const; | 162 bool overflowControlsIntersectRect(const IntRect& localRect) const; |
| 163 | 163 |
| 164 RenderBox& box() const; | 164 RenderBox& box() const; |
| 165 RenderLayer* layer() const; | 165 RenderLayer* layer() const; |
| 166 | 166 |
| 167 void updateScrollableAreaSet(bool hasOverflow); | 167 void updateScrollableAreaSet(bool hasOverflow); |
| 168 | 168 |
| 169 void updateCompositingLayersAfterScroll(); | |
| 170 | |
| 171 RenderLayer& m_layer; | 169 RenderLayer& m_layer; |
| 172 | 170 |
| 173 unsigned m_scrollsOverflow : 1; | 171 unsigned m_scrollsOverflow : 1; |
| 174 | 172 |
| 175 unsigned m_scrollDimensionsDirty : 1; | 173 unsigned m_scrollDimensionsDirty : 1; |
| 176 unsigned m_inOverflowRelayout : 1; | 174 unsigned m_inOverflowRelayout : 1; |
| 177 | 175 |
| 178 RenderLayer* m_nextTopmostScrollChild; | 176 RenderLayer* m_nextTopmostScrollChild; |
| 179 RenderLayer* m_topmostScrollChild; | 177 RenderLayer* m_topmostScrollChild; |
| 180 | 178 |
| (...skipping 10 matching lines...) Expand all Loading... |
| 191 IntPoint m_cachedOverlayScrollbarOffset; | 189 IntPoint m_cachedOverlayScrollbarOffset; |
| 192 | 190 |
| 193 // For areas with overflow, we have a pair of scrollbars. | 191 // For areas with overflow, we have a pair of scrollbars. |
| 194 RefPtr<Scrollbar> m_hBar; | 192 RefPtr<Scrollbar> m_hBar; |
| 195 RefPtr<Scrollbar> m_vBar; | 193 RefPtr<Scrollbar> m_vBar; |
| 196 }; | 194 }; |
| 197 | 195 |
| 198 } // namespace blink | 196 } // namespace blink |
| 199 | 197 |
| 200 #endif // SKY_ENGINE_CORE_RENDERING_RENDERLAYERSCROLLABLEAREA_H_ | 198 #endif // SKY_ENGINE_CORE_RENDERING_RENDERLAYERSCROLLABLEAREA_H_ |
| OLD | NEW |