source: trunk/StudioModules/LDModuleBrainfuck/ULDModuleBrainfuck.pas

Last change on this file was 18, checked in by chronos, 12 years ago
  • Used external packages are now stored in uncompressed form rather in zipped files. This allow better package version synchronisation.
File size: 1.2 KB
Line 
1unit ULDModuleBrainfuck;
2
3{$mode delphi}{$H+}
4
5interface
6
7uses
8 Classes, SysUtils, UModularSystem, USource;
9
10type
11
12 { TLDModuleBrainfuck }
13
14 TLDModuleBrainfuck = class(TModule)
15 private
16 BFFileType: TSourceType;
17 public
18 constructor Create(Owner: TComponent); override;
19 procedure Install; override;
20 procedure Uninstall; override;
21 end;
22
23
24implementation
25
26uses
27 ULDStudioAPI;
28
29resourcestring
30 SBrainfuck = 'Brainfuck';
31
32{ TLDModuleBrainfuck }
33
34constructor TLDModuleBrainfuck.Create(Owner: TComponent);
35begin
36 inherited;
37 Identification := 'Brainfuck';
38 Title := SBrainfuck;
39 Version := '0.1';
40 License := 'GNU/LGPLv3';
41 Dependencies.Add('Basic');
42end;
43
44procedure TLDModuleBrainfuck.Install;
45begin
46 with TLDStudioAPI(API) do begin
47 BFFileType := TSourceType.Create;
48 BFFileType.Extension := '.b';
49 BFFileType.Title := 'Brainfuck source';
50 RegisterFileType(BFFileType);
51 end;
52 inherited Install;
53end;
54
55procedure TLDModuleBrainfuck.Uninstall;
56begin
57 inherited Uninstall;
58 with TLDStudioAPI(API) do begin
59 UnregisterFileType(BFFileType);
60 BFFileType.Free;
61 end;
62end;
63
64end.
65
Note: See TracBrowser for help on using the repository browser.