mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-18 15:39:32 +02:00
win32: also handle correct when themes are not enabled
git-svn-id: trunk@17092 -
This commit is contained in:
parent
1628077528
commit
48793b3843
@ -343,9 +343,11 @@ begin
|
||||
end;
|
||||
|
||||
CN_NOTIFY:
|
||||
if Sender is TCustomTrackBar then
|
||||
with TLMessage(Message) do
|
||||
Result := SendMessage(Handle, Msg, WParam, LParam);
|
||||
if (Sender is TCustomTrackBar) then
|
||||
Result := SendMessage(Handle, Msg, WParam, LParam)
|
||||
else
|
||||
Result := CallDefaultWindowProc(Handle, Msg, WParam, LParam);
|
||||
else
|
||||
if TLMessage(Message).Msg >= WM_USER then
|
||||
with TLMessage(Message) do
|
||||
|
@ -613,12 +613,11 @@ var
|
||||
Details: TThemedElementDetails;
|
||||
NMHdr: PNMHDR;
|
||||
begin
|
||||
if ThemeServices.ThemesEnabled then
|
||||
begin
|
||||
// Paul: next is a slightly modified code of TThemeManager.TrackBarWindowProc
|
||||
// of Mike Lischke Theme manager library (Mike granted us permition to use his code)
|
||||
case Msg of
|
||||
CN_NOTIFY:
|
||||
if ThemeServices.ThemesEnabled then
|
||||
begin
|
||||
NMHdr := PNMHDR(LParam);
|
||||
if NMHdr^.code = NM_CUSTOMDRAW then
|
||||
@ -693,13 +692,12 @@ begin
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
else
|
||||
Result := WindowProc(Window, Msg, WParam, LParam);
|
||||
end;
|
||||
end
|
||||
else
|
||||
Result := CallDefaultWindowProc(Window, Msg, WParam, LParam);
|
||||
else
|
||||
Result := WindowProc(Window, Msg, WParam, LParam);
|
||||
end;
|
||||
end;
|
||||
|
||||
{ TWin32WSTrackBar }
|
||||
|
Loading…
Reference in New Issue
Block a user