* Enable TDatasource.Enabled, patch from Laco

git-svn-id: trunk@49630 -
This commit is contained in:
michael 2021-07-22 05:50:22 +00:00
parent b9db32ca05
commit c48ac0a71e

View File

@ -639,6 +639,7 @@ procedure TDatasource.SetEnabled(Value: Boolean);
begin
FEnabled:=Value;
ProcessEvent(deUpdateState,0);
end;
@ -679,7 +680,7 @@ procedure TDataSource.ProcessEvent(Event : TDataEvent; Info : Ptrint);
Const
OnDataChangeEvents = [deRecordChange, deDataSetChange, deDataSetScroll,
deLayoutChange,deUpdateState];
deLayoutChange, deUpdateState];
Var
NeedDataChange : Boolean;
@ -691,7 +692,7 @@ begin
begin
NeedDataChange:=(FState=dsInactive);
FLastState:=FState;
If Assigned(Dataset) then
If Assigned(Dataset) and FEnabled then
FState:=Dataset.State
else
FState:=dsInactive;