Last change
on this file was 16, checked in by george, 15 years ago |
- Upraveno: Rozdělení jednotek pro generování výstupů do samostatných souborů.
- Přidáno: Generátor kódu pro procesor Z80.
- Přidáno: Parsování celých čísel.
|
File size:
845 bytes
|
Line | |
---|
1 | unit UModelViewer;
|
---|
2 |
|
---|
3 | {$mode Delphi}{$H+}
|
---|
4 |
|
---|
5 | interface
|
---|
6 |
|
---|
7 | uses
|
---|
8 | Classes, SysUtils, StdCtrls, ComCtrls, UModel;
|
---|
9 |
|
---|
10 | type
|
---|
11 |
|
---|
12 | { TModelViewer }
|
---|
13 |
|
---|
14 | TModelViewer = class
|
---|
15 | private
|
---|
16 | TreeView: TTreeView;
|
---|
17 | procedure LoadVariables(Node: TTreeNode; Module: TModule);
|
---|
18 | public
|
---|
19 | procedure Show(ATreeView: TTreeView);
|
---|
20 | end;
|
---|
21 |
|
---|
22 | implementation
|
---|
23 |
|
---|
24 | procedure TModelViewer.LoadVariables(Node: TTreeNode; Module: TModule);
|
---|
25 | begin
|
---|
26 |
|
---|
27 | end;
|
---|
28 |
|
---|
29 | procedure TModelViewer.Show(ATreeView: TTreeView);
|
---|
30 | var
|
---|
31 | NewNode: TTreeNode;
|
---|
32 | ProgramNode: TTreeNode;
|
---|
33 | begin
|
---|
34 | TreeView := ATreeView;
|
---|
35 | with TreeView do begin
|
---|
36 | Items.Clear;
|
---|
37 | ProgramNode := Items.AddChild(TopItem, 'program');
|
---|
38 | NewNode := Items.AddChild(ProgramNode, 'var');
|
---|
39 | NewNode := Items.AddChild(ProgramNode, 'begin-end');
|
---|
40 | TopItem.Expand(True);
|
---|
41 | end;
|
---|
42 | end;
|
---|
43 |
|
---|
44 |
|
---|
45 | end.
|
---|
46 |
|
---|
Note:
See
TracBrowser
for help on using the repository browser.