mainform may also be an MDI form, or a stay on top form (fixes bug #656)

git-svn-id: trunk@7044 -
This commit is contained in:
micha 2005-03-31 20:07:44 +00:00
parent 3d07b12402
commit cdcf64b178
2 changed files with 5 additions and 2 deletions

View File

@ -1404,7 +1404,7 @@ begin
if (Instance is TForm) then begin
AForm:=TForm(Instance);
if (FMainForm = nil) and (AForm.FormStyle=fsNormal) then begin
if (FMainForm = nil) and not (AForm.FormStyle in [fsMDIChild, fsSplash]) then begin
FMainForm := AForm;
AForm.HandleNeeded;
end else begin
@ -1453,6 +1453,9 @@ end;
{ =============================================================================
$Log$
Revision 1.113 2005/03/31 20:07:44 micha
mainform may also be an MDI form, or a stay on top form (fixes bug 656)
Revision 1.112 2005/03/26 11:24:55 micha
remove TApplication.Handle (not cross-platform)

View File

@ -239,7 +239,7 @@ begin
Flags := BorderStyleToWin32Flags(BorderStyle);
FlagsEx := BorderStyleToWin32FlagsEx(BorderStyle);
if (lForm.FormStyle in fsAllStayOnTop) and
(not (csDesigning in lForm.ComponentState)) then
not (csDesigning in lForm.ComponentState) then
FlagsEx := FlagsEx or WS_EX_TOPMOST;
Flags := Flags or CalcBorderIconsFlags(lForm);
pClassName := @ClsName;