Changeset 115 for trunk/Forms/UFormAbout.pas
- Timestamp:
- Dec 10, 2016, 3:52:26 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Forms/UFormAbout.pas
r47 r115 1 1 unit UFormAbout; 2 2 3 {$ MODE Delphi}3 {$mode delphi} 4 4 5 5 interface 6 6 7 7 uses 8 SysUtils, Classes, Graphics, Forms, Controls, StdCtrls,9 Buttons, ExtCtrls;8 Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, Menus, 9 StdCtrls, ExtCtrls, UApplicationInfo, UCommon; 10 10 11 11 type … … 14 14 15 15 TFormAbout = class(TForm) 16 ButtonHomePage: TButton; 17 ButtonClose: TButton; 18 Image1: TImage; 19 LabelAppName: TLabel; 20 LabelDescription: TLabel; 21 LabelContent: TLabel; 16 22 Panel1: TPanel; 17 OKButton: TButton; 18 Memo1: TMemo; 19 procedure OKButtonClick(Sender: TObject); 23 procedure ButtonHomePageClick(Sender: TObject); 24 procedure FormCreate(Sender: TObject); 20 25 procedure FormShow(Sender: TObject); 21 26 private 22 { Private declarations }27 { private declarations } 23 28 public 24 { Public declarations }29 { public declarations } 25 30 end; 26 31 … … 36 41 37 42 resourcestring 38 SApplicationName = 'Application name';39 43 SVersion = 'Version'; 40 44 SReleaseDate = 'Release date'; 41 S Manufacturer = 'Company';42 SEmail = 'E-mail'; 43 SHomePage = 'Homepage'; 45 SLicense = 'License'; 46 47 { TFormAbout } 44 48 45 49 procedure TFormAbout.FormShow(Sender: TObject); 46 50 begin 47 with Memo1, Lines, Core.ApplicationInfo do begin 48 BeginUpdate; 49 Clear; 50 Add(SApplicationName + ': ' + AppName); 51 Add(SVersion + ': ' + Version); 52 Add(SReleaseDate + ': ' + DateToStr(ReleaseDate)); 53 Add(SHomePage + ': ' + HomePage); 54 Add(SManufacturer + ': ' + CompanyName); 55 Add(SEmail + ': ' + EmailContact); 56 EndUpdate; 51 with Core do begin 52 LabelAppName.Caption := ApplicationInfo.AppName; 53 LabelContent.Caption := SVersion + ': ' + ApplicationInfo.Version + LineEnding + 54 SReleaseDate + ': ' + DateToStr(ApplicationInfo.ReleaseDate) + LineEnding + 55 SLicense + ': ' + ApplicationInfo.License; 57 56 end; 58 FocusControl(OKButton);59 57 end; 60 58 61 procedure TFormAbout. OKButtonClick(Sender: TObject);59 procedure TFormAbout.ButtonHomePageClick(Sender: TObject); 62 60 begin 63 Close; 61 OpenWebPage(Core.ApplicationInfo.HomePage); 62 end; 63 64 procedure TFormAbout.FormCreate(Sender: TObject); 65 begin 66 Core.CoolTranslator1.TranslateComponentRecursive(Self); 64 67 end; 65 68 66 69 end. 67 70
Note:
See TracChangeset
for help on using the changeset viewer.