unit fContruct;

interface

uses
  System.SysUtils, System.Types, System.UITypes, System.Classes, System.Variants, 
  FMX.Types, FMX.Graphics, FMX.Controls, FMX.Forms, FMX.Dialogs, FMX.StdCtrls,
  FMX.Memo.Types, FMX.ListBox, FMX.ScrollBox, FMX.Memo, FMX.Edit,
  FMX.Controls.Presentation, StrUtils;

type
  TfrContruct = class(TFrame)
    Label12: TLabel;
    edtCommand: TEdit;
    mResponse: TMemo;
    Label14: TLabel;
    GroupBox7: TGroupBox;
    btnAddUserName: TButton;
    btnGetDateFollow: TButton;
    btnGetAgeAccaunt: TButton;
    btnCounterAddtoText: TButton;
    cbCounterName: TComboBox;
    btnGPT: TButton;
    btnRandomUserName: TButton;
    btnGetChannelStat: TButton;
    btnAIPic: TButton;
    btnAddCommand: TButton;
    btnEditCommand: TButton;
    btnRmCommand: TButton;
    cbTextToSpeach: TCheckBox;
    cbHelloTTS: TCheckBox;
    procedure btnAddUserNameClick(Sender: TObject);
    procedure btnGetDateFollowClick(Sender: TObject);
    procedure btnGetAgeAccauntClick(Sender: TObject);
    procedure btnGetChannelStatClick(Sender: TObject);
    procedure btnGPTClick(Sender: TObject);
    procedure btnAIPicClick(Sender: TObject);
    procedure btnRandomUserNameClick(Sender: TObject);
    procedure btnCounterAddtoTextClick(Sender: TObject);
    procedure cbTextToSpeachExit(Sender: TObject);
    procedure cbHelloTTSExit(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

implementation

{$R *.fmx}

uses ugeneral;

procedure TfrContruct.btnAddUserNameClick(Sender: TObject);
begin
mResponse.Lines.text := mResponse.Lines.text + '[USERNAME]';
end;

procedure TfrContruct.btnAIPicClick(Sender: TObject);
begin
mResponse.Lines.text := mResponse.Lines.text + ' [Kandinsky]';
end;

procedure TfrContruct.btnCounterAddtoTextClick(Sender: TObject);
begin
if cbCounterName.Text = '' then
  exit;
mResponse.Lines.text := mResponse.Lines.text + '``'+cbCounterName.Text+'``';
end;

procedure TfrContruct.btnGetAgeAccauntClick(Sender: TObject);
begin
  mResponse.Lines.text := mResponse.Lines.text + ' [AGE]';
end;

procedure TfrContruct.btnGetChannelStatClick(Sender: TObject);
begin
 mResponse.Lines.text := mResponse.Lines.text + ' [STAT]';
end;

procedure TfrContruct.btnGetDateFollowClick(Sender: TObject);
begin
   mResponse.Lines.text := mResponse.Lines.text + ' [FOLLOW]';
end;

procedure TfrContruct.btnGPTClick(Sender: TObject);
begin
  mResponse.Lines.text := mResponse.Lines.text + ' [AI]';
end;

procedure TfrContruct.btnRandomUserNameClick(Sender: TObject);
begin
mResponse.Lines.text := mResponse.Lines.text + ' [RANDOMUSER]';
end;

procedure TfrContruct.cbHelloTTSExit(Sender: TObject);
begin
db.WriteSetting('cbHelloTTS', ifthen(cbHelloTTS.IsChecked,'True','False'));
end;

procedure TfrContruct.cbTextToSpeachExit(Sender: TObject);
begin
db.WriteSetting('cbTextToSpeach', ifthen(cbTextToSpeach.IsChecked,'True','False'));
end;

end.
