| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2008, 2009 Google, Inc. | 3 * Copyright (C) 2008, 2009 Google, Inc. |
| 4 * | 4 * |
| 5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
| 6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
| 7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
| 8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
| 9 * | 9 * |
| 10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
| (...skipping 1137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1148 void RenderThemeChromiumMac::paintMenuListButtonGradients(RenderObject* o, const
PaintInfo& paintInfo, const IntRect& r) | 1148 void RenderThemeChromiumMac::paintMenuListButtonGradients(RenderObject* o, const
PaintInfo& paintInfo, const IntRect& r) |
| 1149 { | 1149 { |
| 1150 if (r.isEmpty()) | 1150 if (r.isEmpty()) |
| 1151 return; | 1151 return; |
| 1152 | 1152 |
| 1153 ContextContainer cgContextContainer(paintInfo.context); | 1153 ContextContainer cgContextContainer(paintInfo.context); |
| 1154 CGContextRef context = cgContextContainer.context(); | 1154 CGContextRef context = cgContextContainer.context(); |
| 1155 | 1155 |
| 1156 GraphicsContextStateSaver stateSaver(*paintInfo.context); | 1156 GraphicsContextStateSaver stateSaver(*paintInfo.context); |
| 1157 | 1157 |
| 1158 RoundedRect border = o->style()->getRoundedBorderFor(r, o->view()); | 1158 RoundedRect border = o->style()->getRoundedBorderFor(r); |
| 1159 int radius = border.radii().topLeft().width(); | 1159 int radius = border.radii().topLeft().width(); |
| 1160 | 1160 |
| 1161 CGColorSpaceRef cspace = deviceRGBColorSpaceRef(); | 1161 CGColorSpaceRef cspace = deviceRGBColorSpaceRef(); |
| 1162 | 1162 |
| 1163 FloatRect topGradient(r.x(), r.y(), r.width(), r.height() / 2.0f); | 1163 FloatRect topGradient(r.x(), r.y(), r.width(), r.height() / 2.0f); |
| 1164 struct CGFunctionCallbacks topCallbacks = { 0, TopGradientInterpolate, NULL
}; | 1164 struct CGFunctionCallbacks topCallbacks = { 0, TopGradientInterpolate, NULL
}; |
| 1165 RetainPtr<CGFunctionRef> topFunction(AdoptCF, CGFunctionCreate(NULL, 1, NULL
, 4, NULL, &topCallbacks)); | 1165 RetainPtr<CGFunctionRef> topFunction(AdoptCF, CGFunctionCreate(NULL, 1, NULL
, 4, NULL, &topCallbacks)); |
| 1166 RetainPtr<CGShadingRef> topShading(AdoptCF, CGShadingCreateAxial(cspace, CGP
ointMake(topGradient.x(), topGradient.y()), CGPointMake(topGradient.x(), topGrad
ient.maxY()), topFunction.get(), false, false)); | 1166 RetainPtr<CGShadingRef> topShading(AdoptCF, CGShadingCreateAxial(cspace, CGP
ointMake(topGradient.x(), topGradient.y()), CGPointMake(topGradient.x(), topGrad
ient.maxY()), topFunction.get(), false, false)); |
| 1167 | 1167 |
| 1168 FloatRect bottomGradient(r.x() + radius, r.y() + r.height() / 2.0f, r.width(
) - 2.0f * radius, r.height() / 2.0f); | 1168 FloatRect bottomGradient(r.x() + radius, r.y() + r.height() / 2.0f, r.width(
) - 2.0f * radius, r.height() / 2.0f); |
| (...skipping 835 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2004 | 2004 |
| 2005 bool RenderThemeChromiumMac::shouldUseFallbackTheme(RenderStyle* style) const | 2005 bool RenderThemeChromiumMac::shouldUseFallbackTheme(RenderStyle* style) const |
| 2006 { | 2006 { |
| 2007 ControlPart part = style->appearance(); | 2007 ControlPart part = style->appearance(); |
| 2008 if (part == CheckboxPart || part == RadioPart) | 2008 if (part == CheckboxPart || part == RadioPart) |
| 2009 return style->effectiveZoom() != 1; | 2009 return style->effectiveZoom() != 1; |
| 2010 return false; | 2010 return false; |
| 2011 } | 2011 } |
| 2012 | 2012 |
| 2013 } // namespace WebCore | 2013 } // namespace WebCore |
| OLD | NEW |