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 14 matching lines...) Expand all Loading... |
25 | 25 |
26 #include "config.h" | 26 #include "config.h" |
27 #include "core/rendering/RenderScrollbar.h" | 27 #include "core/rendering/RenderScrollbar.h" |
28 | 28 |
29 #include "core/css/PseudoStyleRequest.h" | 29 #include "core/css/PseudoStyleRequest.h" |
30 #include "core/frame/FrameView.h" | 30 #include "core/frame/FrameView.h" |
31 #include "core/frame/LocalFrame.h" | 31 #include "core/frame/LocalFrame.h" |
32 #include "core/rendering/RenderPart.h" | 32 #include "core/rendering/RenderPart.h" |
33 #include "core/rendering/RenderScrollbarPart.h" | 33 #include "core/rendering/RenderScrollbarPart.h" |
34 #include "core/rendering/RenderScrollbarTheme.h" | 34 #include "core/rendering/RenderScrollbarTheme.h" |
| 35 #include "platform/graphics/GraphicsContext.h" |
35 | 36 |
36 namespace WebCore { | 37 namespace WebCore { |
37 | 38 |
38 PassRefPtr<Scrollbar> RenderScrollbar::createCustomScrollbar(ScrollableArea* scr
ollableArea, ScrollbarOrientation orientation, Node* ownerNode, LocalFrame* owni
ngFrame) | 39 PassRefPtr<Scrollbar> RenderScrollbar::createCustomScrollbar(ScrollableArea* scr
ollableArea, ScrollbarOrientation orientation, Node* ownerNode, LocalFrame* owni
ngFrame) |
39 { | 40 { |
40 return adoptRef(new RenderScrollbar(scrollableArea, orientation, ownerNode,
owningFrame)); | 41 return adoptRef(new RenderScrollbar(scrollableArea, orientation, ownerNode,
owningFrame)); |
41 } | 42 } |
42 | 43 |
43 RenderScrollbar::RenderScrollbar(ScrollableArea* scrollableArea, ScrollbarOrient
ation orientation, Node* ownerNode, LocalFrame* owningFrame) | 44 RenderScrollbar::RenderScrollbar(ScrollableArea* scrollableArea, ScrollbarOrient
ation orientation, Node* ownerNode, LocalFrame* owningFrame) |
44 : Scrollbar(scrollableArea, orientation, RegularScrollbar, RenderScrollbarTh
eme::renderScrollbarTheme()) | 45 : Scrollbar(scrollableArea, orientation, RegularScrollbar, RenderScrollbarTh
eme::renderScrollbarTheme()) |
(...skipping 305 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
350 int RenderScrollbar::minimumThumbLength() | 351 int RenderScrollbar::minimumThumbLength() |
351 { | 352 { |
352 RenderScrollbarPart* partRenderer = m_parts.get(ThumbPart); | 353 RenderScrollbarPart* partRenderer = m_parts.get(ThumbPart); |
353 if (!partRenderer) | 354 if (!partRenderer) |
354 return 0; | 355 return 0; |
355 partRenderer->layout(); | 356 partRenderer->layout(); |
356 return orientation() == HorizontalScrollbar ? partRenderer->width() : partRe
nderer->height(); | 357 return orientation() == HorizontalScrollbar ? partRenderer->width() : partRe
nderer->height(); |
357 } | 358 } |
358 | 359 |
359 } | 360 } |
OLD | NEW |