diff --git a/components/exctrls/source/excombo.pas b/components/exctrls/source/excombo.pas index 2d39d8283..8d9a07ebe 100644 --- a/components/exctrls/source/excombo.pas +++ b/components/exctrls/source/excombo.pas @@ -211,6 +211,15 @@ begin exit; end; + if DroppedDown then + begin + if (odSelected in State) then + Canvas.Brush.Color := clHighlight + else if (Canvas.Brush.Color <> Color) then + Canvas.Brush.Color := Color; + Canvas.FillRect(ARect); + end; + if Index < 0 then txt := '' else @@ -220,15 +229,6 @@ begin FParser.Delimiter := FDelimiter; FParser.DelimitedText := txt; - if not(odBackgroundPainted in State) then - Canvas.FillRect(ARect); - -{ if (odSelected in State) then - Canvas.Brush.Color := clHighlight - else if (Canvas.Brush.Color <> Color) then - Canvas.Brush.Color := Color; - Canvas.FillRect(ARect);} - y := ARect.Top + (ARect.Height - FTextHeight) shr 1; Canvas.Brush.Style := bsClear; // transparent text background