mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-15 11:39:19 +02:00
win32: repair focus rectangle for themed windows (bug #0012885)
git-svn-id: trunk@18004 -
This commit is contained in:
parent
e600258955
commit
c0bf8bbc48
@ -39,7 +39,7 @@ uses
|
|||||||
WSControls, WSLCLClasses, SysUtils, Win32Proc, Win32Extra, WSProc,
|
WSControls, WSLCLClasses, SysUtils, Win32Proc, Win32Extra, WSProc,
|
||||||
{ TODO: needs to move }
|
{ TODO: needs to move }
|
||||||
Forms, ComCtrls, Buttons, StdCtrls, ExtCtrls, GraphMath, GraphType,
|
Forms, ComCtrls, Buttons, StdCtrls, ExtCtrls, GraphMath, GraphType,
|
||||||
InterfaceBase, LCLIntf, LCLType, LCLProc;
|
InterfaceBase, LCLIntf, LCLType, LCLProc, Themes;
|
||||||
|
|
||||||
type
|
type
|
||||||
{ TWin32WSDragImageList }
|
{ TWin32WSDragImageList }
|
||||||
@ -247,7 +247,12 @@ begin
|
|||||||
lhFont := GetStockObject(DEFAULT_GUI_FONT)
|
lhFont := GetStockObject(DEFAULT_GUI_FONT)
|
||||||
else
|
else
|
||||||
lhFont := AWinControl.Font.Reference.Handle;
|
lhFont := AWinControl.Font.Reference.Handle;
|
||||||
Windows.SendMessage(Window, WM_SETFONT, WPARAM(lhFont), 0)
|
Windows.SendMessage(Window, WM_SETFONT, WPARAM(lhFont), 0);
|
||||||
|
// on themed applications windows for some reason hides focus rectangle if
|
||||||
|
// hide underlined letters for keyboard navigation setting is on
|
||||||
|
// read for example here: http://www.icetips.com/showarticle.php?articleid=450
|
||||||
|
if ThemeServices.ThemesEnabled then
|
||||||
|
Windows.SendMessage(Window, WM_CHANGEUISTATE, MakeWParam(UIS_CLEAR, UISF_HIDEFOCUS), 0)
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user