| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2006 Apple Computer, Inc. All rights reserved. | 2 * Copyright (C) 2004, 2006 Apple Computer, 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 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 137 virtual IntRect convertFromContainingView(const IntRect&) const override; | 137 virtual IntRect convertFromContainingView(const IntRect&) const override; |
| 138 | 138 |
| 139 virtual IntPoint convertToContainingView(const IntPoint&) const override; | 139 virtual IntPoint convertToContainingView(const IntPoint&) const override; |
| 140 virtual IntPoint convertFromContainingView(const IntPoint&) const override; | 140 virtual IntPoint convertFromContainingView(const IntPoint&) const override; |
| 141 | 141 |
| 142 void moveThumb(int pos, bool draggingDocument = false); | 142 void moveThumb(int pos, bool draggingDocument = false); |
| 143 | 143 |
| 144 virtual bool isAlphaLocked() const override { return m_isAlphaLocked; } | 144 virtual bool isAlphaLocked() const override { return m_isAlphaLocked; } |
| 145 virtual void setIsAlphaLocked(bool flag) override { m_isAlphaLocked = flag;
} | 145 virtual void setIsAlphaLocked(bool flag) override { m_isAlphaLocked = flag;
} |
| 146 | 146 |
| 147 virtual float elasticOverscroll() const override { return m_elasticOverscrol
l; } |
| 148 virtual void setElasticOverscroll(float elasticOverscroll) override { m_elas
ticOverscroll = elasticOverscroll; } |
| 149 |
| 147 bool overlapsResizer() const { return m_overlapsResizer; } | 150 bool overlapsResizer() const { return m_overlapsResizer; } |
| 148 void setOverlapsResizer(bool overlapsResizer) { m_overlapsResizer = overlaps
Resizer; } | 151 void setOverlapsResizer(bool overlapsResizer) { m_overlapsResizer = overlaps
Resizer; } |
| 149 | 152 |
| 150 DisplayItemClient displayItemClient() const { return static_cast<DisplayItem
ClientInternalVoid*>((void*)this); } | 153 DisplayItemClient displayItemClient() const { return static_cast<DisplayItem
ClientInternalVoid*>((void*)this); } |
| 151 | 154 |
| 152 protected: | 155 protected: |
| 153 Scrollbar(ScrollableArea*, ScrollbarOrientation, ScrollbarControlSize, Scrol
lbarTheme* = 0); | 156 Scrollbar(ScrollableArea*, ScrollbarOrientation, ScrollbarControlSize, Scrol
lbarTheme* = 0); |
| 154 | 157 |
| 155 void updateThumb(); | 158 void updateThumb(); |
| 156 virtual void updateThumbPosition(); | 159 virtual void updateThumbPosition(); |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 189 | 192 |
| 190 bool m_enabled; | 193 bool m_enabled; |
| 191 | 194 |
| 192 Timer<Scrollbar> m_scrollTimer; | 195 Timer<Scrollbar> m_scrollTimer; |
| 193 bool m_overlapsResizer; | 196 bool m_overlapsResizer; |
| 194 | 197 |
| 195 bool m_suppressInvalidation; | 198 bool m_suppressInvalidation; |
| 196 | 199 |
| 197 bool m_isAlphaLocked; | 200 bool m_isAlphaLocked; |
| 198 | 201 |
| 202 float m_elasticOverscroll; |
| 203 |
| 199 private: | 204 private: |
| 200 virtual bool isScrollbar() const override { return true; } | 205 virtual bool isScrollbar() const override { return true; } |
| 201 | 206 |
| 202 float scrollableAreaCurrentPos() const; | 207 float scrollableAreaCurrentPos() const; |
| 203 }; | 208 }; |
| 204 | 209 |
| 205 DEFINE_TYPE_CASTS(Scrollbar, Widget, widget, widget->isScrollbar(), widget.isScr
ollbar()); | 210 DEFINE_TYPE_CASTS(Scrollbar, Widget, widget, widget->isScrollbar(), widget.isScr
ollbar()); |
| 206 | 211 |
| 207 } // namespace blink | 212 } // namespace blink |
| 208 | 213 |
| 209 #endif // Scrollbar_h | 214 #endif // Scrollbar_h |
| OLD | NEW |