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

View File

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

View File

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