mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-12-08 01:57:27 +01:00
win32: fix showing an alphablend parented form on win 7 and older. issue #26206, patch from Michl
git-svn-id: trunk@53436 -
This commit is contained in:
parent
83086f564a
commit
96834c85ee
@ -206,6 +206,12 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
// mantis #26206: Layered windows are only supported for top-level windows.
|
||||||
|
// After Windows 8 it is supported for child windows too.
|
||||||
|
if (WindowsVersion < wv8) and Assigned(AWinControl.Parent)
|
||||||
|
and (AWinControl is TCustomForm) and TCustomForm(AWinControl).AlphaBlend then
|
||||||
|
FlagsEx := FlagsEx and not WS_EX_LAYERED;
|
||||||
|
|
||||||
Window := CreateWindowExW(FlagsEx, PWideChar(WideString(pClassName)),
|
Window := CreateWindowExW(FlagsEx, PWideChar(WideString(pClassName)),
|
||||||
PWideChar(UTF8ToUTF16(WindowTitle)), Flags,
|
PWideChar(UTF8ToUTF16(WindowTitle)), Flags,
|
||||||
Left, Top, Width, Height, Parent, 0, HInstance, @NCCreateParams);
|
Left, Top, Width, Height, Parent, 0, HInstance, @NCCreateParams);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user