OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008, 2009 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008, 2009 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 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 void SetVisualRect(const LayoutRect&) final; | 70 void SetVisualRect(const LayoutRect&) final; |
71 | 71 |
72 DECLARE_VIRTUAL_TRACE(); | 72 DECLARE_VIRTUAL_TRACE(); |
73 | 73 |
74 protected: | 74 protected: |
75 LayoutScrollbar(ScrollableArea*, ScrollbarOrientation, Element*); | 75 LayoutScrollbar(ScrollableArea*, ScrollbarOrientation, Element*); |
76 | 76 |
77 private: | 77 private: |
78 friend class Scrollbar; | 78 friend class Scrollbar; |
79 | 79 |
80 void SetParent(FrameViewBase*) override; | |
81 void SetEnabled(bool) override; | 80 void SetEnabled(bool) override; |
| 81 void DisconnectFromScrollableArea() override; |
82 | 82 |
83 void SetHoveredPart(ScrollbarPart) override; | 83 void SetHoveredPart(ScrollbarPart) override; |
84 void SetPressedPart(ScrollbarPart) override; | 84 void SetPressedPart(ScrollbarPart) override; |
85 | 85 |
86 void StyleChanged() override; | 86 void StyleChanged() override; |
87 | 87 |
88 bool IsCustomScrollbar() const override { return true; } | 88 bool IsCustomScrollbar() const override { return true; } |
89 | 89 |
90 void UpdateScrollbarParts(bool destroy = false); | 90 void UpdateScrollbarParts(bool destroy = false); |
91 | 91 |
92 PassRefPtr<ComputedStyle> GetScrollbarPseudoStyle(ScrollbarPart, PseudoId); | 92 PassRefPtr<ComputedStyle> GetScrollbarPseudoStyle(ScrollbarPart, PseudoId); |
93 void UpdateScrollbarPart(ScrollbarPart, bool destroy = false); | 93 void UpdateScrollbarPart(ScrollbarPart, bool destroy = false); |
94 | 94 |
95 // The element that supplies our style information. | 95 // The element that supplies our style information. |
96 Member<Element> style_source_; | 96 Member<Element> style_source_; |
97 | 97 |
98 HashMap<unsigned, LayoutScrollbarPart*> parts_; | 98 HashMap<unsigned, LayoutScrollbarPart*> parts_; |
99 }; | 99 }; |
100 | 100 |
101 DEFINE_TYPE_CASTS(LayoutScrollbar, | 101 DEFINE_TYPE_CASTS(LayoutScrollbar, |
102 ScrollbarThemeClient, | 102 ScrollbarThemeClient, |
103 scrollbar, | 103 scrollbar, |
104 scrollbar->IsCustomScrollbar(), | 104 scrollbar->IsCustomScrollbar(), |
105 scrollbar.IsCustomScrollbar()); | 105 scrollbar.IsCustomScrollbar()); |
106 | 106 |
107 } // namespace blink | 107 } // namespace blink |
108 | 108 |
109 #endif // LayoutScrollbar_h | 109 #endif // LayoutScrollbar_h |
OLD | NEW |