OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 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 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 virtual LengthSize minimumControlSize(ControlPart, const FontDescription&, f
loat /*zoomFactor*/) const { return LengthSize(Length(0, Fixed), Length(0, Fixed
)); } | 87 virtual LengthSize minimumControlSize(ControlPart, const FontDescription&, f
loat /*zoomFactor*/) const { return LengthSize(Length(0, Fixed), Length(0, Fixed
)); } |
88 | 88 |
89 // Allows the theme to modify the existing padding/border. | 89 // Allows the theme to modify the existing padding/border. |
90 virtual LengthBox controlPadding(ControlPart, const FontDescription&, const
LengthBox& zoomedBox, float zoomFactor) const; | 90 virtual LengthBox controlPadding(ControlPart, const FontDescription&, const
LengthBox& zoomedBox, float zoomFactor) const; |
91 virtual LengthBox controlBorder(ControlPart, const FontDescription&, const L
engthBox& zoomedBox, float zoomFactor) const; | 91 virtual LengthBox controlBorder(ControlPart, const FontDescription&, const L
engthBox& zoomedBox, float zoomFactor) const; |
92 | 92 |
93 // Whether or not whitespace: pre should be forced on always. | 93 // Whether or not whitespace: pre should be forced on always. |
94 virtual bool controlRequiresPreWhiteSpace(ControlPart) const { return false;
} | 94 virtual bool controlRequiresPreWhiteSpace(ControlPart) const { return false;
} |
95 | 95 |
96 // Method for painting a control. The rect is in zoomed coordinates. | 96 // Method for painting a control. The rect is in zoomed coordinates. |
97 virtual void paint(ControlPart, ControlStates, GraphicsContext*, const IntRe
ct& /*zoomedRect*/, float /*zoomFactor*/, ScrollableArea*) const { } | 97 virtual void paint(ControlPart, ControlStates, GraphicsContext&, const IntRe
ct& /*zoomedRect*/, float /*zoomFactor*/, ScrollableArea*) const { } |
98 | 98 |
99 // Add visual overflow (e.g., the check on an OS X checkbox). The rect passe
d in is in zoomed coordinates so | 99 // Add visual overflow (e.g., the check on an OS X checkbox). The rect passe
d in is in zoomed coordinates so |
100 // the inflation should take that into account and make sure the inflation a
mount is also scaled by the zoomFactor. | 100 // the inflation should take that into account and make sure the inflation a
mount is also scaled by the zoomFactor. |
101 virtual void addVisualOverflow(ControlPart, ControlStates, float zoomFactor,
IntRect& borderBox) const { } | 101 virtual void addVisualOverflow(ControlPart, ControlStates, float zoomFactor,
IntRect& borderBox) const { } |
102 | 102 |
103 private: | 103 private: |
104 mutable Color m_activeSelectionColor; | 104 mutable Color m_activeSelectionColor; |
105 mutable Color m_inactiveSelectionColor; | 105 mutable Color m_inactiveSelectionColor; |
106 }; | 106 }; |
107 | 107 |
108 PLATFORM_EXPORT Theme* platformTheme(); | 108 PLATFORM_EXPORT Theme* platformTheme(); |
109 | 109 |
110 } // namespace blink | 110 } // namespace blink |
111 | 111 |
112 #endif // Theme_h | 112 #endif // Theme_h |
OLD | NEW |