let canfocus imply that setfocus can be called

git-svn-id: trunk@6478 -
This commit is contained in:
micha 2005-01-04 11:26:26 +00:00
parent d62f50ff28
commit a6cc7c88ea
2 changed files with 11 additions and 4 deletions

View File

@ -1094,7 +1094,8 @@ Begin
if not
((AWinControl = nil)
or (AWinControl <> Self) and (GetParentForm(AWinControl) = Self)
and ((csLoading in ComponentState) or AWinControl.CanFocus))
and ((csLoading in ComponentState) or not (Visible and Enabled)
or AWinControl.CanFocus))
then
RaiseGDBException(SCannotFocus);
// EInvalidOperation.Create(SCannotFocus);
@ -1827,6 +1828,9 @@ end;
{ =============================================================================
$Log$
Revision 1.170 2005/01/04 11:26:26 micha
let canfocus imply that setfocus can be called
Revision 1.169 2004/12/27 00:06:44 mattias
added DestroyHandle after ShowModal to save resources

View File

@ -736,11 +736,11 @@ begin
if Form <> nil then
begin
Control := Self;
while Control <> Form do
begin
repeat
if not (Control.FVisible and Control.Enabled) then Exit;
if Control = Form then break;
Control := Control.Parent;
end;
until false;
Result := True;
end;
end;
@ -4232,6 +4232,9 @@ end;
{ =============================================================================
$Log$
Revision 1.295 2005/01/04 11:26:26 micha
let canfocus imply that setfocus can be called
Revision 1.294 2005/01/03 22:44:31 mattias
implemented TControl.AnchorSide