OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2012 Google Inc. All rights reserved. | 2 * Copyright (C) 2012 Google 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 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 BLINK_PLATFORM_EXPORT void paintTickmarks(WebCanvas*, const WebRect&); | 64 BLINK_PLATFORM_EXPORT void paintTickmarks(WebCanvas*, const WebRect&); |
65 BLINK_PLATFORM_EXPORT void paintThumb(WebCanvas*, const WebRect&); | 65 BLINK_PLATFORM_EXPORT void paintThumb(WebCanvas*, const WebRect&); |
66 | 66 |
67 // This opacity is applied on top of the content that is painted for the thu
mb. | 67 // This opacity is applied on top of the content that is painted for the thu
mb. |
68 BLINK_PLATFORM_EXPORT float thumbOpacity() const; | 68 BLINK_PLATFORM_EXPORT float thumbOpacity() const; |
69 | 69 |
70 BLINK_PLATFORM_EXPORT bool trackNeedsRepaint() const; | 70 BLINK_PLATFORM_EXPORT bool trackNeedsRepaint() const; |
71 BLINK_PLATFORM_EXPORT bool thumbNeedsRepaint() const; | 71 BLINK_PLATFORM_EXPORT bool thumbNeedsRepaint() const; |
72 | 72 |
73 #if INSIDE_BLINK | 73 #if INSIDE_BLINK |
74 BLINK_PLATFORM_EXPORT WebScrollbarThemePainter(ScrollbarTheme*, Scrollbar*,
float deviceScaleFactor); | 74 BLINK_PLATFORM_EXPORT WebScrollbarThemePainter(ScrollbarTheme&, Scrollbar&,
float deviceScaleFactor); |
75 #endif | 75 #endif |
76 | 76 |
77 private: | 77 private: |
78 // The theme is not owned by this class. It is assumed that the theme is a | 78 // The theme is not owned by this class. It is assumed that the theme is a |
79 // static pointer and its lifetime is essentially infinite. The functions | 79 // static pointer and its lifetime is essentially infinite. The functions |
80 // called from the painter may not be thread-safe, so all calls must be made | 80 // called from the painter may not be thread-safe, so all calls must be made |
81 // from the same thread that it is created on. | 81 // from the same thread that it is created on. |
82 ScrollbarTheme* m_theme; | 82 ScrollbarTheme* m_theme; |
83 | 83 |
84 // It is assumed that the constructor of this paint object is responsible | 84 // It is assumed that the constructor of this paint object is responsible |
85 // for the lifetime of this scrollbar. The painter has to use the real | 85 // for the lifetime of this scrollbar. The painter has to use the real |
86 // scrollbar (and not a WebScrollbar wrapper) due to static_casts for | 86 // scrollbar (and not a WebScrollbar wrapper) due to static_casts for |
87 // LayoutScrollbar and pointer-based HashMap lookups for Lion scrollbars. | 87 // LayoutScrollbar and pointer-based HashMap lookups for Lion scrollbars. |
88 WebPrivatePtr<Scrollbar> m_scrollbar; | 88 WebPrivatePtr<Scrollbar> m_scrollbar; |
89 | 89 |
90 float m_deviceScaleFactor; | 90 float m_deviceScaleFactor; |
91 }; | 91 }; |
92 | 92 |
93 } // namespace blink | 93 } // namespace blink |
94 | 94 |
95 #endif | 95 #endif |
OLD | NEW |