TAChart: Transmit sender in broadcast notifications

git-svn-id: trunk@25940 -
This commit is contained in:
ask 2010-06-06 05:58:56 +00:00
parent 4715269597
commit 68caa0b7e3
3 changed files with 5 additions and 5 deletions

View File

@ -164,7 +164,7 @@ type
public
destructor Destroy; override;
public
procedure Broadcast;
procedure Broadcast(ASender: TObject);
procedure Subscribe(AListener: TListener);
procedure Unsubscribe(AListener: TListener);
end;
@ -823,12 +823,12 @@ end;
{ TBroadcaster }
procedure TBroadcaster.Broadcast;
procedure TBroadcaster.Broadcast(ASender: TObject);
var
i: Integer;
begin
for i := 0 to Count - 1 do
TListener(Items[i]).Notify(nil);
TListener(Items[i]).Notify(ASender);
end;
destructor TBroadcaster.Destroy;

View File

@ -389,7 +389,7 @@ end;
procedure TCustomChartSource.Notify;
begin
if not IsUpdating then
FBroadcaster.Broadcast;
FBroadcaster.Broadcast(Self);
end;
procedure TCustomChartSource.ValuesInRange(

View File

@ -280,7 +280,7 @@ end;
procedure TAxisTransform.Changed;
begin
if Transformations <> nil then
Transformations.Broadcaster.Broadcast;
Transformations.Broadcaster.Broadcast(Self);
end;
constructor TAxisTransform.Create(AOwner: TComponent);