unit FMXTee.Editor.Tools.TransposeSeries;

interface

uses
  System.SysUtils, System.Types, System.UITypes, System.Classes, System.Variants,
  FMX.Types, FMX.Controls, FMX.Forms, FMX.Dialogs, FMXTee.Editor.Tools.Series,
  FMXTee.Procs,
  FMX.ListBox, FMXTee.Tools.TransposeSeries, FMX.Edit, FMX.TabControl, FMX.Colors;

type
  TTransposeSeriesToolEdit = class(TForm)
    BTranspose: TButton;
    procedure FormActivate(Sender: TObject);
    procedure BTransposeClick(Sender: TObject);
  private
    { Private declarations }
    TransposeSeries : TTransposeSeriesTool;
  public
    { Public declarations }
  end;

implementation

{$R *.fmx}

procedure TTransposeSeriesToolEdit.BTransposeClick(Sender: TObject);
begin
  if Assigned(TransposeSeries) then
    TransposeSeries.Transpose;
end;

procedure TTransposeSeriesToolEdit.FormActivate(Sender: TObject);
begin
  if not Assigned(TransposeSeries) then
  begin
    TransposeSeries:=TTransposeSeriesTool(TagObject);
  end;
end;

initialization
  RegisterSeriesEditor(TTransposeSeriesToolEdit);
end.
