mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-12 08:40:42 +01:00
LCL: default implementation of themed headers
git-svn-id: trunk@11185 -
This commit is contained in:
parent
759a269ca6
commit
28a2530ec6
@ -162,7 +162,7 @@ begin
|
|||||||
Result.IsHot := False;
|
Result.IsHot := False;
|
||||||
|
|
||||||
case Details.Element of
|
case Details.Element of
|
||||||
teButton:
|
teButton, teHeader:
|
||||||
begin
|
begin
|
||||||
case Details.Part of
|
case Details.Part of
|
||||||
BP_PUSHBUTTON:
|
BP_PUSHBUTTON:
|
||||||
|
|||||||
@ -1765,7 +1765,7 @@ var
|
|||||||
begin
|
begin
|
||||||
// default painting
|
// default painting
|
||||||
ARect := R; // in order to pass by reference
|
ARect := R; // in order to pass by reference
|
||||||
if Details.Element in [teButton, teToolBar] then
|
if Details.Element in [teButton, teToolBar, teHeader] then
|
||||||
begin
|
begin
|
||||||
ADrawFlags := DFCS_BUTTONPUSH;
|
ADrawFlags := DFCS_BUTTONPUSH;
|
||||||
|
|
||||||
@ -1838,14 +1838,14 @@ end;
|
|||||||
function TThemeServices.IsPushed(Details: TThemedElementDetails): Boolean;
|
function TThemeServices.IsPushed(Details: TThemedElementDetails): Boolean;
|
||||||
begin
|
begin
|
||||||
Result := False;
|
Result := False;
|
||||||
if (Details.Element in [teButton, teToolBar]) then
|
if (Details.Element in [teButton, teToolBar, teHeader]) then
|
||||||
Result := Details.State in [3, 5, 6];
|
Result := Details.State in [3, 5, 6];
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TThemeServices.IsHot(Details: TThemedElementDetails): Boolean;
|
function TThemeServices.IsHot(Details: TThemedElementDetails): Boolean;
|
||||||
begin
|
begin
|
||||||
Result := False;
|
Result := False;
|
||||||
if (Details.Element in [teButton, teToolBar]) then
|
if (Details.Element in [teButton, teToolBar, teHeader]) then
|
||||||
Result := Details.State in [2, 6];
|
Result := Details.State in [2, 6];
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user