From 02b5ebb30fc88967b843818cbc61987f9dc9685d Mon Sep 17 00:00:00 2001 From: Leon Clarke Date: Thu, 1 Oct 2009 10:30:38 +0100 Subject: Don't extend the arrow asset of the combo box over the text, so that the real background color is used. Re-instate using the correct color for the text. --- WebKit/android/RenderSkinCombo.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'WebKit/android') diff --git a/WebKit/android/RenderSkinCombo.cpp b/WebKit/android/RenderSkinCombo.cpp index 870c13e..fd6f1f2 100644 --- a/WebKit/android/RenderSkinCombo.cpp +++ b/WebKit/android/RenderSkinCombo.cpp @@ -36,9 +36,9 @@ namespace WebCore { static SkBitmap s_bitmap[2]; // Collection of assets for a combo box static bool s_decoded; // True if all assets were decoded -static const int s_margin = 2; +static const int s_margin = 0; static const SkIRect s_mar = { s_margin, s_margin, - RenderSkinCombo::extraWidth(), s_margin }; + RenderSkinCombo::extraWidth() - 2, s_margin }; RenderSkinCombo::RenderSkinCombo() { @@ -61,11 +61,8 @@ bool RenderSkinCombo::Draw(SkCanvas* canvas, Node* element, int x, int y, int wi return true; State state = (element->isElementNode() && static_cast(element)->isEnabledFormControl()) ? kNormal : kDisabled; - if (height < (s_margin<<1) + 1) { - height = (s_margin<<1) + 1; - } SkRect bounds; - bounds.set(SkIntToScalar(x), SkIntToScalar(y), SkIntToScalar(x + width), SkIntToScalar(y + height)); + bounds.set(SkIntToScalar(x + width), SkIntToScalar(y), SkIntToScalar(x + width), SkIntToScalar(y + height)); SkNinePatch::DrawNine(canvas, bounds, s_bitmap[state], s_mar); return false; } -- cgit v1.1