Rev 5959 | Rev 6746 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 5959 | Rev 6050 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | #define MEMSIZE 0x3E80 |
1 | #define MEMSIZE 4096*10 |
Line 2... | Line 2... | ||
2 | 2 | ||
- | 3 | #include "../lib/io.h" |
|
Line 3... | Line 4... | ||
3 | #include "../lib/io.h" |
4 | #include "../lib/gui.h" |
4 | 5 | ||
5 | void main() |
6 | void main() |
6 | { |
7 | { |
7 | int id, key, i; |
8 | word id; |
8 | dword file; |
- | |
9 | io.dir.load(0,DIR_ONLYREAL); |
- | |
10 | loop() |
9 | dword file; |
11 | { |
10 | io.dir.load(0,DIR_ONLYREAL); |
12 | switch(WaitEvent()) |
11 | loop() switch(WaitEvent()) |
13 | { |
12 | { |
14 | case evButton: |
13 | case evButton: |
15 | id=GetButtonID(); |
14 | id=GetButtonID(); |
Line 16... | Line 15... | ||
16 | if (id==1) ExitProcess(); |
15 | if (id==1) ExitProcess(); |
17 | break; |
16 | break; |
18 | 17 | ||
19 | case evKey: |
- | |
20 | key = GetKey(); |
- | |
21 | if (key==013){ //Enter |
- | |
22 | draw_window(); |
18 | case evKey: |
Line 23... | Line 19... | ||
23 | 19 | GetKeys(); |
|
24 | } |
20 | if (key_scancode == SCAN_CODE_ESC ) ExitProcess(); |
25 | break; |
21 | break; |
26 | 22 | ||
27 | case evReDraw: |
23 | case evReDraw: |
28 | draw_window(); |
- | |
29 | break; |
24 | draw_window(); |
30 | } |
25 | break; |
31 | } |
26 | } |
32 | } |
27 | } |
33 | void draw_window() |
- | |
34 | { |
28 | void draw_window() |
35 | proc_info Form; |
29 | { |
36 | int i; |
30 | proc_info Form; |
37 | i=0; |
31 | int i; |
38 | DefineAndDrawWindow(215,100,250,200,0x34,0xFFFFFF,"Window header"); |
32 | DefineAndDrawWindow(215,100,350,300,0x34,0xFFFFFF,"Window header"); |
39 | GetProcessInfo(#Form, SelfInfo); |
- | |
40 | while(i |
33 | GetProcessInfo(#Form, SelfInfo); |
- | 34 | for (i=0; i |
|
41 | { |
35 | { |
- | 36 | WriteText(5,i*8+3,0x80,0xFF00FF,io.dir.position(i)); |
|
- | 37 | } |
|
42 | WriteText(5,i*8+3,0x80,0xFF00FF,io.dir.position(i)); |
38 | DrawCaptButton(100, 10, 100, 22, 22, 0xCCCccc, 0x000000, "Button"); |
43 | i++; |
39 | WriteText(100,50,0x80,0,"Textline small"); |