cdar

diff unit_Editor_tutorial.pas @ 0:ef71164288c1

begin of using hg for cdar
author "Meillo r e t u r n s <meillo@marmaro.de>"
date Sun, 03 Dec 2006 21:54:43 +0100
parents
children
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/unit_Editor_tutorial.pas	Sun Dec 03 21:54:43 2006 +0100
     1.3 @@ -0,0 +1,148 @@
     1.4 +unit unit_Editor_tutorial;
     1.5 +
     1.6 +interface//####################################################################################
     1.7 +
     1.8 +uses
     1.9 +  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
    1.10 +  Dialogs, StdCtrls, ComCtrls;
    1.11 +
    1.12 +type
    1.13 +  Tform_editor_tutorial = class(TForm)
    1.14 +    btn_close: TButton;
    1.15 +    btn_Beginner: TButton;
    1.16 +    btn_Advanced: TButton;
    1.17 +    btn_Professional: TButton;
    1.18 +    richtbx_Beginner: TRichEdit;
    1.19 +    richtbx_Advanced: TRichEdit;
    1.20 +    richtbx_Professional: TRichEdit;
    1.21 +    richtbx_Anfaenger: TRichEdit;
    1.22 +    richtbx_Fortgeschrittene: TRichEdit;
    1.23 +    richtbx_Profis: TRichEdit;
    1.24 +    procedure FormCreate(Sender: TObject);
    1.25 +    procedure FormShow(Sender: TObject);
    1.26 +    procedure FormClose(Sender: TObject; var Action: TCloseAction);
    1.27 +    procedure btn_closeClick(Sender: TObject);
    1.28 +    procedure btn_BeginnerClick(Sender: TObject);
    1.29 +    procedure btn_AdvancedClick(Sender: TObject);
    1.30 +    procedure btn_ProfessionalClick(Sender: TObject);
    1.31 +  private
    1.32 +    { Private declarations }
    1.33 +  public
    1.34 +    { Public declarations }
    1.35 +  end;
    1.36 +
    1.37 +var
    1.38 +  form_editor_tutorial: Tform_editor_tutorial;
    1.39 +
    1.40 +implementation//###############################################################################
    1.41 +uses unit_Editor;
    1.42 +{$R *.dfm}//###################################################################################
    1.43 +
    1.44 +//------------------------------------------------------------------------------ form create
    1.45 +procedure Tform_editor_tutorial.FormCreate(Sender: TObject);
    1.46 +begin
    1.47 +  // set language
    1.48 +    if form_editor.englisch = true then
    1.49 +      begin // English
    1.50 +        form_Editor_Tutorial.Caption := 'Tutorial';
    1.51 +        btn_close.Caption := 'Close';
    1.52 +        btn_Beginner.Caption := 'Beginner';
    1.53 +        btn_Advanced.Caption := 'Advanced';
    1.54 +        btn_Professional.Caption := 'Professional';
    1.55 +        richtbx_Beginner.BringToFront;
    1.56 +      end
    1.57 +    else
    1.58 +      begin // German
    1.59 +        form_Editor_Tutorial.Caption := 'Anleitung';
    1.60 +        btn_close.Caption := 'Schließen';
    1.61 +        btn_Beginner.Caption := 'Anfänger';
    1.62 +        btn_Advanced.Caption := 'Fortgeschrittene';
    1.63 +        btn_Professional.Caption := 'Profis';
    1.64 +        richtbx_Anfaenger.BringToFront;
    1.65 +      end;
    1.66 +end;//--------------------------------------------------------------------------
    1.67 +//------------------------------------------------------------------------------ form show
    1.68 +procedure Tform_editor_tutorial.FormShow(Sender: TObject);
    1.69 +begin
    1.70 +  // disable drag'n'drop
    1.71 +    form_editor.draggingstatus := 3;
    1.72 +  // disable menu
    1.73 +    form_editor.mnu_Tutorial.enabled := false;
    1.74 +    form_editor.mnu_WelcomeScreen.Enabled := false;
    1.75 +    form_editor.mnu_Autorun.Enabled := false;
    1.76 +    form_editor.mnu_CreateAR.enabled := false;
    1.77 +    form_editor.mnu_Sprache.enabled := false;
    1.78 +end;//--------------------------------------------------------------------------
    1.79 +//------------------------------------------------------------------------------ form close
    1.80 +procedure Tform_editor_tutorial.FormClose(Sender: TObject;
    1.81 +  var Action: TCloseAction);
    1.82 +begin
    1.83 +  // reenable drag'n'drop
    1.84 +    form_editor.draggingstatus := 0;
    1.85 +  // reenable menu
    1.86 +    form_editor.mnu_Tutorial.enabled := true;
    1.87 +    form_editor.mnu_WelcomeScreen.Enabled := true;
    1.88 +    form_editor.mnu_Autorun.Enabled := true;
    1.89 +    form_editor.mnu_CreateAR.enabled := true;
    1.90 +    form_editor.mnu_Sprache.enabled := true;
    1.91 +end;//--------------------------------------------------------------------------
    1.92 +
    1.93 +//#############################################################################################
    1.94 +
    1.95 +//------------------------------------------------------------------------------ close
    1.96 +procedure Tform_editor_tutorial.btn_closeClick(Sender: TObject);
    1.97 +begin
    1.98 +  form_editor_tutorial.Close;
    1.99 +end;//--------------------------------------------------------------------------
   1.100 +
   1.101 +//------------------------------------------------------------------------------ beginner
   1.102 +procedure Tform_editor_tutorial.btn_BeginnerClick(Sender: TObject);
   1.103 +begin
   1.104 +  if form_editor.englisch = true then
   1.105 +    begin
   1.106 +      richtbx_Beginner.BringToFront;
   1.107 +    end
   1.108 +  else
   1.109 +    begin
   1.110 +      richtbx_Anfaenger.BringToFront;
   1.111 +    end;
   1.112 +
   1.113 +  btn_Beginner.Enabled := false;
   1.114 +  btn_Advanced.Enabled := true;
   1.115 +  btn_Professional.Enabled := true;
   1.116 +end;//--------------------------------------------------------------------------
   1.117 +//------------------------------------------------------------------------------ advanced
   1.118 +procedure Tform_editor_tutorial.btn_AdvancedClick(Sender: TObject);
   1.119 +begin
   1.120 +  if form_editor.englisch = true then
   1.121 +    begin
   1.122 +      richtbx_Advanced.BringToFront;
   1.123 +    end
   1.124 +  else
   1.125 +    begin
   1.126 +      richtbx_Fortgeschrittene.BringToFront;
   1.127 +    end;
   1.128 +
   1.129 +
   1.130 +  btn_Beginner.Enabled := true;
   1.131 +  btn_Advanced.Enabled := false;
   1.132 +  btn_Professional.Enabled := true;
   1.133 +end;//--------------------------------------------------------------------------
   1.134 +//------------------------------------------------------------------------------ professional
   1.135 +procedure Tform_editor_tutorial.btn_ProfessionalClick(Sender: TObject);
   1.136 +begin
   1.137 +  if form_editor.englisch = true then
   1.138 +    begin
   1.139 +      richtbx_Professional.BringToFront;
   1.140 +    end
   1.141 +  else
   1.142 +    begin
   1.143 +      richtbx_Profis.BringToFront;
   1.144 +    end;
   1.145 +
   1.146 +  btn_Beginner.Enabled := true;
   1.147 +  btn_Advanced.Enabled := true;
   1.148 +  btn_Professional.Enabled := false;
   1.149 +end;//--------------------------------------------------------------------------
   1.150 +
   1.151 +end.//#########################################################################################