OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008, 2011 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008, 2011 Apple Inc. All Rights Reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
297 virtual GraphicsLayer* layerForContainer() const; | 297 virtual GraphicsLayer* layerForContainer() const; |
298 virtual GraphicsLayer* layerForScrolling() const { return 0; } | 298 virtual GraphicsLayer* layerForScrolling() const { return 0; } |
299 virtual GraphicsLayer* layerForHorizontalScrollbar() const { return 0; } | 299 virtual GraphicsLayer* layerForHorizontalScrollbar() const { return 0; } |
300 virtual GraphicsLayer* layerForVerticalScrollbar() const { return 0; } | 300 virtual GraphicsLayer* layerForVerticalScrollbar() const { return 0; } |
301 virtual GraphicsLayer* layerForScrollCorner() const { return 0; } | 301 virtual GraphicsLayer* layerForScrollCorner() const { return 0; } |
302 bool hasLayerForHorizontalScrollbar() const; | 302 bool hasLayerForHorizontalScrollbar() const; |
303 bool hasLayerForVerticalScrollbar() const; | 303 bool hasLayerForVerticalScrollbar() const; |
304 bool hasLayerForScrollCorner() const; | 304 bool hasLayerForScrollCorner() const; |
305 | 305 |
306 void layerForScrollingDidChange(CompositorAnimationTimeline*); | 306 void layerForScrollingDidChange(CompositorAnimationTimeline*); |
| 307 bool needsShowScrollbarLayers() const { return m_needsShowScrollbarLayers; } |
| 308 void didShowScrollbarLayers() { m_needsShowScrollbarLayers = false; } |
307 | 309 |
308 void cancelScrollAnimation(); | 310 void cancelScrollAnimation(); |
309 virtual void cancelProgrammaticScrollAnimation(); | 311 virtual void cancelProgrammaticScrollAnimation(); |
310 | 312 |
311 virtual ~ScrollableArea(); | 313 virtual ~ScrollableArea(); |
312 | 314 |
313 // Called when any of horizontal scrollbar, vertical scrollbar and scroll | 315 // Called when any of horizontal scrollbar, vertical scrollbar and scroll |
314 // corner is setNeedsPaintInvalidation. | 316 // corner is setNeedsPaintInvalidation. |
315 virtual void scrollControlWasSetNeedsPaintInvalidation() = 0; | 317 virtual void scrollControlWasSetNeedsPaintInvalidation() = 0; |
316 | 318 |
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
439 | 441 |
440 unsigned m_scrollOriginChanged : 1; | 442 unsigned m_scrollOriginChanged : 1; |
441 | 443 |
442 unsigned m_horizontalScrollbarNeedsPaintInvalidation : 1; | 444 unsigned m_horizontalScrollbarNeedsPaintInvalidation : 1; |
443 unsigned m_verticalScrollbarNeedsPaintInvalidation : 1; | 445 unsigned m_verticalScrollbarNeedsPaintInvalidation : 1; |
444 unsigned m_scrollCornerNeedsPaintInvalidation : 1; | 446 unsigned m_scrollCornerNeedsPaintInvalidation : 1; |
445 unsigned m_scrollbarsHidden : 1; | 447 unsigned m_scrollbarsHidden : 1; |
446 unsigned m_scrollbarCaptured : 1; | 448 unsigned m_scrollbarCaptured : 1; |
447 unsigned m_mouseOverScrollbar : 1; | 449 unsigned m_mouseOverScrollbar : 1; |
448 | 450 |
| 451 // Indicates that the next compositing update needs to call |
| 452 // WebLayer::showScrollbars on our scroll layer. Ignored if not composited. |
| 453 unsigned m_needsShowScrollbarLayers : 1; |
| 454 |
449 // There are 6 possible combinations of writing mode and direction. Scroll | 455 // There are 6 possible combinations of writing mode and direction. Scroll |
450 // origin will be non-zero in the x or y axis if there is any reversed | 456 // origin will be non-zero in the x or y axis if there is any reversed |
451 // direction or writing-mode. The combinations are: | 457 // direction or writing-mode. The combinations are: |
452 // writing-mode / direction scrollOrigin.x() set scrollOrigin.y() set | 458 // writing-mode / direction scrollOrigin.x() set scrollOrigin.y() set |
453 // horizontal-tb / ltr NO NO | 459 // horizontal-tb / ltr NO NO |
454 // horizontal-tb / rtl YES NO | 460 // horizontal-tb / rtl YES NO |
455 // vertical-lr / ltr NO NO | 461 // vertical-lr / ltr NO NO |
456 // vertical-lr / rtl NO YES | 462 // vertical-lr / rtl NO YES |
457 // vertical-rl / ltr YES NO | 463 // vertical-rl / ltr YES NO |
458 // vertical-rl / rtl YES YES | 464 // vertical-rl / rtl YES YES |
459 IntPoint m_scrollOrigin; | 465 IntPoint m_scrollOrigin; |
460 }; | 466 }; |
461 | 467 |
462 } // namespace blink | 468 } // namespace blink |
463 | 469 |
464 #endif // ScrollableArea_h | 470 #endif // ScrollableArea_h |
OLD | NEW |