| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2006, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2004, 2006, 2008 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 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 82 Scrollbar::~Scrollbar() | 82 Scrollbar::~Scrollbar() |
| 83 { | 83 { |
| 84 stopTimerIfNeeded(); | 84 stopTimerIfNeeded(); |
| 85 } | 85 } |
| 86 | 86 |
| 87 ScrollbarOverlayStyle Scrollbar::scrollbarOverlayStyle() const | 87 ScrollbarOverlayStyle Scrollbar::scrollbarOverlayStyle() const |
| 88 { | 88 { |
| 89 return m_scrollableArea ? m_scrollableArea->scrollbarOverlayStyle() : Scroll
barOverlayStyleDefault; | 89 return m_scrollableArea ? m_scrollableArea->scrollbarOverlayStyle() : Scroll
barOverlayStyleDefault; |
| 90 } | 90 } |
| 91 | 91 |
| 92 void Scrollbar::getTickmarks(Vector<IntRect>& tickmarks) const | |
| 93 { | |
| 94 if (m_scrollableArea) | |
| 95 m_scrollableArea->getTickmarks(tickmarks); | |
| 96 } | |
| 97 | |
| 98 bool Scrollbar::isScrollableAreaActive() const | 92 bool Scrollbar::isScrollableAreaActive() const |
| 99 { | 93 { |
| 100 return m_scrollableArea && m_scrollableArea->isActive(); | 94 return m_scrollableArea && m_scrollableArea->isActive(); |
| 101 } | 95 } |
| 102 | 96 |
| 103 bool Scrollbar::isLeftSideVerticalScrollbar() const | 97 bool Scrollbar::isLeftSideVerticalScrollbar() const |
| 104 { | 98 { |
| 105 if (m_orientation == VerticalScrollbar && m_scrollableArea) | 99 if (m_orientation == VerticalScrollbar && m_scrollableArea) |
| 106 return m_scrollableArea->shouldPlaceVerticalScrollbarOnLeft(); | 100 return m_scrollableArea->shouldPlaceVerticalScrollbarOnLeft(); |
| 107 return false; | 101 return false; |
| (...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 630 thumbRect.setWidth(thumbRect.width() - kScrollbarMargin); | 624 thumbRect.setWidth(thumbRect.width() - kScrollbarMargin); |
| 631 if (isLeftSideVerticalScrollbar()) | 625 if (isLeftSideVerticalScrollbar()) |
| 632 thumbRect.setX(thumbRect.x() + kScrollbarMargin); | 626 thumbRect.setX(thumbRect.x() + kScrollbarMargin); |
| 633 } | 627 } |
| 634 | 628 |
| 635 DEFINE_STATIC_LOCAL(Color, color, (128, 128, 128, 128)); | 629 DEFINE_STATIC_LOCAL(Color, color, (128, 128, 128, 128)); |
| 636 context->fillRect(thumbRect, color); | 630 context->fillRect(thumbRect, color); |
| 637 } | 631 } |
| 638 | 632 |
| 639 } // namespace blink | 633 } // namespace blink |
| OLD | NEW |