Rev 485 | Go to most recent revision | Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
255 | heavyiron | 1 | ;----------------------------------------------------------- |
2 | ;---load icons in memory and draw icons on panel----------- |
||
3 | ;----------------------------------------------------------- |
||
4 | load_icons: |
||
5 | mov esi,panel_picture |
||
6 | mov edi,[ScreenPointer] |
||
7 | mov eax,edi |
||
8 | add edi,(1200*1000*3) |
||
9 | ;mov edi,[PointerToIcons] |
||
10 | call ReadGIF |
||
11 | |||
12 | ret |
||
13 | |||
14 | draw_icons: |
||
15 | |||
16 | mov [Icon_X],7 |
||
17 | mov [Icon_Y],20+15+4 |
||
18 | |||
19 | ;draw panel picture |
||
20 | mov edx,[Icon_X] |
||
21 | shl edx,16 |
||
22 | add edx,[Icon_Y] |
||
23 | mov ebx,[ScreenPointer] |
||
24 | add ebx,(1200*1000*3)+12 |
||
25 | mov eax,7 |
||
26 | mov ecx,417*65536+46 |
||
27 | int 0x40 |
||
28 | |||
29 | |||
30 | ;main buttons of instrumnts |
||
31 | |||
32 | and [counter],0 |
||
33 | mov [Icon_X],8 |
||
34 | mov [Icon_Y],20+15+4+1 |
||
35 | |||
36 | main_buttons: |
||
37 | |||
38 | mov eax,8 |
||
39 | mov ebx,[Icon_X] |
||
40 | mov ecx,[Icon_Y] |
||
41 | dec ebx |
||
42 | dec ecx |
||
43 | shl ebx,16 |
||
44 | shl ecx,16 |
||
45 | add ebx,19 |
||
46 | add ecx,20 |
||
47 | mov edx,[counter] |
||
48 | add edx,10 |
||
49 | add edx,1000000000000000000000000000000b |
||
50 | int 0x40 |
||
51 | |||
52 | |||
53 | add [Icon_X],22 |
||
54 | |||
55 | inc [counter] |
||
56 | cmp [counter],19 |
||
57 | jne main_buttons |
||
58 | |||
59 | |||
60 | ;buttons of brushes(and lines width) |
||
61 | and [counter],0 |
||
62 | |||
63 | mov [Icon_X],7+1 |
||
64 | mov [Icon_Y],20+15+4+25+1 |
||
65 | |||
66 | next_button_brush: |
||
67 | |||
68 | mov eax,8 |
||
69 | mov ebx,[Icon_X] |
||
70 | mov ecx,[Icon_Y] |
||
71 | dec ebx |
||
72 | dec ecx |
||
73 | shl ebx,16 |
||
74 | shl ecx,16 |
||
75 | add ebx,19 |
||
76 | add ecx,20 |
||
77 | mov edx,[counter] |
||
78 | add edx,40 |
||
79 | add edx,1000000000000000000000000000000b |
||
80 | int 0x40 |
||
81 | |||
82 | add [Icon_X],19 |
||
83 | |||
84 | inc [counter] |
||
85 | cmp [counter],5 |
||
86 | jne next_button_brush |
||
87 | |||
88 | |||
89 | ;buttons of zoom |
||
90 | and [counter],0 |
||
91 | |||
92 | mov [Icon_X],7+155+1 |
||
93 | mov [Icon_Y],20+15+4+25+1 |
||
94 | |||
95 | next_button_zoom: |
||
96 | |||
97 | mov eax,8 |
||
98 | mov ebx,[Icon_X] |
||
99 | mov ecx,[Icon_Y] |
||
100 | dec ebx |
||
101 | dec ecx |
||
102 | shl ebx,16 |
||
103 | shl ecx,16 |
||
104 | add ebx,19 |
||
105 | add ecx,20 |
||
106 | mov edx,[counter] |
||
107 | add edx,45 |
||
108 | add edx,1000000000000000000000000000000b |
||
109 | int 0x40 |
||
110 | |||
111 | add [Icon_X],19 |
||
112 | |||
113 | inc [counter] |
||
114 | cmp [counter],6 |
||
115 | jne next_button_zoom |
||
116 | |||
117 | |||
118 | ; button of palette |
||
119 | mov [Icon_X],7+105+1 |
||
120 | mov [Icon_Y],20+15+4+25+1 |
||
121 | |||
122 | mov eax,8 |
||
123 | mov ebx,[Icon_X] |
||
124 | mov ecx,[Icon_Y] |
||
125 | dec ebx |
||
126 | dec ecx |
||
127 | shl ebx,16 |
||
128 | shl ecx,16 |
||
129 | add ebx,20 |
||
130 | add ecx,21 |
||
131 | mov edx,51 |
||
132 | add edx,1000000000000000000000000000000b |
||
133 | int 0x40 |
||
134 | |||
135 | ; button of color |
||
136 | mov [Icon_X],7+128+1 |
||
137 | mov [Icon_Y],20+15+4+25+1 |
||
138 | |||
139 | mov eax,8 |
||
140 | mov ebx,[Icon_X] |
||
141 | mov ecx,[Icon_Y] |
||
142 | dec ebx |
||
143 | dec ecx |
||
144 | shl ebx,16 |
||
145 | shl ecx,16 |
||
146 | add ebx,20 |
||
147 | add ecx,21 |
||
148 | mov edx,52 |
||
149 | add edx,1000000000000000000000000000000b |
||
150 | int 0x40 |
||
151 | |||
152 | mov eax,13 |
||
153 | mov ebx,136*65536+20 |
||
154 | mov ecx,65*65536+20 |
||
155 | mov edx,[Color] |
||
156 | int 0x40 |
||
157 | |||
158 | ret |