| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007 Apple Inc. | 2 * Copyright (C) 2007 Apple Inc. |
| 3 * Copyright (C) 2007 Alp Toker <alp@atoker.com> | 3 * Copyright (C) 2007 Alp Toker <alp@atoker.com> |
| 4 * Copyright (C) 2008 Collabora Ltd. | 4 * Copyright (C) 2008 Collabora Ltd. |
| 5 * Copyright (C) 2008, 2009 Google Inc. | 5 * Copyright (C) 2008, 2009 Google Inc. |
| 6 * Copyright (C) 2009 Kenneth Rohde Christiansen | 6 * Copyright (C) 2009 Kenneth Rohde Christiansen |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 262 if (useMockTheme()) { | 262 if (useMockTheme()) { |
| 263 // The size and position of the drop-down button is different between | 263 // The size and position of the drop-down button is different between |
| 264 // the mock theme and the regular aura theme. | 264 // the mock theme and the regular aura theme. |
| 265 int spacingTop = box.borderTop() + box.paddingTop(); | 265 int spacingTop = box.borderTop() + box.paddingTop(); |
| 266 int spacingBottom = box.borderBottom() + box.paddingBottom(); | 266 int spacingBottom = box.borderBottom() + box.paddingBottom(); |
| 267 int spacingRight = box.borderRight() + box.paddingRight(); | 267 int spacingRight = box.borderRight() + box.paddingRight(); |
| 268 extraParams.menuList.arrowX = (box.styleRef().direction() == RTL) ? rect
.x() + 4 + spacingRight: right - 10 - spacingRight; | 268 extraParams.menuList.arrowX = (box.styleRef().direction() == RTL) ? rect
.x() + 4 + spacingRight: right - 10 - spacingRight; |
| 269 extraParams.menuList.arrowSize = rect.height() - spacingBottom - spacing
Top; | 269 extraParams.menuList.arrowSize = rect.height() - spacingBottom - spacing
Top; |
| 270 } else { | 270 } else { |
| 271 const int arrowSize = 6; | 271 const int arrowSize = 6; |
| 272 const int arrowPadding = 7; | 272 const int arrowPadding = 6; |
| 273 extraParams.menuList.arrowX = (box.styleRef().direction() == RTL) | 273 extraParams.menuList.arrowX = (box.styleRef().direction() == RTL) |
| 274 ? rect.x() + arrowPadding * box.styleRef().effectiveZoom() | 274 ? rect.x() + arrowPadding * box.styleRef().effectiveZoom() + box.bor
derLeft() |
| 275 : right - (arrowSize + arrowPadding) * box.styleRef().effectiveZoom(
); | 275 : right - (arrowSize + arrowPadding) * box.styleRef().effectiveZoom(
) - box.borderRight(); |
| 276 extraParams.menuList.arrowSize = arrowSize * box.styleRef().effectiveZoo
m(); | 276 extraParams.menuList.arrowSize = arrowSize * box.styleRef().effectiveZoo
m(); |
| 277 } | 277 } |
| 278 extraParams.menuList.arrowColor = box.resolveColor(CSSPropertyColor).rgb(); | 278 extraParams.menuList.arrowColor = box.resolveColor(CSSPropertyColor).rgb(); |
| 279 } | 279 } |
| 280 | 280 |
| 281 bool ThemePainterDefault::paintSliderTrack(const LayoutObject& o, const PaintInf
o& i, const IntRect& rect) | 281 bool ThemePainterDefault::paintSliderTrack(const LayoutObject& o, const PaintInf
o& i, const IntRect& rect) |
| 282 { | 282 { |
| 283 WebThemeEngine::ExtraParams extraParams; | 283 WebThemeEngine::ExtraParams extraParams; |
| 284 WebCanvas* canvas = i.context.canvas(); | 284 WebCanvas* canvas = i.context.canvas(); |
| 285 extraParams.slider.vertical = o.styleRef().appearance() == SliderVerticalPar
t; | 285 extraParams.slider.vertical = o.styleRef().appearance() == SliderVerticalPar
t; |
| (...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 419 inputContentBox.y() + (inputContentBox.height() - magnifierSize + 1) / 2
, | 419 inputContentBox.y() + (inputContentBox.height() - magnifierSize + 1) / 2
, |
| 420 magnifierSize, magnifierSize); | 420 magnifierSize, magnifierSize); |
| 421 IntRect paintingRect = convertToPaintingRect(inputLayoutBox, magnifierObject
, magnifierRect, r); | 421 IntRect paintingRect = convertToPaintingRect(inputLayoutBox, magnifierObject
, magnifierRect, r); |
| 422 | 422 |
| 423 DEFINE_STATIC_REF(Image, magnifierImage, (Image::loadPlatformResource("searc
hMagnifier"))); | 423 DEFINE_STATIC_REF(Image, magnifierImage, (Image::loadPlatformResource("searc
hMagnifier"))); |
| 424 paintInfo.context.drawImage(magnifierImage, paintingRect); | 424 paintInfo.context.drawImage(magnifierImage, paintingRect); |
| 425 return false; | 425 return false; |
| 426 } | 426 } |
| 427 | 427 |
| 428 } // namespace blink | 428 } // namespace blink |
| OLD | NEW |