mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-24 12:39:23 +02:00
lcl: fix owner drawn statusbar panels
- don't skip TStatusPanel.Bevel - assign passed in the WM_DrawItem Message DC to the Canvas.Handle git-svn-id: trunk@18318 -
This commit is contained in:
parent
9c9c8716f2
commit
f71d89b2b3
@ -88,9 +88,12 @@ end;
|
||||
|
||||
procedure TStatusBar.LMDrawItem(var Message: TLMDrawItems);
|
||||
begin
|
||||
if assigned(FOnDrawPanel) then
|
||||
if Assigned(FOnDrawPanel) then
|
||||
with Message.DrawItemStruct^ do
|
||||
FOnDrawPanel(Self,Panels[itemID],rcItem);
|
||||
begin
|
||||
Canvas.Handle := _hDC;
|
||||
FOnDrawPanel(Self, Panels[itemID], rcItem);
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TStatusBar.BoundsChanged;
|
||||
|
@ -270,10 +270,9 @@ begin
|
||||
taCenter: Text := #9 + Text;
|
||||
taRightJustify: Text := #9#9 + Text;
|
||||
end;
|
||||
if StatusPanel.Style=psOwnerDraw then
|
||||
WParam := SBT_OWNERDRAW
|
||||
else
|
||||
WParam := StatusBevelMap[StatusPanel.Bevel];
|
||||
WParam := StatusBevelMap[StatusPanel.Bevel];
|
||||
if StatusPanel.Style = psOwnerDraw then
|
||||
WParam := WParam or SBT_OWNERDRAW;
|
||||
WParam := WParam or StatusPanel.Index;
|
||||
{$ifdef WindowsUnicodeSupport}
|
||||
if UnicodeEnabledOS then
|
||||
|
Loading…
Reference in New Issue
Block a user