OLD | NEW |
1 /* | 1 /* |
2 Copyright (C) 1997 Martin Jones (mjones@kde.org) | 2 Copyright (C) 1997 Martin Jones (mjones@kde.org) |
3 (C) 1998 Waldo Bastian (bastian@kde.org) | 3 (C) 1998 Waldo Bastian (bastian@kde.org) |
4 (C) 1998, 1999 Torben Weis (weis@kde.org) | 4 (C) 1998, 1999 Torben Weis (weis@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) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv
ed. | 7 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv
ed. |
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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 class RenderBox; | 48 class RenderBox; |
49 class RenderEmbeddedObject; | 49 class RenderEmbeddedObject; |
50 class RenderObject; | 50 class RenderObject; |
51 class RenderScrollbarPart; | 51 class RenderScrollbarPart; |
52 class RenderStyle; | 52 class RenderStyle; |
53 | 53 |
54 Pagination::Mode paginationModeForRenderStyle(RenderStyle*); | 54 Pagination::Mode paginationModeForRenderStyle(RenderStyle*); |
55 | 55 |
56 typedef unsigned long long DOMTimeStamp; | 56 typedef unsigned long long DOMTimeStamp; |
57 | 57 |
58 class FrameView : public ScrollView { | 58 class FrameView FINAL : public ScrollView { |
59 public: | 59 public: |
60 friend class RenderView; | 60 friend class RenderView; |
61 friend class Internals; | 61 friend class Internals; |
62 | 62 |
63 static PassRefPtr<FrameView> create(Frame*); | 63 static PassRefPtr<FrameView> create(Frame*); |
64 static PassRefPtr<FrameView> create(Frame*, const IntSize& initialSize); | 64 static PassRefPtr<FrameView> create(Frame*, const IntSize& initialSize); |
65 | 65 |
66 virtual ~FrameView(); | 66 virtual ~FrameView(); |
67 | 67 |
68 virtual HostWindow* hostWindow() const; | 68 virtual HostWindow* hostWindow() const OVERRIDE; |
69 | 69 |
70 virtual void invalidateRect(const IntRect&); | 70 virtual void invalidateRect(const IntRect&) OVERRIDE; |
71 virtual void setFrameRect(const IntRect&); | 71 virtual void setFrameRect(const IntRect&) OVERRIDE; |
72 | 72 |
73 virtual bool scheduleAnimation(); | 73 virtual bool scheduleAnimation() OVERRIDE; |
74 | 74 |
75 Frame& frame() const { return *m_frame; } | 75 Frame& frame() const { return *m_frame; } |
76 | 76 |
77 RenderView* renderView() const; | 77 RenderView* renderView() const; |
78 | 78 |
79 LayoutUnit marginWidth() const { return m_margins.width(); } // -1 means def
ault | 79 LayoutUnit marginWidth() const { return m_margins.width(); } // -1 means def
ault |
80 LayoutUnit marginHeight() const { return m_margins.height(); } // -1 means d
efault | 80 LayoutUnit marginHeight() const { return m_margins.height(); } // -1 means d
efault |
81 void setMarginWidth(LayoutUnit); | 81 void setMarginWidth(LayoutUnit); |
82 void setMarginHeight(LayoutUnit); | 82 void setMarginHeight(LayoutUnit); |
83 | 83 |
84 virtual void setCanHaveScrollbars(bool); | 84 virtual void setCanHaveScrollbars(bool) OVERRIDE; |
85 void updateCanHaveScrollbars(); | 85 void updateCanHaveScrollbars(); |
86 | 86 |
87 virtual PassRefPtr<Scrollbar> createScrollbar(ScrollbarOrientation); | 87 virtual PassRefPtr<Scrollbar> createScrollbar(ScrollbarOrientation) OVERRIDE
; |
88 | 88 |
89 virtual void setContentsSize(const IntSize&); | 89 virtual void setContentsSize(const IntSize&) OVERRIDE; |
90 | 90 |
91 void layout(bool allowSubtree = true); | 91 void layout(bool allowSubtree = true); |
92 bool didFirstLayout() const; | 92 bool didFirstLayout() const; |
93 void layoutTimerFired(Timer<FrameView>*); | 93 void layoutTimerFired(Timer<FrameView>*); |
94 void scheduleRelayout(); | 94 void scheduleRelayout(); |
95 void scheduleRelayoutOfSubtree(RenderObject*); | 95 void scheduleRelayoutOfSubtree(RenderObject*); |
96 void unscheduleRelayout(); | 96 void unscheduleRelayout(); |
97 bool layoutPending() const; | 97 bool layoutPending() const; |
98 bool isInLayout() const { return m_inLayout; } | 98 bool isInLayout() const { return m_inLayout; } |
99 | 99 |
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
144 Color baseBackgroundColor() const; | 144 Color baseBackgroundColor() const; |
145 void setBaseBackgroundColor(const Color&); | 145 void setBaseBackgroundColor(const Color&); |
146 void updateBackgroundRecursively(const Color&, bool); | 146 void updateBackgroundRecursively(const Color&, bool); |
147 | 147 |
148 bool shouldUpdateWhileOffscreen() const; | 148 bool shouldUpdateWhileOffscreen() const; |
149 void setShouldUpdateWhileOffscreen(bool); | 149 void setShouldUpdateWhileOffscreen(bool); |
150 bool shouldUpdate() const; | 150 bool shouldUpdate() const; |
151 | 151 |
152 void adjustViewSize(); | 152 void adjustViewSize(); |
153 | 153 |
154 virtual IntRect windowClipRect(bool clipToContents = true) const; | 154 virtual IntRect windowClipRect(bool clipToContents = true) const OVERRIDE; |
155 IntRect windowClipRectForFrameOwner(const HTMLFrameOwnerElement*, bool clipT
oLayerContents) const; | 155 IntRect windowClipRectForFrameOwner(const HTMLFrameOwnerElement*, bool clipT
oLayerContents) const; |
156 | 156 |
157 virtual IntRect windowResizerRect() const; | 157 virtual IntRect windowResizerRect() const OVERRIDE; |
158 | 158 |
159 virtual float visibleContentScaleFactor() const OVERRIDE { return m_visibleC
ontentScaleFactor; } | 159 virtual float visibleContentScaleFactor() const OVERRIDE { return m_visibleC
ontentScaleFactor; } |
160 void setVisibleContentScaleFactor(float); | 160 void setVisibleContentScaleFactor(float); |
161 | 161 |
162 virtual float inputEventsScaleFactor() const OVERRIDE; | 162 virtual float inputEventsScaleFactor() const OVERRIDE; |
163 virtual IntSize inputEventsOffsetForEmulation() const OVERRIDE; | 163 virtual IntSize inputEventsOffsetForEmulation() const OVERRIDE; |
164 void setInputEventsTransformForEmulation(const IntSize&, float); | 164 void setInputEventsTransformForEmulation(const IntSize&, float); |
165 | 165 |
166 virtual void setScrollPosition(const IntPoint&) OVERRIDE; | 166 virtual void setScrollPosition(const IntPoint&) OVERRIDE; |
167 virtual void repaintFixedElementsAfterScrolling(); | 167 virtual void repaintFixedElementsAfterScrolling() OVERRIDE; |
168 virtual void updateFixedElementsAfterScrolling(); | 168 virtual void updateFixedElementsAfterScrolling() OVERRIDE; |
169 virtual bool shouldRubberBandInDirection(ScrollDirection) const; | 169 virtual bool shouldRubberBandInDirection(ScrollDirection) const OVERRIDE; |
170 virtual bool isRubberBandInProgress() const OVERRIDE; | 170 virtual bool isRubberBandInProgress() const OVERRIDE; |
171 void setScrollPositionNonProgrammatically(const IntPoint&); | 171 void setScrollPositionNonProgrammatically(const IntPoint&); |
172 | 172 |
173 // This is different than visibleContentRect() in that it ignores negative (
or overly positive) | 173 // This is different than visibleContentRect() in that it ignores negative (
or overly positive) |
174 // offsets from rubber-banding, and it takes zooming into account. | 174 // offsets from rubber-banding, and it takes zooming into account. |
175 LayoutRect viewportConstrainedVisibleContentRect() const; | 175 LayoutRect viewportConstrainedVisibleContentRect() const; |
176 | 176 |
177 AtomicString mediaType() const; | 177 AtomicString mediaType() const; |
178 void setMediaType(const AtomicString&); | 178 void setMediaType(const AtomicString&); |
179 void adjustMediaTypeForPrinting(bool printing); | 179 void adjustMediaTypeForPrinting(bool printing); |
(...skipping 26 matching lines...) Expand all Loading... |
206 void postLayoutTimerFired(Timer<FrameView>*); | 206 void postLayoutTimerFired(Timer<FrameView>*); |
207 | 207 |
208 bool wasScrolledByUser() const; | 208 bool wasScrolledByUser() const; |
209 void setWasScrolledByUser(bool); | 209 void setWasScrolledByUser(bool); |
210 | 210 |
211 bool safeToPropagateScrollToParent() const { return m_safeToPropagateScrollT
oParent; } | 211 bool safeToPropagateScrollToParent() const { return m_safeToPropagateScrollT
oParent; } |
212 void setSafeToPropagateScrollToParent(bool isSafe) { m_safeToPropagateScroll
ToParent = isSafe; } | 212 void setSafeToPropagateScrollToParent(bool isSafe) { m_safeToPropagateScroll
ToParent = isSafe; } |
213 | 213 |
214 void addWidgetToUpdate(RenderEmbeddedObject&); | 214 void addWidgetToUpdate(RenderEmbeddedObject&); |
215 | 215 |
216 virtual void paintContents(GraphicsContext*, const IntRect& damageRect); | 216 virtual void paintContents(GraphicsContext*, const IntRect& damageRect) OVER
RIDE; |
217 void setPaintBehavior(PaintBehavior); | 217 void setPaintBehavior(PaintBehavior); |
218 PaintBehavior paintBehavior() const; | 218 PaintBehavior paintBehavior() const; |
219 bool isPainting() const; | 219 bool isPainting() const; |
220 bool hasEverPainted() const { return m_lastPaintTime; } | 220 bool hasEverPainted() const { return m_lastPaintTime; } |
221 void setLastPaintTime(double lastPaintTime) { m_lastPaintTime = lastPaintTim
e; } | 221 void setLastPaintTime(double lastPaintTime) { m_lastPaintTime = lastPaintTim
e; } |
222 void setNodeToDraw(Node*); | 222 void setNodeToDraw(Node*); |
223 | 223 |
224 virtual void paintOverhangAreas(GraphicsContext*, const IntRect& horizontalO
verhangArea, const IntRect& verticalOverhangArea, const IntRect& dirtyRect); | 224 virtual void paintOverhangAreas(GraphicsContext*, const IntRect& horizontalO
verhangArea, const IntRect& verticalOverhangArea, const IntRect& dirtyRect) OVER
RIDE; |
225 virtual void paintScrollCorner(GraphicsContext*, const IntRect& cornerRect); | 225 virtual void paintScrollCorner(GraphicsContext*, const IntRect& cornerRect)
OVERRIDE; |
226 virtual void paintScrollbar(GraphicsContext*, Scrollbar*, const IntRect&) OV
ERRIDE; | 226 virtual void paintScrollbar(GraphicsContext*, Scrollbar*, const IntRect&) OV
ERRIDE; |
227 | 227 |
228 Color documentBackgroundColor() const; | 228 Color documentBackgroundColor() const; |
229 | 229 |
230 static double currentFrameTimeStamp() { return s_currentFrameTimeStamp; } | 230 static double currentFrameTimeStamp() { return s_currentFrameTimeStamp; } |
231 | 231 |
232 void updateLayoutAndStyleIfNeededRecursive(); | 232 void updateLayoutAndStyleIfNeededRecursive(); |
233 | 233 |
234 void incrementVisuallyNonEmptyCharacterCount(unsigned); | 234 void incrementVisuallyNonEmptyCharacterCount(unsigned); |
235 void incrementVisuallyNonEmptyPixelCount(const IntSize&); | 235 void incrementVisuallyNonEmptyPixelCount(const IntSize&); |
236 void setIsVisuallyNonEmpty() { m_isVisuallyNonEmpty = true; } | 236 void setIsVisuallyNonEmpty() { m_isVisuallyNonEmpty = true; } |
237 bool isVisuallyNonEmpty() const { return m_isVisuallyNonEmpty; } | 237 bool isVisuallyNonEmpty() const { return m_isVisuallyNonEmpty; } |
238 void enableAutoSizeMode(bool enable, const IntSize& minSize, const IntSize&
maxSize); | 238 void enableAutoSizeMode(bool enable, const IntSize& minSize, const IntSize&
maxSize); |
239 | 239 |
240 void forceLayout(bool allowSubtree = false); | 240 void forceLayout(bool allowSubtree = false); |
241 void forceLayoutForPagination(const FloatSize& pageSize, const FloatSize& or
iginalPageSize, float maximumShrinkFactor, AdjustViewSizeOrNot); | 241 void forceLayoutForPagination(const FloatSize& pageSize, const FloatSize& or
iginalPageSize, float maximumShrinkFactor, AdjustViewSizeOrNot); |
242 | 242 |
243 bool scrollToFragment(const KURL&); | 243 bool scrollToFragment(const KURL&); |
244 bool scrollToAnchor(const String&); | 244 bool scrollToAnchor(const String&); |
245 void maintainScrollPositionAtAnchor(Node*); | 245 void maintainScrollPositionAtAnchor(Node*); |
246 void scrollElementToRect(Element*, const IntRect&); | 246 void scrollElementToRect(Element*, const IntRect&); |
247 | 247 |
248 // Methods to convert points and rects between the coordinate space of the r
enderer, and this view. | 248 // Methods to convert points and rects between the coordinate space of the r
enderer, and this view. |
249 virtual IntRect convertFromRenderer(const RenderObject*, const IntRect&) con
st; | 249 IntRect convertFromRenderer(const RenderObject*, const IntRect&) const; |
250 virtual IntRect convertToRenderer(const RenderObject*, const IntRect&) const
; | 250 IntRect convertToRenderer(const RenderObject*, const IntRect&) const; |
251 virtual IntPoint convertFromRenderer(const RenderObject*, const IntPoint&) c
onst; | 251 IntPoint convertFromRenderer(const RenderObject*, const IntPoint&) const; |
252 virtual IntPoint convertToRenderer(const RenderObject*, const IntPoint&) con
st; | 252 IntPoint convertToRenderer(const RenderObject*, const IntPoint&) const; |
253 | 253 |
254 bool isFrameViewScrollCorner(RenderScrollbarPart* scrollCorner) const { retu
rn m_scrollCorner == scrollCorner; } | 254 bool isFrameViewScrollCorner(RenderScrollbarPart* scrollCorner) const { retu
rn m_scrollCorner == scrollCorner; } |
255 | 255 |
256 bool isScrollable(); | 256 bool isScrollable(); |
257 | 257 |
258 enum ScrollbarModesCalculationStrategy { RulesFromWebContentOnly, AnyRule }; | 258 enum ScrollbarModesCalculationStrategy { RulesFromWebContentOnly, AnyRule }; |
259 void calculateScrollbarModesForLayout(ScrollbarMode& hMode, ScrollbarMode& v
Mode, ScrollbarModesCalculationStrategy = AnyRule); | 259 void calculateScrollbarModesForLayout(ScrollbarMode& hMode, ScrollbarMode& v
Mode, ScrollbarModesCalculationStrategy = AnyRule); |
260 | 260 |
261 // Normal delay | 261 // Normal delay |
262 static void setRepaintThrottlingDeferredRepaintDelay(double); | 262 static void setRepaintThrottlingDeferredRepaintDelay(double); |
263 // Negative value would mean that first few repaints happen without a delay | 263 // Negative value would mean that first few repaints happen without a delay |
264 static void setRepaintThrottlingnInitialDeferredRepaintDelayDuringLoading(do
uble); | 264 static void setRepaintThrottlingnInitialDeferredRepaintDelayDuringLoading(do
uble); |
265 // The delay grows on each repaint to this maximum value | 265 // The delay grows on each repaint to this maximum value |
266 static void setRepaintThrottlingMaxDeferredRepaintDelayDuringLoading(double)
; | 266 static void setRepaintThrottlingMaxDeferredRepaintDelayDuringLoading(double)
; |
267 // On each repaint the delay increses by this amount | 267 // On each repaint the delay increses by this amount |
268 static void setRepaintThrottlingDeferredRepaintDelayIncrementDuringLoading(d
ouble); | 268 static void setRepaintThrottlingDeferredRepaintDelayIncrementDuringLoading(d
ouble); |
269 | 269 |
270 virtual IntPoint lastKnownMousePosition() const; | 270 virtual IntPoint lastKnownMousePosition() const OVERRIDE; |
271 bool shouldSetCursor() const; | 271 bool shouldSetCursor() const; |
272 | 272 |
273 void setCursor(const Cursor&); | 273 void setCursor(const Cursor&); |
274 | 274 |
275 virtual bool scrollbarsCanBeActive() const OVERRIDE; | 275 virtual bool scrollbarsCanBeActive() const OVERRIDE; |
276 | 276 |
277 // FIXME: Remove this method once plugin loading is decoupled from layout. | 277 // FIXME: Remove this method once plugin loading is decoupled from layout. |
278 void flushAnyPendingPostLayoutTasks(); | 278 void flushAnyPendingPostLayoutTasks(); |
279 | 279 |
280 virtual bool shouldSuspendScrollAnimations() const; | 280 virtual bool shouldSuspendScrollAnimations() const OVERRIDE; |
281 virtual void scrollbarStyleChanged(int newStyle, bool forceUpdate); | 281 virtual void scrollbarStyleChanged(int newStyle, bool forceUpdate) OVERRIDE; |
282 | 282 |
283 void setAnimatorsAreActive(); | 283 void setAnimatorsAreActive(); |
284 | 284 |
285 RenderBox* embeddedContentBox() const; | 285 RenderBox* embeddedContentBox() const; |
286 | 286 |
287 void setTracksRepaints(bool); | 287 void setTracksRepaints(bool); |
288 bool isTrackingRepaints() const { return m_isTrackingRepaints; } | 288 bool isTrackingRepaints() const { return m_isTrackingRepaints; } |
289 void resetTrackedRepaints(); | 289 void resetTrackedRepaints(); |
290 const Vector<IntRect>& trackedRepaintRects() const { return m_trackedRepaint
Rects; } | 290 const Vector<IntRect>& trackedRepaintRects() const { return m_trackedRepaint
Rects; } |
291 String trackedRepaintRectsAsText() const; | 291 String trackedRepaintRectsAsText() const; |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
341 | 341 |
342 class DeferredRepaintScope { | 342 class DeferredRepaintScope { |
343 public: | 343 public: |
344 DeferredRepaintScope(FrameView&); | 344 DeferredRepaintScope(FrameView&); |
345 ~DeferredRepaintScope(); | 345 ~DeferredRepaintScope(); |
346 private: | 346 private: |
347 RefPtr<FrameView> m_view; | 347 RefPtr<FrameView> m_view; |
348 }; | 348 }; |
349 | 349 |
350 protected: | 350 protected: |
351 virtual bool scrollContentsFastPath(const IntSize& scrollDelta, const IntRec
t& rectToScroll, const IntRect& clipRect); | 351 virtual bool scrollContentsFastPath(const IntSize& scrollDelta, const IntRec
t& rectToScroll, const IntRect& clipRect) OVERRIDE; |
352 virtual void scrollContentsSlowPath(const IntRect& updateRect); | 352 virtual void scrollContentsSlowPath(const IntRect& updateRect) OVERRIDE; |
353 | 353 |
354 virtual bool isVerticalDocument() const; | 354 virtual bool isVerticalDocument() const OVERRIDE; |
355 virtual bool isFlippedDocument() const; | 355 virtual bool isFlippedDocument() const OVERRIDE; |
356 | 356 |
357 private: | 357 private: |
358 explicit FrameView(Frame*); | 358 explicit FrameView(Frame*); |
359 | 359 |
360 void beginDeferredRepaints(); | 360 void beginDeferredRepaints(); |
361 void endDeferredRepaints(); | 361 void endDeferredRepaints(); |
362 void flushDeferredRepaints(); | 362 void flushDeferredRepaints(); |
363 void startDeferredRepaintTimer(double delay); | 363 void startDeferredRepaintTimer(double delay); |
364 | 364 |
365 void reset(); | 365 void reset(); |
366 void init(); | 366 void init(); |
367 | 367 |
368 virtual void frameRectsChanged(); | 368 virtual void frameRectsChanged() OVERRIDE; |
369 virtual bool isFrameView() const OVERRIDE { return true; } | 369 virtual bool isFrameView() const OVERRIDE { return true; } |
370 | 370 |
371 friend class RenderWidget; | 371 friend class RenderWidget; |
372 bool useSlowRepaints(bool considerOverlap = true) const; | 372 bool useSlowRepaints(bool considerOverlap = true) const; |
373 bool useSlowRepaintsIfNotOverlapped() const; | 373 bool useSlowRepaintsIfNotOverlapped() const; |
374 void updateCanBlitOnScrollRecursively(); | 374 void updateCanBlitOnScrollRecursively(); |
375 bool contentsInCompositedLayer() const; | 375 bool contentsInCompositedLayer() const; |
376 | 376 |
377 void applyOverflowToViewport(RenderObject*, ScrollbarMode& hMode, ScrollbarM
ode& vMode); | 377 void applyOverflowToViewport(RenderObject*, ScrollbarMode& hMode, ScrollbarM
ode& vMode); |
378 void applyPaginationToViewport(); | 378 void applyPaginationToViewport(); |
379 | 379 |
380 void updateOverflowStatus(bool horizontalOverflow, bool verticalOverflow); | 380 void updateOverflowStatus(bool horizontalOverflow, bool verticalOverflow); |
381 | 381 |
382 void paintControlTints(); | 382 void paintControlTints(); |
383 | 383 |
384 void updateCounters(); | 384 void updateCounters(); |
385 void autoSizeIfEnabled(); | 385 void autoSizeIfEnabled(); |
386 void forceLayoutParentViewIfNeeded(); | 386 void forceLayoutParentViewIfNeeded(); |
387 void performPreLayoutTasks(); | 387 void performPreLayoutTasks(); |
388 void performLayout(RenderObject* rootForThisLayout, bool inSubtreeLayout); | 388 void performLayout(RenderObject* rootForThisLayout, bool inSubtreeLayout); |
389 void scheduleOrPerformPostLayoutTasks(); | 389 void scheduleOrPerformPostLayoutTasks(); |
390 void performPostLayoutTasks(); | 390 void performPostLayoutTasks(); |
391 | 391 |
392 void repaintTree(RenderObject* root); | 392 void repaintTree(RenderObject* root); |
393 | 393 |
394 virtual void gatherDebugLayoutRects(RenderObject* layoutRoot); | 394 void gatherDebugLayoutRects(RenderObject* layoutRoot); |
395 | 395 |
396 virtual void repaintContentRectangle(const IntRect&); | 396 virtual void repaintContentRectangle(const IntRect&) OVERRIDE; |
397 virtual void contentsResized() OVERRIDE; | 397 virtual void contentsResized() OVERRIDE; |
398 virtual void scrollbarExistenceDidChange(); | 398 virtual void scrollbarExistenceDidChange() OVERRIDE; |
399 | 399 |
400 // Override ScrollView methods to do point conversion via renderers, in orde
r to | 400 // Override ScrollView methods to do point conversion via renderers, in orde
r to |
401 // take transforms into account. | 401 // take transforms into account. |
402 virtual IntRect convertToContainingView(const IntRect&) const OVERRIDE; | 402 virtual IntRect convertToContainingView(const IntRect&) const OVERRIDE; |
403 virtual IntRect convertFromContainingView(const IntRect&) const OVERRIDE; | 403 virtual IntRect convertFromContainingView(const IntRect&) const OVERRIDE; |
404 virtual IntPoint convertToContainingView(const IntPoint&) const OVERRIDE; | 404 virtual IntPoint convertToContainingView(const IntPoint&) const OVERRIDE; |
405 virtual IntPoint convertFromContainingView(const IntPoint&) const OVERRIDE; | 405 virtual IntPoint convertFromContainingView(const IntPoint&) const OVERRIDE; |
406 | 406 |
407 // ScrollableArea interface | 407 // ScrollableArea interface |
408 virtual void invalidateScrollbarRect(Scrollbar*, const IntRect&) OVERRIDE; | 408 virtual void invalidateScrollbarRect(Scrollbar*, const IntRect&) OVERRIDE; |
409 virtual void getTickmarks(Vector<IntRect>&) const OVERRIDE; | 409 virtual void getTickmarks(Vector<IntRect>&) const OVERRIDE; |
410 virtual void scrollTo(const IntSize&) OVERRIDE; | 410 virtual void scrollTo(const IntSize&) OVERRIDE; |
411 virtual ScrollableArea* enclosingScrollableArea() const OVERRIDE; | 411 virtual ScrollableArea* enclosingScrollableArea() const OVERRIDE; |
412 virtual IntRect scrollableAreaBoundingBox() const OVERRIDE; | 412 virtual IntRect scrollableAreaBoundingBox() const OVERRIDE; |
413 virtual bool scrollAnimatorEnabled() const OVERRIDE; | 413 virtual bool scrollAnimatorEnabled() const OVERRIDE; |
414 virtual bool usesCompositedScrolling() const OVERRIDE; | 414 virtual bool usesCompositedScrolling() const OVERRIDE; |
415 virtual GraphicsLayer* layerForScrolling() const OVERRIDE; | 415 virtual GraphicsLayer* layerForScrolling() const OVERRIDE; |
416 virtual GraphicsLayer* layerForHorizontalScrollbar() const OVERRIDE; | 416 virtual GraphicsLayer* layerForHorizontalScrollbar() const OVERRIDE; |
417 virtual GraphicsLayer* layerForVerticalScrollbar() const OVERRIDE; | 417 virtual GraphicsLayer* layerForVerticalScrollbar() const OVERRIDE; |
418 virtual GraphicsLayer* layerForScrollCorner() const OVERRIDE; | 418 virtual GraphicsLayer* layerForScrollCorner() const OVERRIDE; |
419 | 419 |
420 void sendResizeEventIfNeeded(); | 420 void sendResizeEventIfNeeded(); |
421 | 421 |
422 void updateScrollableAreaSet(); | 422 void updateScrollableAreaSet(); |
423 | 423 |
424 virtual void notifyPageThatContentAreaWillPaint() const; | 424 virtual void notifyPageThatContentAreaWillPaint() const OVERRIDE; |
425 | 425 |
426 bool shouldUseLoadTimeDeferredRepaintDelay() const; | 426 bool shouldUseLoadTimeDeferredRepaintDelay() const; |
427 void deferredRepaintTimerFired(Timer<FrameView>*); | 427 void deferredRepaintTimerFired(Timer<FrameView>*); |
428 void doDeferredRepaints(); | 428 void doDeferredRepaints(); |
429 void updateDeferredRepaintDelayAfterRepaint(); | 429 void updateDeferredRepaintDelayAfterRepaint(); |
430 double adjustedDeferredRepaintDelay() const; | 430 double adjustedDeferredRepaintDelay() const; |
431 | 431 |
432 void updateWidgetsTimerFired(Timer<FrameView>*); | 432 void updateWidgetsTimerFired(Timer<FrameView>*); |
433 bool updateWidgets(); | 433 bool updateWidgets(); |
434 | 434 |
435 void scrollToAnchor(); | 435 void scrollToAnchor(); |
436 void scrollPositionChanged(); | 436 void scrollPositionChanged(); |
437 | 437 |
438 bool hasCustomScrollbars() const; | 438 bool hasCustomScrollbars() const; |
439 bool shouldUseCustomScrollbars(Element*& customScrollbarElement, Frame*& cus
tomScrollbarFrame); | 439 bool shouldUseCustomScrollbars(Element*& customScrollbarElement, Frame*& cus
tomScrollbarFrame); |
440 | 440 |
441 virtual void updateScrollCorner(); | 441 virtual void updateScrollCorner() OVERRIDE; |
442 | 442 |
443 FrameView* parentFrameView() const; | 443 FrameView* parentFrameView() const; |
444 | 444 |
445 virtual AXObjectCache* axObjectCache() const; | 445 AXObjectCache* axObjectCache() const; |
446 void removeFromAXObjectCache(); | 446 void removeFromAXObjectCache(); |
447 | 447 |
448 bool isMainFrame() const; | 448 bool isMainFrame() const; |
449 | 449 |
450 void setLayoutSizeInternal(const IntSize&); | 450 void setLayoutSizeInternal(const IntSize&); |
451 | 451 |
452 static double s_currentFrameTimeStamp; // used for detecting decoded resourc
e thrash in the cache | 452 static double s_currentFrameTimeStamp; // used for detecting decoded resourc
e thrash in the cache |
453 static bool s_inPaintContents; | 453 static bool s_inPaintContents; |
454 | 454 |
455 LayoutSize m_size; | 455 LayoutSize m_size; |
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
581 static const unsigned visualPixelThreshold = 32 * 32; | 581 static const unsigned visualPixelThreshold = 32 * 32; |
582 if (m_visuallyNonEmptyPixelCount > visualPixelThreshold) | 582 if (m_visuallyNonEmptyPixelCount > visualPixelThreshold) |
583 setIsVisuallyNonEmpty(); | 583 setIsVisuallyNonEmpty(); |
584 } | 584 } |
585 | 585 |
586 DEFINE_TYPE_CASTS(FrameView, Widget, widget, widget->isFrameView(), widget.isFra
meView()); | 586 DEFINE_TYPE_CASTS(FrameView, Widget, widget, widget->isFrameView(), widget.isFra
meView()); |
587 | 587 |
588 } // namespace WebCore | 588 } // namespace WebCore |
589 | 589 |
590 #endif // FrameView_h | 590 #endif // FrameView_h |
OLD | NEW |