Rev 3831 | Rev 3983 | Go to most recent revision | Only display areas with differences | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3831 | Rev 3865 | ||
---|---|---|---|
1 | ;***************************************************************************** |
1 | ;***************************************************************************** |
2 | ; Open Dialog - for Kolibri OS |
2 | ; Open Dialog - for Kolibri OS |
3 | ; Copyright (c) 2009-2013, Marat Zakiyanov aka Mario79, aka Mario |
3 | ; Copyright (c) 2009-2013, Marat Zakiyanov aka Mario79, aka Mario |
4 | ; All rights reserved. |
4 | ; All rights reserved. |
5 | ; |
5 | ; |
6 | ; Redistribution and use in source and binary forms, with or without |
6 | ; Redistribution and use in source and binary forms, with or without |
7 | ; modification, are permitted provided that the following conditions are met: |
7 | ; modification, are permitted provided that the following conditions are met: |
8 | ; * Redistributions of source code must retain the above copyright |
8 | ; * Redistributions of source code must retain the above copyright |
9 | ; notice, this list of conditions and the following disclaimer. |
9 | ; notice, this list of conditions and the following disclaimer. |
10 | ; * Redistributions in binary form must reproduce the above copyright |
10 | ; * Redistributions in binary form must reproduce the above copyright |
11 | ; notice, this list of conditions and the following disclaimer in the |
11 | ; notice, this list of conditions and the following disclaimer in the |
12 | ; documentation and/or other materials provided with the distribution. |
12 | ; documentation and/or other materials provided with the distribution. |
13 | ; * Neither the name of the |
13 | ; * Neither the name of the |
14 | ; names of its contributors may be used to endorse or promote products |
14 | ; names of its contributors may be used to endorse or promote products |
15 | ; derived from this software without specific prior written permission. |
15 | ; derived from this software without specific prior written permission. |
16 | ; |
16 | ; |
17 | ; THIS SOFTWARE IS PROVIDED BY Marat Zakiyanov ''AS IS'' AND ANY |
17 | ; THIS SOFTWARE IS PROVIDED BY Marat Zakiyanov ''AS IS'' AND ANY |
18 | ; EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
18 | ; EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
19 | ; WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
19 | ; WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
20 | ; DISCLAIMED. IN NO EVENT SHALL |
20 | ; DISCLAIMED. IN NO EVENT SHALL |
21 | ; DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES |
21 | ; DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES |
22 | ; (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
22 | ; (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
23 | ; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
23 | ; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
24 | ; ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
24 | ; ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
25 | ; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
25 | ; (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
26 | ; SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 | ; SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
27 | ;***************************************************************************** |
27 | ;***************************************************************************** |
28 | ;--------------------------------------------------------------------- |
28 | ;--------------------------------------------------------------------- |
29 | ;Some documentation for memory |
29 | ;Some documentation for memory |
30 | ; |
30 | ; |
31 | ;area name db 'FFFFFFFF_open_dialog',0 ; FFFFFFFF = PID |
31 | ;area name db 'FFFFFFFF_open_dialog',0 ; FFFFFFFF = PID |
32 | ; |
32 | ; |
33 | ; communication area data |
33 | ; communication area data |
34 | ; flag ; +0 |
34 | ; flag ; +0 |
35 | ; dw 0 ; 0 - empty, 1 - file for open, 2 -folder for open, |
35 | ; dw 0 ; 0 - empty, 1 - file for open, 2 -folder for open, |
36 | ; 3 - cancel, 4 - path=name of area 6822. |
36 | ; 3 - cancel, 4 - path=name of area 6822. |
37 | ; |
37 | ; |
38 | ; type of dialog: 0-Open, 1-Save, 2-Dir |
38 | ; type of dialog: 0-Open, 1-Save, 2-Dir |
39 | ; dw 0 ; +2 |
39 | ; dw 0 ; +2 |
40 | ; |
40 | ; |
41 | ; window X size ; +4 |
41 | ; window X size ; +4 |
42 | ; dw 0 |
42 | ; dw 0 |
43 | ; |
43 | ; |
44 | ; window X position ; +6 |
44 | ; window X position ; +6 |
45 | ; dw 0 |
45 | ; dw 0 |
46 | ; |
46 | ; |
47 | ; window y size ; +8 |
47 | ; window y size ; +8 |
48 | ; dw 0 |
48 | ; dw 0 |
49 | ; |
49 | ; |
50 | ; window Y position ; +10 |
50 | ; window Y position ; +10 |
51 | ; dw 0 |
51 | ; dw 0 |
52 | ; |
52 | ; |
53 | ; OpenDialog WINDOW SLOT ; +12 |
53 | ; OpenDialog WINDOW SLOT ; +12 |
54 | ; dd 0 |
54 | ; dd 0 |
55 | ; |
55 | ; |
56 | ; file_path ; +16 |
56 | ; file_path ; +16 |
57 | ; rb 3824 ; path to file |
57 | ; rb 3824 ; path to file |
58 | ; |
58 | ; |
59 | ; file name ; +3840 |
59 | ; file name ; +3840 |
60 | ; rb 256 |
60 | ; rb 256 |
61 | ; |
61 | ; |
62 | ; filtration flag ; +4096 |
62 | ; filtration flag ; +4096 |
63 | ; dd 0 ; flag 0 - no filtration, 1 - filtering |
63 | ; dd 0 ; flag 0 - no filtration, 1 - filtering |
64 | ; |
64 | ; |
65 | ; area for storage of filtering values ; +4100 |
65 | ; area for storage of filtering values ; +4100 |
66 | ; rb 4092 |
66 | ; rb 4092 |
67 | ;--------------------------------------------------------------------- |
67 | ;--------------------------------------------------------------------- |
68 | use32 |
68 | use32 |
69 | org 0x0 |
69 | org 0x0 |
70 | 70 | ||
71 | db 'MENUET01' |
71 | db 'MENUET01' |
72 | dd 0x01 |
72 | dd 0x01 |
73 | dd START |
73 | dd START |
74 | dd IM_END |
74 | dd IM_END |
75 | dd I_END |
75 | dd I_END |
76 | dd stacktop |
76 | dd stacktop |
77 | dd param |
77 | dd param |
78 | dd path |
78 | dd path |
79 | 79 | ||
80 | include '../../macros.inc' |
80 | include '../../macros.inc' |
- | 81 | ;include '../../debug.inc' |
|
81 | include '../../develop/libraries/box_lib/load_lib.mac' |
82 | include '../../develop/libraries/box_lib/load_lib.mac' |
82 | include '../../develop/libraries/box_lib/trunk/box_lib.mac' |
83 | include '../../develop/libraries/box_lib/trunk/box_lib.mac' |
83 | ;include 'macros.inc' |
84 | ;include 'macros.inc' |
84 | ;include 'load_lib.mac' |
85 | ;include 'load_lib.mac' |
85 | ;include 'box_lib.mac' |
86 | ;include 'box_lib.mac' |
86 | @use_library |
87 | @use_library |
87 | 88 | ||
88 | x_minimal_size equ 350 |
89 | x_minimal_size equ 350 |
89 | y_minimal_size equ 250 |
90 | y_minimal_size equ 250 |
90 | ;--------------------------------------------------------------------- |
91 | ;--------------------------------------------------------------------- |
91 | ;--------------------------------------------------------------------- |
92 | ;--------------------------------------------------------------------- |
92 | START: |
93 | START: |
93 | mcall 68,11 |
94 | mcall 68,11 |
94 | mcall 66,1,1 |
95 | mcall 66,1,1 |
95 | mcall 40,0x27 |
96 | mcall 40,0x27 |
96 | call get_communication_area |
97 | call get_communication_area |
97 | 98 | ||
98 | call get_active_pocess |
99 | call get_active_pocess |
99 | 100 | ||
100 | load_libraries l_libs_start,end_l_libs |
101 | load_libraries l_libs_start,end_l_libs |
101 | test eax,eax |
102 | test eax,eax |
102 | jnz button.exit |
103 | jnz button.exit |
103 | ; initialize sort |
104 | ; initialize sort |
104 | push dword 1 |
105 | push dword 1 |
105 | call dword [sort_init] |
106 | call dword [sort_init] |
106 | ; unpack deflate |
107 | ; unpack deflate |
107 | mov eax,[unpack_DeflateUnpack2] |
108 | mov eax,[unpack_DeflateUnpack2] |
108 | mov [deflate_unpack],eax |
109 | mov [deflate_unpack],eax |
109 | 110 | ||
110 | mov esi,start_pach |
111 | mov esi,start_pach |
111 | mov edi,previous_dir_path |
112 | mov edi,previous_dir_path |
112 | call copy_dir_name.1 |
113 | call copy_dir_name.1 |
113 | 114 | ||
114 | call load_root_directory |
115 | call load_root_directory |
115 | call load_start_directory |
116 | call load_start_directory |
116 | call sort_directory |
117 | call sort_directory |
117 | call load_icons |
118 | call load_icons |
118 | call convert_icons |
119 | call convert_icons |
119 | call load_ini |
120 | call load_ini |
120 | call calc_ini |
121 | call calc_ini |
121 | jmp red_1 |
122 | jmp red_1 |
122 | ;--------------------------------------------------------------------- |
123 | ;--------------------------------------------------------------------- |
123 | red: |
124 | red: |
124 | call control_minimal_window_size |
125 | call control_minimal_window_size |
125 | red_1: |
126 | red_1: |
126 | call draw_window |
127 | call draw_window |
127 | ;--------------------------------------------------------------------- |
128 | ;--------------------------------------------------------------------- |
128 | still: |
129 | still: |
129 | mcall 10 |
130 | mcall 10 |
130 | cmp eax,1 |
131 | cmp eax,1 |
131 | je red |
132 | je red |
132 | cmp eax,2 |
133 | cmp eax,2 |
133 | je key |
134 | je key |
134 | cmp eax,3 |
135 | cmp eax,3 |
135 | je button |
136 | je button |
136 | cmp eax,6 |
137 | cmp eax,6 |
137 | je mouse |
138 | je mouse |
138 | jmp still |
139 | jmp still |
139 | ;--------------------------------------------------------------------- |
140 | ;--------------------------------------------------------------------- |
140 | control_minimal_window_size: |
141 | control_minimal_window_size: |
141 | pusha |
142 | pusha |
142 | call get_window_param |
143 | call get_window_param |
143 | test [window_status],10b |
144 | test [window_status],10b |
144 | jnz .end ;red_1 |
145 | jnz .end ;red_1 |
145 | test [window_status],100b |
146 | test [window_status],100b |
146 | jnz .end ;red_1 |
147 | jnz .end ;red_1 |
147 | test [window_status],1b |
148 | test [window_status],1b |
148 | jnz .end ;red_1 |
149 | jnz .end ;red_1 |
149 | mov esi,-1 |
150 | mov esi,-1 |
150 | mov eax,procinfo |
151 | mov eax,procinfo |
151 | mov eax,[eax+46] |
152 | mov eax,[eax+46] |
152 | cmp eax,dword y_minimal_size ;200 |
153 | cmp eax,dword y_minimal_size ;200 |
153 | jae @f |
154 | jae @f |
154 | mov esi,dword y_minimal_size ;200 |
155 | mov esi,dword y_minimal_size ;200 |
155 | mcall 67,-1,ebx,ebx |
156 | mcall 67,-1,ebx,ebx |
156 | @@: |
157 | @@: |
157 | mov edx,-1 |
158 | mov edx,-1 |
158 | mov eax,procinfo |
159 | mov eax,procinfo |
159 | mov eax,[eax+42] |
160 | mov eax,[eax+42] |
160 | cmp eax,dword x_minimal_size ;300 |
161 | cmp eax,dword x_minimal_size ;300 |
161 | jae @f |
162 | jae @f |
162 | mov edx,dword x_minimal_size ;300 |
163 | mov edx,dword x_minimal_size ;300 |
163 | mcall 67,-1,ebx,,ebx |
164 | mcall 67,-1,ebx,,ebx |
164 | @@: |
165 | @@: |
165 | .end: |
166 | .end: |
166 | popa |
167 | popa |
167 | ret |
168 | ret |
168 | ;--------------------------------------------------------------------- |
169 | ;--------------------------------------------------------------------- |
169 | key: |
170 | key: |
170 | mov al,[focus_pointer] |
171 | mov al,[focus_pointer] |
171 | test al,al |
172 | test al,al |
172 | jne key_ASCII |
173 | jne key_ASCII |
173 | mcall 2 |
174 | mcall 2 |
174 | xor ebx,ebx |
175 | xor ebx,ebx |
175 | cmp [extended_key],1 |
176 | cmp [extended_key],1 |
176 | je .extended_key |
177 | je .extended_key |
177 | test al,al |
178 | test al,al |
178 | jnz still |
179 | jnz still |
179 | cmp ah,0xE0 |
180 | cmp ah,0xE0 |
180 | jne @f |
181 | jne @f |
181 | mov [extended_key],1 |
182 | mov [extended_key],1 |
182 | jmp still |
183 | jmp still |
183 | @@: |
184 | @@: |
184 | cmp ah,72 ; arrow up |
185 | cmp ah,72 ; arrow up |
185 | je .2 |
186 | je .2 |
186 | cmp ah,80 ; arrow down |
187 | cmp ah,80 ; arrow down |
187 | je .1 |
188 | je .1 |
188 | cmp ah,28 ; Enter |
189 | cmp ah,28 ; Enter |
189 | je .7 |
190 | je .7 |
190 | cmp ah,1 ; Esc |
191 | cmp ah,1 ; Esc |
191 | je button.exit |
192 | je button.exit |
192 | cmp ah,14 ; Backspace |
193 | cmp ah,14 ; Backspace |
193 | je button.exit_dir |
194 | je button.exit_dir |
194 | cmp ah,187 ; F1 |
195 | cmp ah,187 ; F1 |
195 | je select_disk |
196 | je select_disk |
196 | cmp ah,188 ; F2 |
197 | cmp ah,188 ; F2 |
197 | je select_sort |
198 | je select_sort |
198 | cmp ah,189 ; F3 |
199 | cmp ah,189 ; F3 |
199 | je select_filter |
200 | je select_filter |
200 | cmp ah,19 ; R |
201 | cmp ah,19 ; R |
201 | je button.reload_dir |
202 | je button.reload_dir |
202 | cmp ah,42 |
203 | cmp ah,42 |
203 | je key_shift_up |
204 | je key_shift_up |
204 | cmp ah,54 |
205 | cmp ah,54 |
205 | je key_shift_up |
206 | je key_shift_up |
206 | cmp ah,170 |
207 | cmp ah,170 |
207 | je key_shift_down |
208 | je key_shift_down |
208 | cmp ah,182 |
209 | cmp ah,182 |
209 | je key_shift_down |
210 | je key_shift_down |
210 | cmp ah,29 |
211 | cmp ah,29 |
211 | je key_ctrl_up |
212 | je key_ctrl_up |
212 | cmp ah,157 |
213 | cmp ah,157 |
213 | je key_ctrl_down |
214 | je key_ctrl_down |
214 | cmp ah,56 |
215 | cmp ah,56 |
215 | je key_alt_up |
216 | je key_alt_up |
216 | cmp ah,184 |
217 | cmp ah,184 |
217 | je key_alt_down |
218 | je key_alt_down |
218 | cmp ah,206 ; NumPad+ Up |
219 | cmp ah,206 ; NumPad+ Up |
219 | je NumPad_plus_Up |
220 | je NumPad_plus_Up |
220 | cmp ah,202 ; NumPad- Up |
221 | cmp ah,202 ; NumPad- Up |
221 | je NumPad_minus_Up |
222 | je NumPad_minus_Up |
222 | cmp ah,183 ; NumPad* Up |
223 | cmp ah,183 ; NumPad* Up |
223 | je NumPad_invert_Up |
224 | je NumPad_invert_Up |
224 | cmp ah,158 |
225 | cmp ah,158 |
225 | je symbol_a_up |
226 | je symbol_a_up |
226 | cmp ah,15 ; Tab down |
227 | cmp ah,15 ; Tab down |
227 | je change_focus_area_press_Tab_key |
228 | je change_focus_area_press_Tab_key |
228 | cmp ah,143 ; Tab up |
229 | cmp ah,143 ; Tab up |
229 | je change_focus_area_check_Tab_key |
230 | je change_focus_area_check_Tab_key |
230 | ; compare for "1,2,3,4,5,6,7,8,9,0,(-),(=)" |
231 | ; compare for "1,2,3,4,5,6,7,8,9,0,(-),(=)" |
231 | cmp ah,2 |
232 | cmp ah,2 |
232 | jb still |
233 | jb still |
233 | cmp ah,13 |
234 | cmp ah,13 |
234 | jbe .12 |
235 | jbe .12 |
235 | ; compare for "q,w,e,r,t,y,u,i,o,p,([),(])" |
236 | ; compare for "q,w,e,r,t,y,u,i,o,p,([),(])" |
236 | cmp ah,16 |
237 | cmp ah,16 |
237 | jb still |
238 | jb still |
238 | cmp ah,27 |
239 | cmp ah,27 |
239 | jbe .12 |
240 | jbe .12 |
240 | ; compare for "a,s,d,f,g,h,j,k,l,(;),('),(`)" |
241 | ; compare for "a,s,d,f,g,h,j,k,l,(;),('),(`)" |
241 | cmp ah,30 |
242 | cmp ah,30 |
242 | jb still |
243 | jb still |
243 | cmp ah,41 |
244 | cmp ah,41 |
244 | jbe .12 |
245 | jbe .12 |
245 | ; compare for "(\),z,x,c,v,b,n,m,(,),(.),(/)" |
246 | ; compare for "(\),z,x,c,v,b,n,m,(,),(.),(/)" |
246 | cmp ah,43 |
247 | cmp ah,43 |
247 | jb still |
248 | jb still |
248 | cmp ah,53 |
249 | cmp ah,53 |
249 | jbe .12 |
250 | jbe .12 |
250 | jmp still |
251 | jmp still |
251 | .extended_key: |
252 | .extended_key: |
252 | mov [extended_key],0 |
253 | mov [extended_key],0 |
253 | cmp ah,80 ; arrow down |
254 | cmp ah,80 ; arrow down |
254 | je .1 |
255 | je .1 |
255 | cmp ah,72 ; arrow up |
256 | cmp ah,72 ; arrow up |
256 | je .2 |
257 | je .2 |
257 | cmp ah,81 ; PageDown |
258 | cmp ah,81 ; PageDown |
258 | je .3 |
259 | je .3 |
259 | cmp ah,73 ; PageUp |
260 | cmp ah,73 ; PageUp |
260 | je .4 |
261 | je .4 |
261 | cmp ah,71 ; Home |
262 | cmp ah,71 ; Home |
262 | je .5 |
263 | je .5 |
263 | cmp ah,79 ; End |
264 | cmp ah,79 ; End |
264 | je .6 |
265 | je .6 |
265 | cmp ah,28 ; Enter |
266 | cmp ah,28 ; Enter |
266 | je .7 |
267 | je .7 |
267 | cmp ah,82 ; Insert |
268 | cmp ah,82 ; Insert |
268 | je .8 |
269 | je .8 |
269 | 270 | ||
270 | cmp ah,29 |
271 | cmp ah,29 |
271 | je key_ctrl_up |
272 | je key_ctrl_up |
272 | cmp ah,157 |
273 | cmp ah,157 |
273 | je key_ctrl_down |
274 | je key_ctrl_down |
274 | cmp ah,56 |
275 | cmp ah,56 |
275 | je key_alt_up |
276 | je key_alt_up |
276 | cmp ah,184 |
277 | cmp ah,184 |
277 | je key_alt_down |
278 | je key_alt_down |
278 | jmp still |
279 | jmp still |
279 | ;--------------------------------- |
280 | ;--------------------------------- |
280 | .12: |
281 | .12: |
281 | inc ebx ; 12 - Search with key |
282 | inc ebx ; 12 - Search with key |
282 | ;--------------------------------- |
283 | ;--------------------------------- |
283 | .11: |
284 | .11: |
284 | inc ebx ; 11 - Invert Mark |
285 | inc ebx ; 11 - Invert Mark |
285 | ;--------------------------------- |
286 | ;--------------------------------- |
286 | .10: |
287 | .10: |
287 | inc ebx ; 10 - Unmark All |
288 | inc ebx ; 10 - Unmark All |
288 | ;--------------------------------- |
289 | ;--------------------------------- |
289 | .9: |
290 | .9: |
290 | inc ebx ; 9 - Mark All |
291 | inc ebx ; 9 - Mark All |
291 | ;--------------------------------- |
292 | ;--------------------------------- |
292 | .8: |
293 | .8: |
293 | inc ebx ; 8 - Insert (Mark) |
294 | inc ebx ; 8 - Insert (Mark) |
294 | ;--------------------------------- |
295 | ;--------------------------------- |
295 | .7: |
296 | .7: |
296 | inc ebx ; 7 - Enter |
297 | inc ebx ; 7 - Enter |
297 | ;--------------------------------- |
298 | ;--------------------------------- |
298 | .6: |
299 | .6: |
299 | inc ebx ; 6 - End |
300 | inc ebx ; 6 - End |
300 | ;--------------------------------- |
301 | ;--------------------------------- |
301 | .5: |
302 | .5: |
302 | inc ebx ; 5 - Home |
303 | inc ebx ; 5 - Home |
303 | ;--------------------------------- |
304 | ;--------------------------------- |
304 | .4: |
305 | .4: |
305 | inc ebx ; 4 - PageUp |
306 | inc ebx ; 4 - PageUp |
306 | ;--------------------------------- |
307 | ;--------------------------------- |
307 | .3: |
308 | .3: |
308 | inc ebx ; 3 - PageDown |
309 | inc ebx ; 3 - PageDown |
309 | ;--------------------------------- |
310 | ;--------------------------------- |
310 | .2: |
311 | .2: |
311 | inc ebx ; 2 - arrow up |
312 | inc ebx ; 2 - arrow up |
312 | ;--------------------------------- |
313 | ;--------------------------------- |
313 | .1: |
314 | .1: |
314 | inc ebx ; 1 - arrow down |
315 | inc ebx ; 1 - arrow down |
315 | ;--------------------------------- |
316 | ;--------------------------------- |
316 | call .key_action |
317 | call .key_action |
317 | 318 | ||
318 | ; movzx ecx,word [file_browser_data_1.start_draw_cursor_line] |
319 | ; movzx ecx,word [file_browser_data_1.start_draw_cursor_line] |
319 | ; mcall 47,0x80000,,<50,0>,0x40000000,0xffffff |
320 | ; mcall 47,0x80000,,<50,0>,0x40000000,0xffffff |
320 | ; movzx ecx,word [file_browser_data_1.size_y] |
321 | ; movzx ecx,word [file_browser_data_1.size_y] |
321 | ; mcall 47,0x80000,,<150,0>,0x40000000,0xffffff |
322 | ; mcall 47,0x80000,,<150,0>,0x40000000,0xffffff |
322 | 323 | ||
323 | mov eax,file_browser_data_1.mouse_keys_delta |
324 | mov eax,file_browser_data_1.mouse_keys_delta |
324 | cmp [eax],dword 3 |
325 | cmp [eax],dword 3 |
325 | jne still |
326 | jne still |
326 | xor ebx,ebx |
327 | xor ebx,ebx |
327 | mov [eax],ebx |
328 | mov [eax],ebx |
328 | call load_next_dir |
329 | call load_next_dir |
329 | jmp still |
330 | jmp still |
330 | ;------------------------------------------------------- |
331 | ;------------------------------------------------------- |
331 | .key_action: |
332 | .key_action: |
332 | mov [file_browser_data_1.key_action],bx |
333 | mov [file_browser_data_1.key_action],bx |
333 | shr ax,8 |
334 | shr ax,8 |
334 | mov [file_browser_data_1.key_action_num],ax |
335 | mov [file_browser_data_1.key_action_num],ax |
335 | 336 | ||
336 | push dword file_browser_data_1 |
337 | push dword file_browser_data_1 |
337 | call [FileBrowser_key] |
338 | call [FileBrowser_key] |
338 | 339 | ||
339 | call draw_open_button_label |
340 | call draw_open_button_label |
340 | 341 | ||
341 | cmp [file_browser_data_1.draw_scroll_bar],0 |
342 | cmp [file_browser_data_1.draw_scroll_bar],0 |
342 | je @f |
343 | je @f |
343 | call draw_scrollbar1 |
344 | call draw_scrollbar1 |
344 | mov [file_browser_data_1.draw_scroll_bar],0 |
345 | mov [file_browser_data_1.draw_scroll_bar],0 |
345 | @@: |
346 | @@: |
346 | ret |
347 | ret |
347 | ;--------------------------------------------------------------------- |
348 | ;--------------------------------------------------------------------- |
348 | change_focus_area_Tab_key_ASCII: |
349 | change_focus_area_Tab_key_ASCII: |
349 | xor eax,eax |
350 | xor eax,eax |
350 | inc eax |
351 | inc eax |
351 | mov [Tab_key_block],al |
352 | mov [Tab_key_block],al |
352 | jmp change_focus_area |
353 | jmp change_focus_area |
353 | ;--------------------------------------------------------------------- |
354 | ;--------------------------------------------------------------------- |
354 | change_focus_area_press_Tab_key: |
355 | change_focus_area_press_Tab_key: |
355 | cmp [open_dialog_type],1 |
356 | cmp [open_dialog_type],1 |
356 | jne still |
357 | jne still |
357 | mov al,[Tab_key_block] |
358 | mov al,[Tab_key_block] |
358 | test al,al |
359 | test al,al |
359 | jnz still |
360 | jnz still |
360 | xor eax,eax |
361 | xor eax,eax |
361 | inc eax |
362 | inc eax |
362 | mov [Tab_key],al |
363 | mov [Tab_key],al |
363 | jmp still |
364 | jmp still |
364 | ;--------------------------------------------------------------------- |
365 | ;--------------------------------------------------------------------- |
365 | change_focus_area_check_Tab_key: |
366 | change_focus_area_check_Tab_key: |
366 | cmp [open_dialog_type],1 |
367 | cmp [open_dialog_type],1 |
367 | jne still |
368 | jne still |
368 | xor eax,eax |
369 | xor eax,eax |
369 | mov [Tab_key_block],al |
370 | mov [Tab_key_block],al |
370 | mov al,[Tab_key] |
371 | mov al,[Tab_key] |
371 | test al,al |
372 | test al,al |
372 | jz still |
373 | jz still |
373 | xor eax,eax |
374 | xor eax,eax |
374 | mov [Tab_key],al |
375 | mov [Tab_key],al |
375 | ;--------------------------------------------------------------------- |
376 | ;--------------------------------------------------------------------- |
376 | change_focus_area: |
377 | change_focus_area: |
377 | mov al,[focus_pointer] |
378 | mov al,[focus_pointer] |
378 | inc al |
379 | inc al |
379 | and al,1 |
380 | and al,1 |
380 | mov [focus_pointer],al |
381 | mov [focus_pointer],al |
381 | .1: |
382 | .1: |
382 | mov edi,edit1 |
383 | mov edi,edit1 |
383 | test al,al |
384 | test al,al |
384 | jne @f |
385 | jne @f |
385 | mov [file_browser_data_1.select_panel_counter],1 |
386 | mov [file_browser_data_1.select_panel_counter],1 |
386 | and [edi+44],dword 0xFFFFFFFD ; ed_focus |
387 | and [edi+44],dword 0xFFFFFFFD ; ed_focus |
387 | mov [edi+12],dword 0xffffff ; color white |
388 | mov [edi+12],dword 0xffffff ; color white |
388 | call draw_draw_file_browser1 |
389 | call draw_draw_file_browser1 |
389 | mcall 66,1,1 |
390 | mcall 66,1,1 |
390 | jmp still |
391 | jmp still |
391 | @@: |
392 | @@: |
392 | mov [file_browser_data_1.select_panel_counter],0 |
393 | mov [file_browser_data_1.select_panel_counter],0 |
393 | or [edi+44],dword ed_focus |
394 | or [edi+44],dword ed_focus |
394 | mov [edi+12],dword 0xffffb0 ; color yellow |
395 | mov [edi+12],dword 0xffffb0 ; color yellow |
395 | call draw_draw_file_browser1 |
396 | call draw_draw_file_browser1 |
396 | mcall 66,1,0 |
397 | mcall 66,1,0 |
397 | jmp still |
398 | jmp still |
398 | ;--------------------------------------------------------------------- |
399 | ;--------------------------------------------------------------------- |
399 | key_ASCII: |
400 | key_ASCII: |
400 | mcall 2 |
401 | mcall 2 |
401 | cmp ah,9 |
402 | cmp ah,9 |
402 | je change_focus_area_Tab_key_ASCII |
403 | je change_focus_area_Tab_key_ASCII |
403 | cmp ah,13 |
404 | cmp ah,13 |
404 | je .13 |
405 | je .13 |
405 | cmp ah,27 |
406 | cmp ah,27 |
406 | je button.exit |
407 | je button.exit |
407 | push dword name_editboxes |
408 | push dword name_editboxes |
408 | call [edit_box_key] |
409 | call [edit_box_key] |
409 | jmp still |
410 | jmp still |
410 | .13: |
411 | .13: |
411 | ; cmp [open_dialog_type],2 ; Select dir |
412 | ; cmp [open_dialog_type],2 ; Select dir |
412 | ; je file_no_folder |
413 | ; je file_no_folder |
413 | ; cmp [open_dialog_type],1 ; Save file |
414 | ; cmp [open_dialog_type],1 ; Save file |
414 | ; jne user_selected_name_action ; load_dir |
415 | ; jne user_selected_name_action ; load_dir |
415 | ; inc [open_dialog_type] |
416 | ; inc [open_dialog_type] |
416 | jmp file_no_folder |
417 | jmp file_no_folder |
417 | ;.load_dir: |
418 | ;.load_dir: |
418 | ; mov [file_browser_data_1.select_panel_counter],1 |
419 | ; mov [file_browser_data_1.select_panel_counter],1 |
419 | ; xor eax,eax |
420 | ; xor eax,eax |
420 | ; mov [focus_pointer],al |
421 | ; mov [focus_pointer],al |
421 | ; mcall 66,1,1 |
422 | ; mcall 66,1,1 |
422 | 423 | ||
423 | ; xor eax,eax |
424 | ; xor eax,eax |
424 | ; mov esi,dir_path |
425 | ; mov esi,dir_path |
425 | ; cld |
426 | ; cld |
426 | ;@@: |
427 | ;@@: |
427 | ; lodsb |
428 | ; lodsb |
428 | ; test al,al |
429 | ; test al,al |
429 | ; jne @r |
430 | ; jne @r |
430 | ; sub esi,2 |
431 | ; sub esi,2 |
431 | ; cmp [esi],byte '/' |
432 | ; cmp [esi],byte '/' |
432 | ; jne @f |
433 | ; jne @f |
433 | ; xor eax,eax |
434 | ; xor eax,eax |
434 | ; mov [esi],al |
435 | ; mov [esi],al |
435 | ;@@: |
436 | ;@@: |
436 | ; call load_next_dir.1 |
437 | ; call load_next_dir.1 |
437 | ; jmp still |
438 | ; jmp still |
438 | ;--------------------------------------------------------------------- |
439 | ;--------------------------------------------------------------------- |
439 | user_selected_name_action: |
440 | user_selected_name_action: |
440 | mov eax,[communication_area] |
441 | mov eax,[communication_area] |
441 | test eax,eax |
442 | test eax,eax |
442 | jnz @f |
443 | jnz @f |
443 | call control_minimal_window_size |
444 | call control_minimal_window_size |
444 | call draw_window |
445 | call draw_window |
445 | ret |
446 | ret |
446 | @@: |
447 | @@: |
447 | add eax,16 ;12 |
448 | add eax,16 ;12 |
448 | ;copy_path user_selected_name,dir_path,eax,0 |
449 | ;copy_path user_selected_name,dir_path,eax,0 |
449 | mov esi,dir_path |
450 | mov esi,dir_path |
450 | mov edi,eax |
451 | mov edi,eax |
451 | call copy_dir_name |
452 | call copy_dir_name |
452 | mov [edi-1],byte '/' |
453 | mov [edi-1],byte '/' |
453 | mov esi,user_selected_name |
454 | mov esi,user_selected_name |
454 | call copy_dir_name |
455 | call copy_dir_name |
455 | 456 | ||
456 | mov eax,[communication_area] |
457 | mov eax,[communication_area] |
457 | mov [eax],word 1 |
458 | mov [eax],word 1 |
458 | jmp button.exit |
459 | jmp button.exit |
459 | ;--------------------------------------------------------------------- |
460 | ;--------------------------------------------------------------------- |
460 | select_disk: |
461 | select_disk: |
461 | call check_alt |
462 | call check_alt |
462 | .1: |
463 | .1: |
463 | call load_root_directory |
464 | call load_root_directory |
464 | xor eax,eax |
465 | xor eax,eax |
465 | mov [menu_data_1.ret_key],eax |
466 | mov [menu_data_1.ret_key],eax |
466 | 467 | ||
467 | push dword menu_data_1 |
468 | push dword menu_data_1 |
468 | call [menu_bar_activate] |
469 | call [menu_bar_activate] |
469 | 470 | ||
470 | call clear_control_key_flag |
471 | call clear_control_key_flag |
471 | 472 | ||
472 | mov eax,[menu_data_1.ret_key] |
473 | mov eax,[menu_data_1.ret_key] |
473 | mov [menu_data_1.ret_key],dword 0 |
474 | mov [menu_data_1.ret_key],dword 0 |
474 | cmp eax,1 |
475 | cmp eax,1 |
475 | je select_filter.1 |
476 | je select_filter.1 |
476 | 477 | ||
477 | cmp eax,2 |
478 | cmp eax,2 |
478 | je select_sort.1 |
479 | je select_sort.1 |
479 | 480 | ||
480 | cmp [menu_data_1.click],dword 1 |
481 | cmp [menu_data_1.click],dword 1 |
481 | jne still |
482 | jne still |
482 | 483 | ||
483 | cmp [menu_data_1.cursor_out],dword 0 |
484 | cmp [menu_data_1.cursor_out],dword 0 |
484 | jne analyse_out_menu_1 |
485 | jne analyse_out_menu_1 |
485 | jmp still |
486 | jmp still |
486 | ;--------------------------------------------------------------------- |
487 | ;--------------------------------------------------------------------- |
487 | select_sort: |
488 | select_sort: |
488 | call check_alt |
489 | call check_alt |
489 | .1: |
490 | .1: |
490 | xor eax,eax |
491 | xor eax,eax |
491 | mov [menu_data_2.ret_key],eax |
492 | mov [menu_data_2.ret_key],eax |
492 | 493 | ||
493 | push dword menu_data_2 |
494 | push dword menu_data_2 |
494 | call [menu_bar_activate] |
495 | call [menu_bar_activate] |
495 | 496 | ||
496 | call clear_control_key_flag |
497 | call clear_control_key_flag |
497 | 498 | ||
498 | mov eax,[menu_data_2.ret_key] |
499 | mov eax,[menu_data_2.ret_key] |
499 | mov [menu_data_2.ret_key],dword 0 |
500 | mov [menu_data_2.ret_key],dword 0 |
500 | cmp eax,1 |
501 | cmp eax,1 |
501 | je select_disk.1 |
502 | je select_disk.1 |
502 | 503 | ||
503 | cmp eax,2 |
504 | cmp eax,2 |
504 | je select_filter.1 |
505 | je select_filter.1 |
505 | 506 | ||
506 | 507 | ||
507 | cmp [menu_data_2.click],dword 1 |
508 | cmp [menu_data_2.click],dword 1 |
508 | jne still |
509 | jne still |
509 | 510 | ||
510 | cmp [menu_data_2.cursor_out],dword 0 |
511 | cmp [menu_data_2.cursor_out],dword 0 |
511 | jne analyse_out_menu_2 |
512 | jne analyse_out_menu_2 |
512 | jmp still |
513 | jmp still |
513 | ;--------------------------------------------------------------------- |
514 | ;--------------------------------------------------------------------- |
514 | select_filter: |
515 | select_filter: |
515 | call check_alt |
516 | call check_alt |
516 | .1: |
517 | .1: |
517 | xor eax,eax |
518 | xor eax,eax |
518 | mov [menu_data_3.ret_key],eax |
519 | mov [menu_data_3.ret_key],eax |
519 | 520 | ||
520 | push dword menu_data_3 |
521 | push dword menu_data_3 |
521 | call [menu_bar_activate] |
522 | call [menu_bar_activate] |
522 | 523 | ||
523 | call clear_control_key_flag |
524 | call clear_control_key_flag |
524 | 525 | ||
525 | mov eax,[menu_data_3.ret_key] |
526 | mov eax,[menu_data_3.ret_key] |
526 | mov [menu_data_3.ret_key],dword 0 |
527 | mov [menu_data_3.ret_key],dword 0 |
527 | cmp eax,1 |
528 | cmp eax,1 |
528 | je select_sort.1 |
529 | je select_sort.1 |
529 | 530 | ||
530 | cmp eax,2 |
531 | cmp eax,2 |
531 | je select_disk.1 |
532 | je select_disk.1 |
532 | 533 | ||
533 | 534 | ||
534 | cmp [menu_data_3.click],dword 1 |
535 | cmp [menu_data_3.click],dword 1 |
535 | jne still |
536 | jne still |
536 | 537 | ||
537 | cmp [menu_data_3.cursor_out],dword 0 |
538 | cmp [menu_data_3.cursor_out],dword 0 |
538 | jne analyse_out_menu_3 |
539 | jne analyse_out_menu_3 |
539 | jmp still |
540 | jmp still |
540 | ;--------------------------------------------------------------------- |
541 | ;--------------------------------------------------------------------- |
541 | symbol_a_up: |
542 | symbol_a_up: |
542 | NumPad_plus_Up: |
543 | NumPad_plus_Up: |
543 | call check_ctrl |
544 | call check_ctrl |
544 | jmp key.9 |
545 | jmp key.9 |
545 | ;--------------------------------------- |
546 | ;--------------------------------------- |
546 | NumPad_minus_Up: |
547 | NumPad_minus_Up: |
547 | call check_ctrl |
548 | call check_ctrl |
548 | jmp key.10 |
549 | jmp key.10 |
549 | ;--------------------------------------- |
550 | ;--------------------------------------- |
550 | NumPad_invert_Up: |
551 | NumPad_invert_Up: |
551 | call check_ctrl |
552 | call check_ctrl |
552 | jmp key.11 |
553 | jmp key.11 |
553 | ;--------------------------------------- |
554 | ;--------------------------------------- |
554 | check_alt: |
555 | check_alt: |
555 | xor eax,eax |
556 | xor eax,eax |
556 | mov al,[alt_flag] |
557 | mov al,[alt_flag] |
557 | test eax,eax |
558 | test eax,eax |
558 | jz @f |
559 | jz @f |
559 | xor ebx,ebx |
560 | xor ebx,ebx |
560 | ret |
561 | ret |
561 | @@: |
562 | @@: |
562 | add esp,4 |
563 | add esp,4 |
563 | jmp still |
564 | jmp still |
564 | ;--------------------------------------- |
565 | ;--------------------------------------- |
565 | check_ctrl: |
566 | check_ctrl: |
566 | xor eax,eax |
567 | xor eax,eax |
567 | mov al,[ctrl_flag] |
568 | mov al,[ctrl_flag] |
568 | test eax,eax |
569 | test eax,eax |
569 | jz @f |
570 | jz @f |
570 | xor ebx,ebx |
571 | xor ebx,ebx |
571 | ret |
572 | ret |
572 | @@: |
573 | @@: |
573 | add esp,4 |
574 | add esp,4 |
574 | jmp still |
575 | jmp still |
575 | ;--------------------------------------------------------------------- |
576 | ;--------------------------------------------------------------------- |
576 | clear_control_key_flag: |
577 | clear_control_key_flag: |
577 | xor eax,eax |
578 | xor eax,eax |
578 | mov [shift_flag],al |
579 | mov [shift_flag],al |
579 | mov [ctrl_flag],al |
580 | mov [ctrl_flag],al |
580 | mov [alt_flag],al |
581 | mov [alt_flag],al |
581 | ret |
582 | ret |
582 | ;--------------------------------------------------------------------- |
583 | ;--------------------------------------------------------------------- |
583 | key_shift_up: |
584 | key_shift_up: |
584 | mov [shift_flag],1 |
585 | mov [shift_flag],1 |
585 | jmp still |
586 | jmp still |
586 | ;--------------------------------------------------------------------- |
587 | ;--------------------------------------------------------------------- |
587 | key_shift_down: |
588 | key_shift_down: |
588 | mov [shift_flag],0 |
589 | mov [shift_flag],0 |
589 | jmp still |
590 | jmp still |
590 | ;--------------------------------------------------------------------- |
591 | ;--------------------------------------------------------------------- |
591 | key_ctrl_up: |
592 | key_ctrl_up: |
592 | mov [ctrl_flag],1 |
593 | mov [ctrl_flag],1 |
593 | jmp still |
594 | jmp still |
594 | ;--------------------------------------------------------------------- |
595 | ;--------------------------------------------------------------------- |
595 | key_ctrl_down: |
596 | key_ctrl_down: |
596 | mov [ctrl_flag],0 |
597 | mov [ctrl_flag],0 |
597 | jmp still |
598 | jmp still |
598 | ;--------------------------------------------------------------------- |
599 | ;--------------------------------------------------------------------- |
599 | key_alt_up: |
600 | key_alt_up: |
600 | mov [alt_flag],1 |
601 | mov [alt_flag],1 |
601 | jmp still |
602 | jmp still |
602 | ;--------------------------------------------------------------------- |
603 | ;--------------------------------------------------------------------- |
603 | key_alt_down: |
604 | key_alt_down: |
604 | mov [alt_flag],0 |
605 | mov [alt_flag],0 |
605 | jmp still |
606 | jmp still |
606 | ;--------------------------------------------------------------------- |
607 | ;--------------------------------------------------------------------- |
607 | button: |
608 | button: |
608 | mcall 17 |
609 | mcall 17 |
609 | cmp ah,6 |
610 | cmp ah,6 |
610 | je .reload_dir_1 |
611 | je .reload_dir_1 |
611 | cmp ah,4 |
612 | cmp ah,4 |
612 | je .open_dir_or_file |
613 | je .open_dir_or_file |
613 | cmp ah,3 |
614 | cmp ah,3 |
614 | je .exit |
615 | je .exit |
615 | cmp ah,2 |
616 | cmp ah,2 |
616 | je .exit_dir |
617 | je .exit_dir |
617 | cmp ah,1 |
618 | cmp ah,1 |
618 | jne still |
619 | jne still |
619 | .exit: |
620 | .exit: |
620 | mov eax,[communication_area] |
621 | mov eax,[communication_area] |
621 | test eax,eax |
622 | test eax,eax |
622 | jz @f |
623 | jz @f |
623 | cmp [eax],word 1 |
624 | cmp [eax],word 1 |
624 | je @f |
625 | je @f |
625 | mov [eax],word 3 |
626 | mov [eax],word 3 |
626 | @@: |
627 | @@: |
627 | mov eax,[N_error] |
628 | mov eax,[N_error] |
628 | test eax,eax |
629 | test eax,eax |
629 | jz @f |
630 | jz @f |
630 | call start_error_window_thread |
631 | call start_error_window_thread |
631 | @@: |
632 | @@: |
632 | call get_window_param |
633 | call get_window_param |
633 | mov ebx,[communication_area] |
634 | mov ebx,[communication_area] |
634 | mov ecx,procinfo |
635 | mov ecx,procinfo |
635 | ; mov eax,[window_x] |
636 | ; mov eax,[window_x] |
636 | mov eax,[ecx+34] |
637 | mov eax,[ecx+34] |
637 | shl eax,16 |
638 | shl eax,16 |
638 | add eax,[ecx+42] |
639 | add eax,[ecx+42] |
639 | mov [ebx+4],eax |
640 | mov [ebx+4],eax |
640 | ; mov eax,[window_y] |
641 | ; mov eax,[window_y] |
641 | mov eax,[ecx+38] |
642 | mov eax,[ecx+38] |
642 | shl eax,16 |
643 | shl eax,16 |
643 | add eax,[ecx+46] |
644 | add eax,[ecx+46] |
644 | mov [ebx+8],eax |
645 | mov [ebx+8],eax |
645 | 646 | ||
646 | mcall -1 |
647 | mcall -1 |
647 | ;--------------------------------------------------------------------- |
648 | ;--------------------------------------------------------------------- |
648 | .reload_dir: |
649 | .reload_dir: |
649 | cmp [ctrl_flag],bl |
650 | cmp [ctrl_flag],bl |
650 | je key.12 ; Just symbol 'R' or 'r' |
651 | je key.12 ; Just symbol 'R' or 'r' |
651 | .reload_dir_1: |
652 | .reload_dir_1: |
652 | call load_next_dir.1 |
653 | call load_next_dir.1 |
653 | jmp still |
654 | jmp still |
654 | ;--------------------------------------------------------------------- |
655 | ;--------------------------------------------------------------------- |
655 | .exit_dir: |
656 | .exit_dir: |
656 | call load_next_dir.exit_dir |
657 | call load_next_dir.exit_dir |
657 | jmp still |
658 | jmp still |
658 | ;--------------------------------------------------------------------- |
659 | ;--------------------------------------------------------------------- |
659 | .open_dir_or_file: |
660 | .open_dir_or_file: |
660 | cmp [open_dialog_type],2 ;Select dir |
661 | cmp [open_dialog_type],2 ;Select dir |
661 | je file_no_folder |
662 | je file_no_folder |
662 | 663 | ||
663 | cmp [open_dialog_type],1 ;Save file |
664 | cmp [open_dialog_type],1 ;Save file |
664 | jne @f |
665 | jne @f |
665 | mov al,[focus_pointer] |
666 | mov al,[focus_pointer] |
666 | test al,al |
667 | test al,al |
667 | jne file_no_folder |
668 | jne file_no_folder |
668 | @@: |
669 | @@: |
669 | xor ebx,ebx |
670 | xor ebx,ebx |
670 | jmp key.7 |
671 | jmp key.7 |
671 | ;--------------------------------------------------------------------- |
672 | ;--------------------------------------------------------------------- |
672 | thread_start: |
673 | thread_start: |
673 | mov eax,[N_error] |
674 | mov eax,[N_error] |
674 | cmp al,1 |
675 | cmp al,1 |
675 | jne @f |
676 | jne @f |
676 | mov [N_error],load_ini_error_type |
677 | mov [N_error],load_ini_error_type |
677 | mov [error_path],file_name |
678 | mov [error_path],file_name |
678 | jmp .error_type |
679 | jmp .error_type |
679 | @@: |
680 | @@: |
680 | cmp al,2 |
681 | cmp al,2 |
681 | jne @f |
682 | jne @f |
682 | mov [N_error],load_icons_error_type |
683 | mov [N_error],load_icons_error_type |
683 | mov [error_path],file_name |
684 | mov [error_path],file_name |
684 | jmp .error_type |
685 | jmp .error_type |
685 | @@: |
686 | @@: |
686 | cmp al,3 |
687 | cmp al,3 |
687 | jne @f |
688 | jne @f |
688 | mov [N_error],memory_free_error_type |
689 | mov [N_error],memory_free_error_type |
689 | xor eax,eax |
690 | xor eax,eax |
690 | mov [error_path],eax |
691 | mov [error_path],eax |
691 | mov [error_type],eax |
692 | mov [error_type],eax |
692 | jmp .red |
693 | jmp .red |
693 | @@: |
694 | @@: |
694 | cmp al,4 |
695 | cmp al,4 |
695 | jne @f |
696 | jne @f |
696 | mov [N_error],memory_get_error_type |
697 | mov [N_error],memory_get_error_type |
697 | xor eax,eax |
698 | xor eax,eax |
698 | mov [error_path],eax |
699 | mov [error_path],eax |
699 | mov [error_type],eax |
700 | mov [error_type],eax |
700 | jmp .red |
701 | jmp .red |
701 | @@: |
702 | @@: |
702 | cmp al,5 |
703 | cmp al,5 |
703 | jne @f |
704 | jne @f |
704 | mov [N_error],load_directory_error_type |
705 | mov [N_error],load_directory_error_type |
705 | mov [error_path],dir_path |
706 | mov [error_path],dir_path |
706 | jmp .error_type |
707 | jmp .error_type |
707 | @@: |
708 | @@: |
708 | cmp al,6 |
709 | cmp al,6 |
709 | jne .button |
710 | jne .button |
710 | mov [N_error],convert_icons_error_type |
711 | mov [N_error],convert_icons_error_type |
711 | mov [error_path],file_name |
712 | mov [error_path],file_name |
712 | xor eax,eax |
713 | xor eax,eax |
713 | mov [error_type],eax |
714 | mov [error_type],eax |
714 | jmp .red |
715 | jmp .red |
715 | .error_type: |
716 | .error_type: |
716 | mov eax,[error_type] |
717 | mov eax,[error_type] |
717 | shl eax,2 |
718 | shl eax,2 |
718 | add eax,error_fs_text_pointers |
719 | add eax,error_fs_text_pointers |
719 | mov eax,[eax] |
720 | mov eax,[eax] |
720 | mov [error_type],eax |
721 | mov [error_type],eax |
721 | .red: |
722 | .red: |
722 | call draw_error_window |
723 | call draw_error_window |
723 | .still: |
724 | .still: |
724 | mcall 10 |
725 | mcall 10 |
725 | cmp eax,1 |
726 | cmp eax,1 |
726 | je .red |
727 | je .red |
727 | cmp eax,2 |
728 | cmp eax,2 |
728 | je .key |
729 | je .key |
729 | cmp eax,3 |
730 | cmp eax,3 |
730 | je .button |
731 | je .button |
731 | jmp .still |
732 | jmp .still |
732 | .key: |
733 | .key: |
733 | mcall 2 |
734 | mcall 2 |
734 | jmp .still |
735 | jmp .still |
735 | .button: |
736 | .button: |
736 | mcall -1 |
737 | mcall -1 |
737 | jmp .still |
738 | jmp .still |
738 | ;--------------------------------------------------------------------- |
739 | ;--------------------------------------------------------------------- |
739 | draw_error_window: |
740 | draw_error_window: |
740 | mcall 12,1 |
741 | mcall 12,1 |
741 | mcall 0,[error_window_x],[error_window_y],0x03ff0000 |
742 | mcall 0,[error_window_x],[error_window_y],0x03ff0000 |
742 | call type_title |
743 | call type_title |
743 | mcall 4,<10,30>,0x90ffffff,[N_error] |
744 | mcall 4,<10,30>,0x90ffffff,[N_error] |
744 | mov eax,[error_path] |
745 | mov eax,[error_path] |
745 | test eax,eax |
746 | test eax,eax |
746 | jz @f |
747 | jz @f |
747 | mcall 4,<10,50>,,[error_path] |
748 | mcall 4,<10,50>,,[error_path] |
748 | @@: |
749 | @@: |
749 | mov eax,[error_type] |
750 | mov eax,[error_type] |
750 | test eax,eax |
751 | test eax,eax |
751 | jz @f |
752 | jz @f |
752 | mcall 4,<10,70>,,[error_type] |
753 | mcall 4,<10,70>,,[error_type] |
753 | @@: |
754 | @@: |
754 | mcall 12,2 |
755 | mcall 12,2 |
755 | ret |
756 | ret |
756 | ;--------------------------------------------------------------------- |
757 | ;--------------------------------------------------------------------- |
757 | start_error_window_thread: |
758 | start_error_window_thread: |
758 | mcall 9,procinfo,-1 |
759 | mcall 9,procinfo,-1 |
759 | mov eax,[ebx+46] |
760 | mov eax,[ebx+46] |
760 | shr eax,1 |
761 | shr eax,1 |
761 | add eax,[ebx+38] |
762 | add eax,[ebx+38] |
762 | sub eax,40 |
763 | sub eax,40 |
763 | mov [error_window_y+2],ax |
764 | mov [error_window_y+2],ax |
764 | mov eax,[ebx+42] |
765 | mov eax,[ebx+42] |
765 | shr eax,1 |
766 | shr eax,1 |
766 | add eax,[ebx+34] |
767 | add eax,[ebx+34] |
767 | sub eax,125 |
768 | sub eax,125 |
768 | mov [error_window_x+2],ax |
769 | mov [error_window_x+2],ax |
769 | mcall 51,1,thread_start,thread_stack |
770 | mcall 51,1,thread_start,thread_stack |
770 | ret |
771 | ret |
771 | ;--------------------------------------------------------------------- |
772 | ;--------------------------------------------------------------------- |
772 | mouse: |
773 | mouse: |
773 | mcall 18,7 |
774 | mcall 18,7 |
774 | cmp [active_process],eax |
775 | cmp [active_process],eax |
775 | jne still |
776 | jne still |
776 | 777 | ||
777 | mcall 37,7 |
778 | mcall 37,7 |
778 | mov [mouse_scroll_data],eax |
779 | mov [mouse_scroll_data],eax |
779 | 780 | ||
780 | mcall 37,1 |
781 | mcall 37,1 |
781 | mov [mouse_position],eax |
782 | mov [mouse_position],eax |
782 | 783 | ||
783 | cmp [scroll_bar_data_vertical.delta2],0 |
784 | cmp [scroll_bar_data_vertical.delta2],0 |
784 | jne .scrollbar |
785 | jne .scrollbar |
785 | 786 | ||
786 | mov [file_browser_data_1.select_flag],0 |
787 | mov [file_browser_data_1.select_flag],0 |
787 | 788 | ||
788 | push dword file_browser_data_1 |
789 | push dword file_browser_data_1 |
789 | call [FileBrowser_mouse] |
790 | call [FileBrowser_mouse] |
790 | 791 | ||
791 | call draw_open_button_label |
792 | call draw_open_button_label |
792 | 793 | ||
793 | mov eax,file_browser_data_1.mouse_keys_delta |
794 | mov eax,file_browser_data_1.mouse_keys_delta |
794 | cmp [eax],dword 3 |
795 | cmp [eax],dword 3 |
795 | jne .check_focus ; scrollbar |
796 | jne .check_focus ; scrollbar |
796 | mov [eax],dword 0 |
797 | mov [eax],dword 0 |
797 | call load_next_dir |
798 | call load_next_dir |
798 | jmp still |
799 | jmp still |
799 | ;--------------------------------------------------- |
800 | ;--------------------------------------------------- |
800 | .check_focus: |
801 | .check_focus: |
801 | mov ebx,[file_browser_data_1.select_flag] |
802 | mov ebx,[file_browser_data_1.select_flag] |
802 | test ebx,ebx |
803 | test ebx,ebx |
803 | jz .scrollbar ;@f |
804 | jz .scrollbar ;@f |
804 | mov al,[focus_pointer] |
805 | mov al,[focus_pointer] |
805 | test al,al |
806 | test al,al |
806 | jz .scrollbar |
807 | jz .scrollbar |
807 | xor eax,eax |
808 | xor eax,eax |
808 | mov [focus_pointer],al |
809 | mov [focus_pointer],al |
809 | jmp change_focus_area.1 |
810 | jmp change_focus_area.1 |
810 | ;--------------------------------------------------- |
811 | ;--------------------------------------------------- |
811 | .scrollbar: |
812 | .scrollbar: |
812 | mov eax,[scroll_bar_data_vertical.max_area] |
813 | mov eax,[scroll_bar_data_vertical.max_area] |
813 | cmp eax,[scroll_bar_data_vertical.cur_area] |
814 | cmp eax,[scroll_bar_data_vertical.cur_area] |
814 | jbe .menu_bar ;still |
815 | jbe .menu_bar ;still |
815 | 816 | ||
816 | push dword scroll_bar_data_vertical |
817 | push dword scroll_bar_data_vertical |
817 | call [scrollbar_ver_mouse] |
818 | call [scrollbar_ver_mouse] |
818 | 819 | ||
819 | cmp [scroll_bar_data_vertical.redraw],0 |
820 | cmp [scroll_bar_data_vertical.redraw],0 |
820 | je .menu_bar ;still |
821 | je .menu_bar ;still |
821 | mov [scroll_bar_data_vertical.redraw],0 |
822 | mov [scroll_bar_data_vertical.redraw],0 |
822 | .draw: |
823 | .draw: |
823 | call draw_draw_file_browser2 |
824 | call draw_draw_file_browser2 |
824 | jmp still |
825 | jmp still |
825 | 826 | ||
826 | ;--------------------------------------------------- |
827 | ;--------------------------------------------------- |
827 | .menu_bar: |
828 | .menu_bar: |
828 | cmp [scroll_bar_data_vertical.delta2],0 |
829 | cmp [scroll_bar_data_vertical.delta2],0 |
829 | jne still |
830 | jne still |
830 | 831 | ||
831 | .menu_bar_1: |
832 | .menu_bar_1: |
832 | call .set_mouse_flag |
833 | call .set_mouse_flag |
833 | @@: |
834 | @@: |
834 | push dword menu_data_1 |
835 | push dword menu_data_1 |
835 | call [menu_bar_mouse] |
836 | call [menu_bar_mouse] |
836 | 837 | ||
837 | cmp [menu_data_1.click],dword 1 |
838 | cmp [menu_data_1.click],dword 1 |
838 | jne .menu_bar_2 |
839 | jne .menu_bar_2 |
839 | 840 | ||
840 | cmp [menu_data_1.cursor_out],dword 0 |
841 | cmp [menu_data_1.cursor_out],dword 0 |
841 | jne select_disk.1 ;analyse_out_menu_1 |
842 | jne select_disk.1 ;analyse_out_menu_1 |
842 | jmp .menu_bar_1 |
843 | jmp .menu_bar_1 |
843 | ;-------------------------------------------- |
844 | ;-------------------------------------------- |
844 | .menu_bar_2: |
845 | .menu_bar_2: |
845 | push dword menu_data_2 |
846 | push dword menu_data_2 |
846 | call [menu_bar_mouse] |
847 | call [menu_bar_mouse] |
847 | 848 | ||
848 | cmp [menu_data_2.click],dword 1 |
849 | cmp [menu_data_2.click],dword 1 |
849 | jne .menu_bar_3 |
850 | jne .menu_bar_3 |
850 | 851 | ||
851 | cmp [menu_data_2.cursor_out],dword 0 |
852 | cmp [menu_data_2.cursor_out],dword 0 |
852 | jne analyse_out_menu_2 |
853 | jne analyse_out_menu_2 |
853 | jmp .menu_bar_1 |
854 | jmp .menu_bar_1 |
854 | ;--------------------------------------------------- |
855 | ;--------------------------------------------------- |
855 | .menu_bar_3: |
856 | .menu_bar_3: |
856 | push dword menu_data_3 |
857 | push dword menu_data_3 |
857 | call [menu_bar_mouse] |
858 | call [menu_bar_mouse] |
858 | 859 | ||
859 | cmp [menu_data_3.click],dword 1 |
860 | cmp [menu_data_3.click],dword 1 |
860 | jne .check_editboxes |
861 | jne .check_editboxes |
861 | 862 | ||
862 | cmp [menu_data_3.cursor_out],dword 0 |
863 | cmp [menu_data_3.cursor_out],dword 0 |
863 | jne analyse_out_menu_3 |
864 | jne analyse_out_menu_3 |
864 | jmp .menu_bar_1 |
865 | jmp .menu_bar_1 |
865 | ;--------------------------------------------------- |
866 | ;--------------------------------------------------- |
866 | .check_editboxes: |
867 | .check_editboxes: |
867 | cmp [open_dialog_type],1 |
868 | cmp [open_dialog_type],1 |
868 | jne .check_scroll_event |
869 | jne .check_scroll_event |
869 | mov eax,[edit1+44] |
870 | mov eax,[edit1+44] |
870 | and eax,10b |
871 | and eax,10b |
871 | push dword name_editboxes |
872 | push dword name_editboxes |
872 | call [edit_box_mouse] |
873 | call [edit_box_mouse] |
873 | mov ebx,[edit1+44] |
874 | mov ebx,[edit1+44] |
874 | and ebx,10b |
875 | and ebx,10b |
875 | cmp eax,ebx |
876 | cmp eax,ebx |
876 | je .check_scroll_event |
877 | je .check_scroll_event |
877 | mov al,[focus_pointer] |
878 | mov al,[focus_pointer] |
878 | test al,al |
879 | test al,al |
879 | jnz .check_scroll_event |
880 | jnz .check_scroll_event |
880 | xor eax,eax |
881 | xor eax,eax |
881 | test ebx,10b |
882 | test ebx,10b |
882 | jz @f |
883 | jz @f |
883 | inc eax |
884 | inc eax |
884 | @@: |
885 | @@: |
885 | mov [focus_pointer],al |
886 | mov [focus_pointer],al |
886 | jmp change_focus_area.1 |
887 | jmp change_focus_area.1 |
887 | ;--------------------------------------------------- |
888 | ;--------------------------------------------------- |
888 | .check_scroll_event: |
889 | .check_scroll_event: |
889 | mov eax,[mouse_position] |
890 | mov eax,[mouse_position] |
890 | xor ebx,ebx |
891 | xor ebx,ebx |
891 | mov bx,ax ; EBX mouse y |
892 | mov bx,ax ; EBX mouse y |
892 | shr eax,16 ; EAX mouse x |
893 | shr eax,16 ; EAX mouse x |
893 | 894 | ||
894 | mov cx,[file_browser_data_1.start_x] |
895 | mov cx,[file_browser_data_1.start_x] |
895 | mov dx,[file_browser_data_1.start_y] |
896 | mov dx,[file_browser_data_1.start_y] |
896 | 897 | ||
897 | cmp ax,cx |
898 | cmp ax,cx |
898 | jb .mouse_next ; min x |
899 | jb .mouse_next ; min x |
899 | 900 | ||
900 | cmp bx,dx |
901 | cmp bx,dx |
901 | jb .mouse_next ; min y |
902 | jb .mouse_next ; min y |
902 | 903 | ||
903 | add cx,[file_browser_data_1.size_x] |
904 | add cx,[file_browser_data_1.size_x] |
904 | cmp ax,cx |
905 | cmp ax,cx |
905 | ja .mouse_next ; max x |
906 | ja .mouse_next ; max x |
906 | 907 | ||
907 | add dx,[file_browser_data_1.size_y] |
908 | add dx,[file_browser_data_1.size_y] |
908 | cmp bx,dx |
909 | cmp bx,dx |
909 | ja .mouse_next ; max y |
910 | ja .mouse_next ; max y |
910 | 911 | ||
911 | xor ecx,ecx |
912 | xor ecx,ecx |
912 | xor ebx,ebx |
913 | xor ebx,ebx |
913 | mov eax,[mouse_scroll_data] |
914 | mov eax,[mouse_scroll_data] |
914 | test eax,eax |
915 | test eax,eax |
915 | jz .mouse_next |
916 | jz .mouse_next |
916 | test ax,0x8000 |
917 | test ax,0x8000 |
917 | jnz .decr |
918 | jnz .decr |
918 | shr eax,16 |
919 | shr eax,16 |
919 | test ax,0x8000 |
920 | test ax,0x8000 |
920 | jnz .decr_1 |
921 | jnz .decr_1 |
921 | 922 | ||
922 | mov cx,[mouse_scroll_data.vertical] |
923 | mov cx,[mouse_scroll_data.vertical] |
923 | test ecx,ecx |
924 | test ecx,ecx |
924 | jnz @f |
925 | jnz @f |
925 | mov cx,[mouse_scroll_data.horizontal] |
926 | mov cx,[mouse_scroll_data.horizontal] |
926 | test ecx,ecx |
927 | test ecx,ecx |
927 | jz .mouse_next |
928 | jz .mouse_next |
928 | @@: |
929 | @@: |
929 | mov ebx,1 |
930 | mov ebx,1 |
930 | @@: |
931 | @@: |
931 | push ebx ecx |
932 | push ebx ecx |
932 | call key.key_action |
933 | call key.key_action |
933 | pop ecx ebx |
934 | pop ecx ebx |
934 | dec ecx |
935 | dec ecx |
935 | jnz @r |
936 | jnz @r |
936 | jmp still |
937 | jmp still |
937 | ;---------------------------------------- |
938 | ;---------------------------------------- |
938 | .decr: |
939 | .decr: |
939 | mov bx,[mouse_scroll_data.vertical] |
940 | mov bx,[mouse_scroll_data.vertical] |
940 | jmp @f |
941 | jmp @f |
941 | .decr_1: |
942 | .decr_1: |
942 | mov bx,[mouse_scroll_data.horizontal] |
943 | mov bx,[mouse_scroll_data.horizontal] |
943 | @@: |
944 | @@: |
944 | mov ecx,0xffff |
945 | mov ecx,0xffff |
945 | sub ecx,ebx |
946 | sub ecx,ebx |
946 | inc ecx |
947 | inc ecx |
947 | mov ebx,2 |
948 | mov ebx,2 |
948 | @@: |
949 | @@: |
949 | push ebx ecx |
950 | push ebx ecx |
950 | call key.key_action |
951 | call key.key_action |
951 | pop ecx ebx |
952 | pop ecx ebx |
952 | dec ecx |
953 | dec ecx |
953 | jnz @r |
954 | jnz @r |
954 | jmp still |
955 | jmp still |
955 | ;--------------------------------------------------- |
956 | ;--------------------------------------------------- |
956 | .mouse_next: |
957 | .mouse_next: |
957 | jmp still |
958 | jmp still |
958 | ;--------------------------------------------------------------------- |
959 | ;--------------------------------------------------------------------- |
959 | .set_mouse_flag: |
960 | .set_mouse_flag: |
960 | xor eax,eax |
961 | xor eax,eax |
961 | inc eax |
962 | inc eax |
962 | mov [menu_data_1.get_mouse_flag],eax |
963 | mov [menu_data_1.get_mouse_flag],eax |
963 | mov [menu_data_2.get_mouse_flag],eax |
964 | mov [menu_data_2.get_mouse_flag],eax |
964 | ret |
965 | ret |
965 | ;--------------------------------------------------------------------- |
966 | ;--------------------------------------------------------------------- |
966 | analyse_out_menu_1: |
967 | analyse_out_menu_1: |
967 | ; Available disks |
968 | ; Available disks |
968 | mov eax,[menu_data_1.cursor_out] |
969 | mov eax,[menu_data_1.cursor_out] |
969 | dec eax |
970 | dec eax |
970 | imul esi,eax,10 |
971 | imul esi,eax,10 |
971 | add esi,retrieved_devices_table |
972 | add esi,retrieved_devices_table |
972 | mov edi,dir_path |
973 | mov edi,dir_path |
973 | call copy_dir_name |
974 | call copy_dir_name |
974 | call load_next_dir.1 |
975 | call load_next_dir.1 |
975 | jmp still |
976 | jmp still |
976 | ;--------------------------------------------------------------------- |
977 | ;--------------------------------------------------------------------- |
977 | analyse_out_menu_2: |
978 | analyse_out_menu_2: |
978 | ; Sort |
979 | ; Sort |
979 | mov eax,[menu_data_2.cursor_out] |
980 | mov eax,[menu_data_2.cursor_out] |
980 | xor ebx,ebx |
981 | xor ebx,ebx |
981 | cmp eax,dword 1 |
982 | cmp eax,dword 1 |
982 | je .1 |
983 | je .1 |
983 | cmp eax,dword 2 |
984 | cmp eax,dword 2 |
984 | je .2 |
985 | je .2 |
985 | cmp eax,dword 3 |
986 | cmp eax,dword 3 |
986 | je .3 |
987 | je .3 |
987 | cmp eax,dword 4 |
988 | cmp eax,dword 4 |
988 | je .4 |
989 | je .4 |
989 | jmp still |
990 | jmp still |
990 | .4: |
991 | .4: |
991 | add ebx,2 |
992 | add ebx,2 |
992 | .3: |
993 | .3: |
993 | add ebx,2 |
994 | add ebx,2 |
994 | .2: |
995 | .2: |
995 | add ebx,2 |
996 | add ebx,2 |
996 | .1: |
997 | .1: |
997 | mov [sort_type],ebx |
998 | mov [sort_type],ebx |
998 | call sort_directory |
999 | call sort_directory |
999 | call draw_draw_file_browser1 |
1000 | call draw_draw_file_browser1 |
1000 | jmp still |
1001 | jmp still |
1001 | ;--------------------------------------------------------------------- |
1002 | ;--------------------------------------------------------------------- |
1002 | analyse_out_menu_3: |
1003 | analyse_out_menu_3: |
1003 | ; Filter |
1004 | ; Filter |
1004 | mov eax,[menu_data_3.cursor_out] |
1005 | mov eax,[menu_data_3.cursor_out] |
1005 | cmp eax,dword 1 |
1006 | cmp eax,dword 1 |
1006 | jne @f |
1007 | jne @f |
1007 | mov [filter_flag],0 |
1008 | mov [filter_flag],0 |
1008 | call load_next_dir.1 |
1009 | call load_next_dir.1 |
1009 | jmp still |
1010 | jmp still |
1010 | @@: |
1011 | @@: |
1011 | cmp eax,dword 2 |
1012 | cmp eax,dword 2 |
1012 | jne still |
1013 | jne still |
1013 | mov [filter_flag],1 |
1014 | mov [filter_flag],1 |
1014 | call load_next_dir.1 |
1015 | call load_next_dir.1 |
1015 | jmp still |
1016 | jmp still |
1016 | ;--------------------------------------------------------------------- |
1017 | ;--------------------------------------------------------------------- |
1017 | get_communication_area: |
1018 | get_communication_area: |
1018 | xor eax,eax |
1019 | xor eax,eax |
1019 | mov al,[param] |
1020 | mov al,[param] |
1020 | test eax,eax |
1021 | test eax,eax |
1021 | jz @f |
1022 | jz .exit |
1022 | mcall 68,22,param,,0x01 |
1023 | mcall 68,22,param,,0x01 |
1023 | mov [communication_area],eax |
1024 | mov [communication_area],eax |
1024 | movzx ebx,word [eax+2] |
1025 | movzx ebx,word [eax+2] |
1025 | mov [open_dialog_type],ebx |
1026 | mov [open_dialog_type],ebx |
- | 1027 | cmp ebx,1 |
|
- | 1028 | jne @f |
|
- | 1029 | pushad |
|
- | 1030 | mov [focus_pointer],bl |
|
- | 1031 | mov edi,edit1 |
|
- | 1032 | mov [file_browser_data_1.select_panel_counter],0 |
|
- | 1033 | or [edi+44],dword ed_focus |
|
- | 1034 | mov [edi+12],dword 0xffffb0 ; color yellow |
|
- | 1035 | mcall 66,1,0 |
|
- | 1036 | popad |
|
- | 1037 | @@: |
|
1026 | mov ebx,[eax+4] |
1038 | mov ebx,[eax+4] |
1027 | cmp bx,word x_minimal_size ;300 |
1039 | cmp bx,word x_minimal_size ;300 |
1028 | jb @f |
1040 | jb @f |
1029 | mov [window_x],ebx |
1041 | mov [window_x],ebx |
1030 | mov ebx,[eax+8] |
1042 | mov ebx,[eax+8] |
1031 | cmp bx,word y_minimal_size ;200 |
1043 | cmp bx,word y_minimal_size ;200 |
1032 | jb @f |
1044 | jb @f |
1033 | mov [window_y],ebx |
1045 | mov [window_y],ebx |
1034 | @@: |
1046 | .exit: |
1035 | ret |
1047 | ret |
1036 | ;--------------------------------------------------------------------- |
1048 | ;--------------------------------------------------------------------- |
1037 | load_start_directory: |
1049 | load_start_directory: |
1038 | mov eax,[communication_area] |
1050 | mov eax,[communication_area] |
1039 | test eax,eax |
1051 | test eax,eax |
1040 | jz .1 |
1052 | jz .1 |
1041 | movzx ebx,word [eax] |
1053 | movzx ebx,word [eax] |
1042 | test eax,eax |
1054 | test eax,eax |
1043 | jz .1 |
1055 | jz .1 |
1044 | add eax,16 ;12 ;4 |
1056 | add eax,16 ;12 ;4 |
1045 | mov esi,eax |
1057 | mov esi,eax |
1046 | push esi |
1058 | push esi |
1047 | mov esi,[communication_area] |
1059 | mov esi,[communication_area] |
1048 | add esi,3840 ;4096-256 |
1060 | add esi,3840 ;4096-256 |
1049 | mov eax,[esi] |
1061 | mov eax,[esi] |
1050 | test eax,eax |
1062 | test al,al |
1051 | jnz @f |
1063 | jnz @f |
1052 | mov esi,example_name_temp |
1064 | mov esi,example_name_temp |
1053 | @@: |
1065 | @@: |
1054 | mov edi,user_selected_name |
1066 | mov edi,user_selected_name |
1055 | call copy_dir_name |
1067 | call copy_dir_name |
1056 | pop esi |
1068 | pop esi |
1057 | jmp .2 |
1069 | jmp .2 |
1058 | .1: |
1070 | .1: |
1059 | mov esi,start_pach |
1071 | mov esi,start_pach |
1060 | .2: |
1072 | .2: |
1061 | mov edi,dir_path |
1073 | mov edi,dir_path |
1062 | call copy_dir_name |
1074 | call copy_dir_name |
1063 | 1075 | ||
1064 | ; call load_directory |
1076 | ; call load_directory |
1065 | ; mov eax,[N_error] |
1077 | ; mov eax,[N_error] |
1066 | ; test eax,eax |
1078 | ; test eax,eax |
1067 | ; jnz button.exit |
1079 | ; jnz button.exit |
1068 | .3: |
1080 | .3: |
1069 | call load_directory |
1081 | call load_directory |
1070 | mov eax,[N_error] |
1082 | mov eax,[N_error] |
1071 | test eax,eax |
1083 | test eax,eax |
1072 | jz @f |
1084 | jz @f |
1073 | call error_handler |
1085 | call error_handler |
1074 | jmp .3 |
1086 | jmp .3 |
1075 | @@: |
1087 | @@: |
1076 | ret |
1088 | ret |
1077 | ;--------------------------------------------------------------------- |
1089 | ;--------------------------------------------------------------------- |
1078 | load_next_dir: |
1090 | load_next_dir: |
1079 | mov ebx,[file_browser_data_1.selected_BDVK_adress] |
1091 | mov ebx,[file_browser_data_1.selected_BDVK_adress] |
1080 | add ebx,40 |
1092 | add ebx,40 |
1081 | test [ebx-40],byte 0x10 |
1093 | test [ebx-40],byte 0x10 |
1082 | jz file_no_folder |
1094 | jz file_no_folder |
1083 | cmp [ebx],word '..' |
1095 | cmp [ebx],word '..' |
1084 | jne @f |
1096 | jne @f |
1085 | cmp [ebx+2],byte 0 |
1097 | cmp [ebx+2],byte 0 |
1086 | je .exit_dir |
1098 | je .exit_dir |
1087 | @@: |
1099 | @@: |
1088 | mov esi,dir_path |
1100 | mov esi,dir_path |
1089 | call copy_dir_path |
1101 | call copy_dir_path |
1090 | 1102 | ||
1091 | @@: |
1103 | @@: |
1092 | .1: |
1104 | .1: |
1093 | call load_directory |
1105 | call load_directory |
1094 | mov eax,[N_error] |
1106 | mov eax,[N_error] |
1095 | test eax,eax |
1107 | test eax,eax |
1096 | jz @f |
1108 | jz @f |
1097 | call error_handler |
1109 | call error_handler |
1098 | jmp .1 |
1110 | jmp .1 |
1099 | @@: |
1111 | @@: |
1100 | call sort_directory |
1112 | call sort_directory |
1101 | 1113 | ||
1102 | mov ebx,[scroll_bar_data_vertical.x] |
1114 | mov ebx,[scroll_bar_data_vertical.x] |
1103 | inc ebx |
1115 | inc ebx |
1104 | mov ecx,[scroll_bar_data_vertical.y] |
1116 | mov ecx,[scroll_bar_data_vertical.y] |
1105 | inc ecx |
1117 | inc ecx |
1106 | mcall 13,,,0xcccccc |
1118 | mcall 13,,,0xcccccc |
1107 | mov edi,edit1 |
1119 | mov edi,edit1 |
1108 | xor eax,eax |
1120 | xor eax,eax |
1109 | mov [edi+44],eax |
1121 | mov [edi+44],eax |
1110 | mov [edi+12],dword 0xffffff ; color white |
1122 | mov [edi+12],dword 0xffffff ; color white |
1111 | call draw_draw_file_browser1 |
1123 | call draw_draw_file_browser1 |
1112 | ret |
1124 | ret |
1113 | .exit_dir: |
1125 | .exit_dir: |
1114 | mov esi,dir_path |
1126 | mov esi,dir_path |
1115 | call copy_exit_dir |
1127 | call copy_exit_dir |
1116 | jmp .1 |
1128 | jmp .1 |
1117 | ;--------------------------------------------------------------------- |
1129 | ;--------------------------------------------------------------------- |
1118 | error_handler: |
1130 | error_handler: |
1119 | .red: |
1131 | .red: |
1120 | call .draw_window |
1132 | call .draw_window |
1121 | ;------------------------------------ |
1133 | ;------------------------------------ |
1122 | .still: |
1134 | .still: |
1123 | mcall 10 |
1135 | mcall 10 |
1124 | cmp eax,1 |
1136 | cmp eax,1 |
1125 | je .red |
1137 | je .red |
1126 | cmp eax,2 |
1138 | cmp eax,2 |
1127 | je .key |
1139 | je .key |
1128 | cmp eax,3 |
1140 | cmp eax,3 |
1129 | je .button |
1141 | je .button |
1130 | jmp .still |
1142 | jmp .still |
1131 | ;------------------------------------ |
1143 | ;------------------------------------ |
1132 | .draw_window: |
1144 | .draw_window: |
1133 | xor eax,eax |
1145 | xor eax,eax |
1134 | inc eax |
1146 | inc eax |
1135 | mov [error_window],al |
1147 | mov [error_window],al |
1136 | call control_minimal_window_size |
1148 | call control_minimal_window_size |
1137 | call draw_window |
1149 | call draw_window |
1138 | xor eax,eax |
1150 | xor eax,eax |
1139 | mov [error_window],al |
1151 | mov [error_window],al |
1140 | ret |
1152 | ret |
1141 | ;------------------------------------ |
1153 | ;------------------------------------ |
1142 | .key: |
1154 | .key: |
1143 | mcall 2 |
1155 | mcall 2 |
1144 | xor ebx,ebx |
1156 | xor ebx,ebx |
1145 | cmp [extended_key],1 |
1157 | cmp [extended_key],1 |
1146 | je .extended_key |
1158 | je .extended_key |
1147 | test al,al |
1159 | test al,al |
1148 | jnz .still |
1160 | jnz .still |
1149 | cmp ah,0xE0 |
1161 | cmp ah,0xE0 |
1150 | jne @f |
1162 | jne @f |
1151 | mov [extended_key],1 |
1163 | mov [extended_key],1 |
1152 | jmp .still |
1164 | jmp .still |
1153 | @@: |
1165 | @@: |
1154 | cmp ah,129 ; Esc |
1166 | cmp ah,129 ; Esc |
1155 | je .exit |
1167 | je .exit |
1156 | jmp .still |
1168 | jmp .still |
1157 | .extended_key: |
1169 | .extended_key: |
1158 | jmp .still |
1170 | jmp .still |
1159 | ;------------------------------------ |
1171 | ;------------------------------------ |
1160 | .button: |
1172 | .button: |
1161 | mcall 17 |
1173 | mcall 17 |
1162 | cmp ah,5 |
1174 | cmp ah,5 |
1163 | je .exit |
1175 | je .exit |
1164 | cmp ah,1 |
1176 | cmp ah,1 |
1165 | jne .still |
1177 | jne .still |
1166 | xor eax,eax |
1178 | xor eax,eax |
1167 | mov [N_error],eax |
1179 | mov [N_error],eax |
1168 | jmp button.exit |
1180 | jmp button.exit |
1169 | ;------------------------------------ |
1181 | ;------------------------------------ |
1170 | .exit: |
1182 | .exit: |
1171 | mov esi,previous_dir_path |
1183 | mov esi,previous_dir_path |
1172 | mov edi,dir_path |
1184 | mov edi,dir_path |
1173 | call copy_dir_name.1 |
1185 | call copy_dir_name.1 |
1174 | mov esi,start_pach |
1186 | mov esi,start_pach |
1175 | mov edi,previous_dir_path |
1187 | mov edi,previous_dir_path |
1176 | call copy_dir_name.1 |
1188 | call copy_dir_name.1 |
1177 | ret |
1189 | ret |
1178 | ;--------------------------------------------------------------------- |
1190 | ;--------------------------------------------------------------------- |
1179 | file_no_folder: |
1191 | file_no_folder: |
1180 | mov esi,dir_path |
1192 | mov esi,dir_path |
1181 | mov edi,file_name |
1193 | mov edi,file_name |
1182 | call copy_dir_name |
1194 | call copy_dir_name |
1183 | push ebx |
1195 | push ebx |
1184 | mov al,[focus_pointer] |
1196 | mov al,[focus_pointer] |
1185 | test al,al |
1197 | test al,al |
1186 | je @f |
1198 | je @f |
1187 | mov ebx,user_selected_name |
1199 | mov ebx,user_selected_name |
- | 1200 | xor eax,eax |
|
- | 1201 | cmp [ebx],al |
|
- | 1202 | je .exit |
|
1188 | @@: |
1203 | @@: |
1189 | cmp [open_dialog_type],2 |
1204 | cmp [open_dialog_type],2 |
1190 | je @f |
1205 | je @f |
1191 | mov esi,file_name |
1206 | mov esi,file_name |
1192 | call copy_dir_path |
1207 | call copy_dir_path |
1193 | @@: |
1208 | @@: |
1194 | mov eax,[communication_area] |
1209 | mov eax,[communication_area] |
1195 | test eax,eax |
1210 | test eax,eax |
1196 | jnz @f |
1211 | jnz @f |
1197 | call control_minimal_window_size |
1212 | call control_minimal_window_size |
1198 | call draw_window |
1213 | call draw_window |
1199 | pop ebx |
1214 | pop ebx |
1200 | ret |
1215 | ret |
1201 | @@: |
1216 | @@: |
1202 | mov edi,eax |
1217 | mov edi,eax |
1203 | add edi,16 ;12 |
1218 | add edi,16 ;12 |
1204 | mov esi,file_name |
1219 | mov esi,file_name |
1205 | call copy_dir_name |
1220 | call copy_dir_name |
1206 | 1221 | ||
1207 | pop esi |
1222 | pop esi |
1208 | mov al,[focus_pointer] |
1223 | mov al,[focus_pointer] |
1209 | test al,al |
1224 | test al,al |
1210 | jz @f |
1225 | jz @f |
1211 | mov esi,user_selected_name |
1226 | mov esi,user_selected_name |
1212 | @@: |
1227 | @@: |
- | 1228 | xor eax,eax |
|
- | 1229 | cmp [esi],al |
|
- | 1230 | je .exit |
|
1213 | mov edi,[communication_area] |
1231 | mov edi,[communication_area] |
1214 | add edi,3840 ;4096-256 |
1232 | add edi,3840 ;4096-256 |
1215 | call copy_dir_name |
1233 | call copy_dir_name |
1216 | 1234 | .exit: |
|
1217 | mov eax,[communication_area] |
1235 | mov eax,[communication_area] |
1218 | mov [eax],word 1 |
1236 | mov [eax],word 1 |
1219 | jmp button.exit |
1237 | jmp button.exit |
1220 | ;--------------------------------------------------------------------- |
1238 | ;--------------------------------------------------------------------- |
1221 | load_root_directory: |
1239 | load_root_directory: |
1222 | mov [dirinfo.name],dword dir_path_temp |
1240 | mov [dirinfo.name],dword dir_path_temp |
1223 | mov eax,[dirinfo.return] |
1241 | mov eax,[dirinfo.return] |
1224 | push eax |
1242 | push eax |
1225 | mov eax,[file_browser_data_1.folder_data] |
1243 | mov eax,[file_browser_data_1.folder_data] |
1226 | push eax |
1244 | push eax |
1227 | xor eax,eax |
1245 | xor eax,eax |
1228 | mov [dirinfo.return],eax |
1246 | mov [dirinfo.return],eax |
1229 | mov [file_browser_data_1.folder_data],eax |
1247 | mov [file_browser_data_1.folder_data],eax |
1230 | mov esi,root_pach |
1248 | mov esi,root_pach |
1231 | mov edi,dir_path_temp |
1249 | mov edi,dir_path_temp |
1232 | call copy_dir_name |
1250 | call copy_dir_name |
1233 | call load_directory |
1251 | call load_directory |
1234 | mov eax,[N_error] |
1252 | mov eax,[N_error] |
1235 | test eax,eax |
1253 | test eax,eax |
1236 | jnz button.exit |
1254 | jnz button.exit |
1237 | 1255 | ||
1238 | mov eax,[dirinfo.return] |
1256 | mov eax,[dirinfo.return] |
1239 | mov [root_folder_area],eax |
1257 | mov [root_folder_area],eax |
1240 | mov eax,[eax+4] |
1258 | mov eax,[eax+4] |
1241 | mov [root_folder_block],eax |
1259 | mov [root_folder_block],eax |
1242 | 1260 | ||
1243 | xor eax,eax |
1261 | xor eax,eax |
1244 | mov [dirinfo.return],eax |
1262 | mov [dirinfo.return],eax |
1245 | mov [file_browser_data_1.folder_data],eax |
1263 | mov [file_browser_data_1.folder_data],eax |
1246 | mov [temp_counter_1],eax ;0 |
1264 | mov [temp_counter_1],eax ;0 |
1247 | 1265 | ||
1248 | mov [retrieved_devices_table_counter],eax ;0 |
1266 | mov [retrieved_devices_table_counter],eax ;0 |
1249 | .start_temp_counter_1: |
1267 | .start_temp_counter_1: |
1250 | imul esi,[temp_counter_1],304 |
1268 | imul esi,[temp_counter_1],304 |
1251 | add esi,[root_folder_area] |
1269 | add esi,[root_folder_area] |
1252 | add esi,32+40 |
1270 | add esi,32+40 |
1253 | mov edi,dir_path_temp+1 |
1271 | mov edi,dir_path_temp+1 |
1254 | mov [edi-1],byte '/' |
1272 | mov [edi-1],byte '/' |
1255 | call copy_dir_name |
1273 | call copy_dir_name |
1256 | call load_directory |
1274 | call load_directory |
1257 | mov eax,[N_error] |
1275 | mov eax,[N_error] |
1258 | test eax,eax |
1276 | test eax,eax |
1259 | jnz button.exit |
1277 | jnz button.exit |
1260 | 1278 | ||
1261 | mov eax,[dirinfo.return] |
1279 | mov eax,[dirinfo.return] |
1262 | mov [root1_folder_area],eax |
1280 | mov [root1_folder_area],eax |
1263 | mov eax,[eax+4] |
1281 | mov eax,[eax+4] |
1264 | test eax,eax |
1282 | test eax,eax |
1265 | jz .continue |
1283 | jz .continue |
1266 | mov [root1_folder_block],eax |
1284 | mov [root1_folder_block],eax |
1267 | 1285 | ||
1268 | mov ebp,0 |
1286 | mov ebp,0 |
1269 | .start_copy_device_patch: |
1287 | .start_copy_device_patch: |
1270 | imul edi,[retrieved_devices_table_counter],10 |
1288 | imul edi,[retrieved_devices_table_counter],10 |
1271 | add edi,retrieved_devices_table |
1289 | add edi,retrieved_devices_table |
1272 | mov [edi],byte '/' |
1290 | mov [edi],byte '/' |
1273 | inc edi |
1291 | inc edi |
1274 | imul esi,[temp_counter_1],304 |
1292 | imul esi,[temp_counter_1],304 |
1275 | add esi,[root_folder_area] |
1293 | add esi,[root_folder_area] |
1276 | add esi,32+40 |
1294 | add esi,32+40 |
1277 | 1295 | ||
1278 | call copy_dir_name |
1296 | call copy_dir_name |
1279 | 1297 | ||
1280 | imul esi,ebp,304 |
1298 | imul esi,ebp,304 |
1281 | add esi,[root1_folder_area] |
1299 | add esi,[root1_folder_area] |
1282 | add esi,32+40 |
1300 | add esi,32+40 |
1283 | mov [edi-1],byte '/' |
1301 | mov [edi-1],byte '/' |
1284 | 1302 | ||
1285 | call copy_dir_name |
1303 | call copy_dir_name |
1286 | 1304 | ||
1287 | inc [retrieved_devices_table_counter] |
1305 | inc [retrieved_devices_table_counter] |
1288 | inc ebp |
1306 | inc ebp |
1289 | cmp ebp,[root1_folder_block] |
1307 | cmp ebp,[root1_folder_block] |
1290 | jb .start_copy_device_patch |
1308 | jb .start_copy_device_patch |
1291 | .continue: |
1309 | .continue: |
1292 | inc [temp_counter_1] |
1310 | inc [temp_counter_1] |
1293 | mov eax,[temp_counter_1] |
1311 | mov eax,[temp_counter_1] |
1294 | cmp eax,[root_folder_block] |
1312 | cmp eax,[root_folder_block] |
1295 | jb .start_temp_counter_1 |
1313 | jb .start_temp_counter_1 |
1296 | 1314 | ||
1297 | cmp [root_folder_area],dword 0 |
1315 | cmp [root_folder_area],dword 0 |
1298 | je @f |
1316 | je @f |
1299 | mcall 68,13,[root_folder_area] |
1317 | mcall 68,13,[root_folder_area] |
1300 | test eax,eax |
1318 | test eax,eax |
1301 | jz memory_free_error |
1319 | jz memory_free_error |
1302 | @@: |
1320 | @@: |
1303 | 1321 | ||
1304 | xor ecx,ecx |
1322 | xor ecx,ecx |
1305 | mov edi,menu_text_area_1_1 ;.1 |
1323 | mov edi,menu_text_area_1_1 ;.1 |
1306 | @@: |
1324 | @@: |
1307 | imul esi,ecx,10 |
1325 | imul esi,ecx,10 |
1308 | add esi,retrieved_devices_table |
1326 | add esi,retrieved_devices_table |
1309 | call copy_dir_name |
1327 | call copy_dir_name |
1310 | inc ecx |
1328 | inc ecx |
1311 | cmp ecx,[retrieved_devices_table_counter] |
1329 | cmp ecx,[retrieved_devices_table_counter] |
1312 | jb @b |
1330 | jb @b |
1313 | mov [menu_data_1.text_end],edi |
1331 | mov [menu_data_1.text_end],edi |
1314 | xor eax,eax |
1332 | xor eax,eax |
1315 | mov [edi],eax |
1333 | mov [edi],eax |
1316 | pop eax |
1334 | pop eax |
1317 | mov [file_browser_data_1.folder_data],eax |
1335 | mov [file_browser_data_1.folder_data],eax |
1318 | pop eax |
1336 | pop eax |
1319 | mov [dirinfo.return],eax |
1337 | mov [dirinfo.return],eax |
1320 | mov [dirinfo.name],dword dir_path |
1338 | mov [dirinfo.name],dword dir_path |
1321 | ret |
1339 | ret |
1322 | ;--------------------------------------------------------------------- |
1340 | ;--------------------------------------------------------------------- |
1323 | memory_free_error: |
1341 | memory_free_error: |
1324 | mov [N_error],3 |
1342 | mov [N_error],3 |
1325 | jmp button.exit |
1343 | jmp button.exit |
1326 | ;--------------------------------------------------------------------- |
1344 | ;--------------------------------------------------------------------- |
1327 | memory_get_error: |
1345 | memory_get_error: |
1328 | mov [N_error],4 |
1346 | mov [N_error],4 |
1329 | jmp button.exit |
1347 | jmp button.exit |
1330 | ;--------------------------------------------------------------------- |
1348 | ;--------------------------------------------------------------------- |
1331 | type_title: |
1349 | type_title: |
1332 | mov ecx,[open_dialog_type] |
1350 | mov ecx,[open_dialog_type] |
1333 | shl ecx,2 |
1351 | shl ecx,2 |
1334 | add ecx,open_dialog_title_pointer |
1352 | add ecx,open_dialog_title_pointer |
1335 | mov ecx,[ecx] |
1353 | mov ecx,[ecx] |
1336 | test ecx,ecx |
1354 | test ecx,ecx |
1337 | jz @f |
1355 | jz @f |
1338 | mcall 71,1,; title ;;param ;file_name ;dir_path |
1356 | mcall 71,1,; title ;;param ;file_name ;dir_path |
1339 | @@: |
1357 | @@: |
1340 | ret |
1358 | ret |
1341 | ;--------------------------------------------------------------------- |
1359 | ;--------------------------------------------------------------------- |
1342 | draw_window: |
1360 | draw_window: |
1343 | 1361 | ||
1344 | mcall 12,1 |
1362 | mcall 12,1 |
1345 | 1363 | ||
1346 | call prepare_system_colors |
1364 | call prepare_system_colors |
1347 | 1365 | ||
1348 | ; mcall 0,<10,420>,<10,320>,0x63AABBCC, |
1366 | ; mcall 0,<10,420>,<10,320>,0x63AABBCC, |
1349 | xor esi,esi |
1367 | xor esi,esi |
1350 | ; mov edx,[w_work] ; color of work area RRGGBB,8->color |
1368 | ; mov edx,[w_work] ; color of work area RRGGBB,8->color |
1351 | ; or edx,0x63000000 |
1369 | ; or edx,0x63000000 |
1352 | mcall 0,[window_x],[window_y],0x63AABBCC |
1370 | mcall 0,[window_x],[window_y],0x63AABBCC |
1353 | 1371 | ||
1354 | ; mov ecx,[communication_area] |
1372 | ; mov ecx,[communication_area] |
1355 | ; add ecx,4096+4+4 |
1373 | ; add ecx,4096+4+4 |
1356 | call type_title |
1374 | call type_title |
1357 | call get_window_param |
1375 | call get_window_param |
1358 | 1376 | ||
1359 | mov eax,[procinfo+70] ;status of window |
1377 | mov eax,[procinfo+70] ;status of window |
1360 | test eax,100b |
1378 | test eax,100b |
1361 | jne .end |
1379 | jne .end |
1362 | 1380 | ||
1363 | mov eax,[window_high] |
1381 | mov eax,[window_high] |
1364 | sub eax,25+45 |
1382 | sub eax,25+45 |
1365 | mov [file_browser_data_1.size_y],ax |
1383 | mov [file_browser_data_1.size_y],ax |
1366 | mov [scroll_bar_data_vertical.size_y],ax |
1384 | mov [scroll_bar_data_vertical.size_y],ax |
1367 | 1385 | ||
1368 | mov eax,[window_width] |
1386 | mov eax,[window_width] |
1369 | sub eax,10+20 |
1387 | sub eax,10+20 |
1370 | mov [file_browser_data_1.size_x],ax |
1388 | mov [file_browser_data_1.size_x],ax |
1371 | add ax,10 |
1389 | add ax,10 |
1372 | mov [scroll_bar_data_vertical.start_x],ax |
1390 | mov [scroll_bar_data_vertical.start_x],ax |
1373 | 1391 | ||
1374 | mov edx,[w_work] ; color of work area RRGGBB,8->color |
1392 | mov edx,[w_work] ; color of work area RRGGBB,8->color |
1375 | or edx,0x63000000 |
1393 | or edx,0x63000000 |
1376 | mcall 13,[window_width],45 ;,0xcccccc |
1394 | mcall 13,[window_width],45 ;,0xcccccc |
1377 | 1395 | ||
1378 | push ecx |
1396 | push ecx |
1379 | rol ecx,16 |
1397 | rol ecx,16 |
1380 | add cx,[file_browser_data_1.size_y] |
1398 | add cx,[file_browser_data_1.size_y] |
1381 | add cx,45 |
1399 | add cx,45 |
1382 | ror ecx,16 |
1400 | ror ecx,16 |
1383 | mov cx,25 |
1401 | mov cx,25 |
1384 | mcall |
1402 | mcall |
1385 | pop ecx |
1403 | pop ecx |
1386 | add ecx,45 shl 16 |
1404 | add ecx,45 shl 16 |
1387 | mov cx,[file_browser_data_1.size_y] |
1405 | mov cx,[file_browser_data_1.size_y] |
1388 | mov bx,10 |
1406 | mov bx,10 |
1389 | mcall |
1407 | mcall |
1390 | mov bx,[file_browser_data_1.size_x] |
1408 | mov bx,[file_browser_data_1.size_x] |
1391 | add bx,10 |
1409 | add bx,10 |
1392 | shl ebx,16 |
1410 | shl ebx,16 |
1393 | mov bx,20 |
1411 | mov bx,20 |
1394 | mcall |
1412 | mcall |
1395 | 1413 | ||
1396 | cmp [error_window],0 |
1414 | cmp [error_window],0 |
1397 | je @f |
1415 | je @f |
1398 | call draw_for_fs_errors |
1416 | call draw_for_fs_errors |
1399 | jmp .1 |
1417 | jmp .1 |
1400 | @@: |
1418 | @@: |
1401 | mov [do_not_draw_open_button_label],1 |
1419 | mov [do_not_draw_open_button_label],1 |
1402 | call draw_draw_file_browser1 |
1420 | call draw_draw_file_browser1 |
1403 | mov [do_not_draw_open_button_label],0 |
1421 | mov [do_not_draw_open_button_label],0 |
1404 | .1: |
1422 | .1: |
1405 | push dword menu_data_1 |
1423 | push dword menu_data_1 |
1406 | call [menu_bar_draw] |
1424 | call [menu_bar_draw] |
1407 | push dword menu_data_2 |
1425 | push dword menu_data_2 |
1408 | call [menu_bar_draw] |
1426 | call [menu_bar_draw] |
1409 | push dword menu_data_3 |
1427 | push dword menu_data_3 |
1410 | call [menu_bar_draw] |
1428 | call [menu_bar_draw] |
1411 | 1429 | ||
1412 | mov ebx,[file_browser_data_1.x] |
1430 | mov ebx,[file_browser_data_1.x] |
1413 | mov ax,bx |
1431 | mov ax,bx |
1414 | shl eax,16 |
1432 | shl eax,16 |
1415 | add ebx,eax |
1433 | add ebx,eax |
1416 | mov eax,50 |
1434 | mov eax,50 |
1417 | mov bx,ax |
1435 | mov bx,ax |
1418 | shl eax,16 |
1436 | shl eax,16 |
1419 | sub ebx,eax |
1437 | sub ebx,eax |
1420 | mov ecx,26 shl 16+15 |
1438 | mov ecx,26 shl 16+15 |
1421 | 1439 | ||
1422 | mcall 8,,,2,[w_work_button] ;0xffffff |
1440 | mcall 8,,,2,[w_work_button] ;0xffffff |
1423 | 1441 | ||
1424 | pusha |
1442 | pusha |
1425 | shr ecx,16 |
1443 | shr ecx,16 |
1426 | mov bx,cx |
1444 | mov bx,cx |
1427 | add ebx,20 shl 16+2 |
1445 | add ebx,20 shl 16+2 |
1428 | mov ecx,[w_work_button_text] |
1446 | mov ecx,[w_work_button_text] |
1429 | or ecx,0x90000000 |
1447 | or ecx,0x90000000 |
1430 | mcall 4,,,message_ExitDir_button |
1448 | mcall 4,,,message_ExitDir_button |
1431 | add ebx,4 |
1449 | add ebx,4 |
1432 | mcall |
1450 | mcall |
1433 | add ebx,4 |
1451 | add ebx,4 |
1434 | mcall |
1452 | mcall |
1435 | popa |
1453 | popa |
1436 | 1454 | ||
1437 | push ebx |
1455 | push ebx |
1438 | sub ebx,70 shl 16 |
1456 | sub ebx,70 shl 16 |
1439 | mov bx,60 |
1457 | mov bx,60 |
1440 | mcall 8,,,6 |
1458 | mcall 8,,,6 |
1441 | 1459 | ||
1442 | shr ecx,16 |
1460 | shr ecx,16 |
1443 | mov bx,cx |
1461 | mov bx,cx |
1444 | add ebx,5 shl 16+4 |
1462 | add ebx,5 shl 16+4 |
1445 | mov ecx,[w_work_button_text] |
1463 | mov ecx,[w_work_button_text] |
1446 | or ecx,0x90000000 |
1464 | or ecx,0x90000000 |
1447 | mcall 4,,,message_ReloadDir_button |
1465 | mcall 4,,,message_ReloadDir_button |
1448 | pop ebx |
1466 | pop ebx |
1449 | 1467 | ||
1450 | mov ebx,[file_browser_data_1.x] |
1468 | mov ebx,[file_browser_data_1.x] |
1451 | 1469 | ||
1452 | mov ax,bx |
1470 | mov ax,bx |
1453 | shl eax,16 |
1471 | shl eax,16 |
1454 | add ebx,eax |
1472 | add ebx,eax |
1455 | mov eax,55 |
1473 | mov eax,55 |
1456 | mov bx,ax |
1474 | mov bx,ax |
1457 | shl eax,16 |
1475 | shl eax,16 |
1458 | sub ebx,eax |
1476 | sub ebx,eax |
1459 | 1477 | ||
1460 | mov ecx,[file_browser_data_1.y] |
1478 | mov ecx,[file_browser_data_1.y] |
1461 | mov ax,cx |
1479 | mov ax,cx |
1462 | add eax,3 |
1480 | add eax,3 |
1463 | shl eax,16 |
1481 | shl eax,16 |
1464 | add ecx,eax |
1482 | add ecx,eax |
1465 | mov cx,15 |
1483 | mov cx,15 |
1466 | 1484 | ||
1467 | mcall 8,,,3 |
1485 | mcall 8,,,3 |
1468 | 1486 | ||
1469 | pusha |
1487 | pusha |
1470 | 1488 | ||
1471 | shr ecx,16 |
1489 | shr ecx,16 |
1472 | mov bx,cx |
1490 | mov bx,cx |
1473 | add ebx,6 shl 16+ 4 |
1491 | add ebx,6 shl 16+ 4 |
1474 | mov ecx,[w_work_button_text] |
1492 | mov ecx,[w_work_button_text] |
1475 | or ecx,0x90000000 |
1493 | or ecx,0x90000000 |
1476 | mcall 4,,,message_cancel_button |
1494 | mcall 4,,,message_cancel_button |
1477 | popa |
1495 | popa |
1478 | 1496 | ||
1479 | sub ebx,65 shl 16 |
1497 | sub ebx,65 shl 16 |
1480 | mcall 8,,,4 |
1498 | mcall 8,,,4 |
1481 | 1499 | ||
1482 | shr ecx,16 |
1500 | shr ecx,16 |
1483 | mov bx,cx |
1501 | mov bx,cx |
1484 | add ebx,6 shl 16+4 |
1502 | add ebx,6 shl 16+4 |
1485 | 1503 | ||
1486 | mov edx,[open_dialog_type] |
1504 | mov edx,[open_dialog_type] |
1487 | shl edx,2 |
1505 | shl edx,2 |
1488 | add edx,message_open_dialog_button |
1506 | add edx,message_open_dialog_button |
1489 | mov edx,[edx] |
1507 | mov edx,[edx] |
1490 | ;-------------------------------------- |
1508 | ;-------------------------------------- |
1491 | cmp [open_dialog_type],1 |
1509 | cmp [open_dialog_type],1 |
1492 | jne @f |
1510 | jne @f |
1493 | 1511 | ||
1494 | cmp [focus_pointer],1 |
1512 | cmp [focus_pointer],1 |
1495 | je @f |
1513 | je @f |
1496 | 1514 | ||
1497 | mov eax,[file_browser_data_1.selected_BDVK_adress] |
1515 | mov eax,[file_browser_data_1.selected_BDVK_adress] |
1498 | test [eax],byte 0x10 |
1516 | test [eax],byte 0x10 |
1499 | jz @f |
1517 | jz @f |
1500 | 1518 | ||
1501 | mov edx,message_0 ; Open Dir |
1519 | mov edx,message_0 ; Open Dir |
1502 | @@: |
1520 | @@: |
1503 | ;-------------------------------------- |
1521 | ;-------------------------------------- |
1504 | mov [open_button_coordinates],ebx |
1522 | mov [open_button_coordinates],ebx |
1505 | mov ecx,[w_work_button_text] |
1523 | mov ecx,[w_work_button_text] |
1506 | or ecx,0x90000000 |
1524 | or ecx,0x90000000 |
1507 | mcall 4 ;message_open_button |
1525 | mcall 4 ;message_open_button |
1508 | 1526 | ||
1509 | ; mcall 47,0x80000,[file_browser_data_1.ini_file_start],<250,0>,0x0 |
1527 | ; mcall 47,0x80000,[file_browser_data_1.ini_file_start],<250,0>,0x0 |
1510 | ; mcall 4,<3,420>,0,fb_extension_start,3 |
1528 | ; mcall 4,<3,420>,0,fb_extension_start,3 |
1511 | .end: |
1529 | .end: |
1512 | mcall 12,2 |
1530 | mcall 12,2 |
1513 | 1531 | ||
1514 | ret |
1532 | ret |
1515 | ;--------------------------------------------------------------------- |
1533 | ;--------------------------------------------------------------------- |
1516 | draw_open_button_label: |
1534 | draw_open_button_label: |
1517 | cmp [do_not_draw_open_button_label],1 |
1535 | cmp [do_not_draw_open_button_label],1 |
1518 | je .exit_1 |
1536 | je .exit_1 |
1519 | 1537 | ||
1520 | cmp [open_dialog_type],1 |
1538 | cmp [open_dialog_type],1 |
1521 | jne .exit_1 |
1539 | jne .exit_1 |
1522 | 1540 | ||
1523 | cmp [focus_pointer],1 |
1541 | cmp [focus_pointer],1 |
1524 | je draw_save_button_label |
1542 | je draw_save_button_label |
1525 | 1543 | ||
1526 | pusha |
1544 | pusha |
1527 | mov ebx,[open_button_coordinates] |
1545 | mov ebx,[open_button_coordinates] |
1528 | test ebx,ebx |
1546 | test ebx,ebx |
1529 | jz .exit |
1547 | jz .exit |
1530 | 1548 | ||
1531 | mov edx,[open_dialog_type] |
1549 | mov edx,[open_dialog_type] |
1532 | shl edx,2 |
1550 | shl edx,2 |
1533 | add edx,message_open_dialog_button |
1551 | add edx,message_open_dialog_button |
1534 | mov edx,[edx] |
1552 | mov edx,[edx] |
1535 | 1553 | ||
1536 | mov eax,[file_browser_data_1.selected_BDVK_adress] |
1554 | mov eax,[file_browser_data_1.selected_BDVK_adress] |
1537 | test [eax],byte 0x10 |
1555 | test [eax],byte 0x10 |
1538 | jz @f |
1556 | jz @f |
1539 | 1557 | ||
1540 | mov edx,message_0 ; Open Dir |
1558 | mov edx,message_0 ; Open Dir |
1541 | jmp .1 |
1559 | jmp .1 |
1542 | @@: |
1560 | @@: |
1543 | call copy_new_file_name |
1561 | call copy_new_file_name |
1544 | .1: |
1562 | .1: |
1545 | mov ecx,[w_work_button_text] |
1563 | mov ecx,[w_work_button_text] |
1546 | or ecx,0xd0000000 |
1564 | or ecx,0xd0000000 |
1547 | mov edi,[w_work_button] |
1565 | mov edi,[w_work_button] |
1548 | mcall 4 ;message_open_button |
1566 | mcall 4 ;message_open_button |
1549 | .exit: |
1567 | .exit: |
1550 | popa |
1568 | popa |
1551 | .exit_1: |
1569 | .exit_1: |
1552 | ret |
1570 | ret |
1553 | ;--------------------------------------------------------------------- |
1571 | ;--------------------------------------------------------------------- |
1554 | draw_save_button_label: |
1572 | draw_save_button_label: |
1555 | pusha |
1573 | pusha |
1556 | mov ebx,[open_button_coordinates] |
1574 | mov ebx,[open_button_coordinates] |
1557 | 1575 | ||
1558 | mov edx,message_1 ; Save |
1576 | mov edx,message_1 ; Save |
1559 | 1577 | ||
1560 | mov ecx,[w_work_button_text] |
1578 | mov ecx,[w_work_button_text] |
1561 | or ecx,0xd0000000 |
1579 | or ecx,0xd0000000 |
1562 | mov edi,[w_work_button] |
1580 | mov edi,[w_work_button] |
1563 | mcall 4 ;message_open_button |
1581 | mcall 4 ;message_open_button |
1564 | popa |
1582 | popa |
1565 | ret |
1583 | ret |
1566 | ;--------------------------------------------------------------------- |
1584 | ;--------------------------------------------------------------------- |
1567 | copy_new_file_name: |
1585 | copy_new_file_name: |
1568 | mov esi,[file_browser_data_1.selected_BDVK_adress] |
1586 | mov esi,[file_browser_data_1.selected_BDVK_adress] |
1569 | add esi,40 |
1587 | add esi,40 |
1570 | mov edi,user_selected_name |
1588 | mov edi,user_selected_name |
1571 | cld |
1589 | cld |
- | 1590 | lodsb |
|
- | 1591 | test al,al |
|
- | 1592 | jnz .1 |
|
- | 1593 | ret |
|
1572 | @@: |
1594 | @@: |
1573 | lodsb |
1595 | lodsb |
- | 1596 | .1: |
|
1574 | stosb |
1597 | stosb |
1575 | test al,al |
1598 | test al,al |
1576 | jnz @r |
1599 | jnz @r |
1577 | 1600 | ||
1578 | sub edi,user_selected_name |
1601 | sub edi,user_selected_name |
1579 | dec edi |
1602 | dec edi |
1580 | 1603 | ||
1581 | mov esi,edit1 |
1604 | mov esi,edit1 |
1582 | mov [esi+48],edi ;ed_size |
1605 | mov [esi+48],edi ;ed_size |
1583 | mov [esi+52],edi ;ed_pos |
1606 | mov [esi+52],edi ;ed_pos |
1584 | 1607 | ||
1585 | push dword name_editboxes |
1608 | push dword name_editboxes |
1586 | call [edit_box_draw] |
1609 | call [edit_box_draw] |
1587 | ret |
1610 | ret |
1588 | ;--------------------------------------------------------------------- |
1611 | ;--------------------------------------------------------------------- |
1589 | prepare_system_colors: |
1612 | prepare_system_colors: |
1590 | mcall 48,3,app_colours,10*4 |
1613 | mcall 48,3,app_colours,10*4 |
1591 | 1614 | ||
1592 | mov eax,[w_work] |
1615 | mov eax,[w_work] |
1593 | mov [menu_data_1.bckg_col],eax |
1616 | mov [menu_data_1.bckg_col],eax |
1594 | mov [menu_data_2.bckg_col],eax |
1617 | mov [menu_data_2.bckg_col],eax |
1595 | mov [menu_data_3.bckg_col],eax |
1618 | mov [menu_data_3.bckg_col],eax |
1596 | 1619 | ||
1597 | mov [menu_data_1.menu_col],eax |
1620 | mov [menu_data_1.menu_col],eax |
1598 | mov [menu_data_2.menu_col],eax |
1621 | mov [menu_data_2.menu_col],eax |
1599 | mov [menu_data_3.menu_col],eax |
1622 | mov [menu_data_3.menu_col],eax |
1600 | 1623 | ||
1601 | mov [scroll_bar_data_vertical.bckg_col],eax |
1624 | mov [scroll_bar_data_vertical.bckg_col],eax |
1602 | 1625 | ||
1603 | mov eax,[w_work_button] |
1626 | mov eax,[w_work_button] |
1604 | mov [menu_data_1.frnt_col],eax |
1627 | mov [menu_data_1.frnt_col],eax |
1605 | mov [menu_data_2.frnt_col],eax |
1628 | mov [menu_data_2.frnt_col],eax |
1606 | mov [menu_data_3.frnt_col],eax |
1629 | mov [menu_data_3.frnt_col],eax |
1607 | 1630 | ||
1608 | mov [scroll_bar_data_vertical.frnt_col],eax |
1631 | mov [scroll_bar_data_vertical.frnt_col],eax |
1609 | 1632 | ||
1610 | mov eax,[w_work_button] |
1633 | mov eax,[w_work_button] |
1611 | mov [menu_data_1.menu_sel_col],eax |
1634 | mov [menu_data_1.menu_sel_col],eax |
1612 | mov [menu_data_2.menu_sel_col],eax |
1635 | mov [menu_data_2.menu_sel_col],eax |
1613 | mov [menu_data_3.menu_sel_col],eax |
1636 | mov [menu_data_3.menu_sel_col],eax |
1614 | 1637 | ||
1615 | mov eax,[w_work_text] |
1638 | mov eax,[w_work_text] |
1616 | mov [menu_data_1.bckg_text_col],eax |
1639 | mov [menu_data_1.bckg_text_col],eax |
1617 | mov [menu_data_2.bckg_text_col],eax |
1640 | mov [menu_data_2.bckg_text_col],eax |
1618 | mov [menu_data_3.bckg_text_col],eax |
1641 | mov [menu_data_3.bckg_text_col],eax |
1619 | 1642 | ||
1620 | mov eax,[w_work_button_text] |
1643 | mov eax,[w_work_button_text] |
1621 | mov [menu_data_1.frnt_text_col],eax |
1644 | mov [menu_data_1.frnt_text_col],eax |
1622 | mov [menu_data_2.frnt_text_col],eax |
1645 | mov [menu_data_2.frnt_text_col],eax |
1623 | mov [menu_data_3.frnt_text_col],eax |
1646 | mov [menu_data_3.frnt_text_col],eax |
1624 | 1647 | ||
1625 | mov [scroll_bar_data_vertical.line_col],eax |
1648 | mov [scroll_bar_data_vertical.line_col],eax |
1626 | ret |
1649 | ret |
1627 | ;--------------------------------------------------------------------- |
1650 | ;--------------------------------------------------------------------- |
1628 | draw_for_fs_errors: |
1651 | draw_for_fs_errors: |
1629 | call draw_dir_path |
1652 | call draw_dir_path |
1630 | 1653 | ||
1631 | mov ebx,[file_browser_data_1.x] |
1654 | mov ebx,[file_browser_data_1.x] |
1632 | mov ecx,[file_browser_data_1.y] |
1655 | mov ecx,[file_browser_data_1.y] |
1633 | mcall 13,,,[file_browser_data_1.background_color] |
1656 | mcall 13,,,[file_browser_data_1.background_color] |
1634 | push ebx ecx |
1657 | push ebx ecx |
1635 | add ebx,10 shl 16 |
1658 | add ebx,10 shl 16 |
1636 | sub ebx,20 |
1659 | sub ebx,20 |
1637 | add ecx,10 shl 16 |
1660 | add ecx,10 shl 16 |
1638 | sub ecx,20 |
1661 | sub ecx,20 |
1639 | mov edx,0xff0000 |
1662 | mov edx,0xff0000 |
1640 | mcall |
1663 | mcall |
1641 | 1664 | ||
1642 | shr ecx,16 |
1665 | shr ecx,16 |
1643 | mov bx,cx |
1666 | mov bx,cx |
1644 | add ebx,5 shl 16+15 |
1667 | add ebx,5 shl 16+15 |
1645 | mcall 4,,0x90ffffff,load_directory_error_type |
1668 | mcall 4,,0x90ffffff,load_directory_error_type |
1646 | 1669 | ||
1647 | add ebx,20 |
1670 | add ebx,20 |
1648 | mcall 4,,,dir_path |
1671 | mcall 4,,,dir_path |
1649 | 1672 | ||
1650 | mov eax,[error_type] |
1673 | mov eax,[error_type] |
1651 | shl eax,2 |
1674 | shl eax,2 |
1652 | add eax,error_fs_text_pointers |
1675 | add eax,error_fs_text_pointers |
1653 | mov edx,[eax] |
1676 | mov edx,[eax] |
1654 | add ebx,20 |
1677 | add ebx,20 |
1655 | mcall 4 |
1678 | mcall 4 |
1656 | 1679 | ||
1657 | pop ecx ebx |
1680 | pop ecx ebx |
1658 | 1681 | ||
1659 | mov ebx,[file_browser_data_1.x] |
1682 | mov ebx,[file_browser_data_1.x] |
1660 | mov ax,bx |
1683 | mov ax,bx |
1661 | shr eax,1 |
1684 | shr eax,1 |
1662 | shl eax,16 |
1685 | shl eax,16 |
1663 | add ebx,eax |
1686 | add ebx,eax |
1664 | mov eax,50 |
1687 | mov eax,50 |
1665 | mov bx,ax |
1688 | mov bx,ax |
1666 | shr eax,1 |
1689 | shr eax,1 |
1667 | shl eax,16 |
1690 | shl eax,16 |
1668 | sub ebx,eax |
1691 | sub ebx,eax |
1669 | 1692 | ||
1670 | mov ecx,[file_browser_data_1.y] |
1693 | mov ecx,[file_browser_data_1.y] |
1671 | mov ax,cx |
1694 | mov ax,cx |
1672 | sub eax,40 |
1695 | sub eax,40 |
1673 | shl eax,16 |
1696 | shl eax,16 |
1674 | add ecx,eax |
1697 | add ecx,eax |
1675 | mov cx,15 |
1698 | mov cx,15 |
1676 | 1699 | ||
1677 | mcall 8,,,5,0xffffff |
1700 | mcall 8,,,5,0xffffff |
1678 | 1701 | ||
1679 | shr ecx,16 |
1702 | shr ecx,16 |
1680 | mov bx,cx |
1703 | mov bx,cx |
1681 | add ebx,4 shl 16+4 |
1704 | add ebx,4 shl 16+4 |
1682 | mcall 4,,0x90000000,message_cancel_button |
1705 | mcall 4,,0x90000000,message_cancel_button |
1683 | 1706 | ||
1684 | 1707 | ||
1685 | ret |
1708 | ret |
1686 | ;--------------------------------------------------------------------- |
1709 | ;--------------------------------------------------------------------- |
1687 | draw_file_name: |
1710 | draw_file_name: |
1688 | mov esi,user_selected_name |
1711 | mov esi,user_selected_name |
1689 | cld |
1712 | cld |
1690 | @@: |
1713 | @@: |
1691 | lodsb |
1714 | lodsb |
1692 | test al,al |
1715 | test al,al |
1693 | jne @r |
1716 | jne @r |
1694 | sub esi,user_selected_name |
1717 | sub esi,user_selected_name |
1695 | mov eax,esi |
1718 | mov eax,esi |
1696 | dec eax |
1719 | dec eax |
1697 | 1720 | ||
1698 | mov edi,edit1 |
1721 | mov edi,edit1 |
1699 | mov [edi+48],eax ;ed_size |
1722 | mov [edi+48],eax ;ed_size |
1700 | mov [edi+52],eax ;ed_pos |
1723 | mov [edi+52],eax ;ed_pos |
1701 | ;-------------------------------------- |
1724 | ;-------------------------------------- |
1702 | mov eax,[file_browser_data_1.x] |
1725 | mov eax,[file_browser_data_1.x] |
1703 | mov ebx,eax |
1726 | mov ebx,eax |
1704 | shr ebx,16 |
1727 | shr ebx,16 |
1705 | and eax,0xffff |
1728 | and eax,0xffff |
1706 | sub eax,200 |
1729 | sub eax,200 |
1707 | mov [edi],eax |
1730 | mov [edi],eax |
1708 | add ebx,70 |
1731 | add ebx,70 |
1709 | mov [edi+4],ebx |
1732 | mov [edi+4],ebx |
1710 | 1733 | ||
1711 | mov eax,[file_browser_data_1.y] |
1734 | mov eax,[file_browser_data_1.y] |
1712 | mov ebx,eax |
1735 | mov ebx,eax |
1713 | shr ebx,16 |
1736 | shr ebx,16 |
1714 | and eax,0xffff |
1737 | and eax,0xffff |
1715 | add eax,ebx |
1738 | add eax,ebx |
1716 | add eax,5 |
1739 | add eax,5 |
1717 | mov [edi+8],eax |
1740 | mov [edi+8],eax |
1718 | 1741 | ||
1719 | push dword name_editboxes |
1742 | push dword name_editboxes |
1720 | call [edit_box_draw] |
1743 | call [edit_box_draw] |
1721 | 1744 | ||
1722 | mov bx,[file_browser_data_1.start_x] |
1745 | mov bx,[file_browser_data_1.start_x] |
1723 | add bx,5 |
1746 | add bx,5 |
1724 | shl ebx,16 |
1747 | shl ebx,16 |
1725 | mov bx,[file_browser_data_1.start_y] |
1748 | mov bx,[file_browser_data_1.start_y] |
1726 | add bx,[file_browser_data_1.size_y] |
1749 | add bx,[file_browser_data_1.size_y] |
1727 | add bx,9 |
1750 | add bx,9 |
1728 | mcall 4,,0x80000000,message_file_name |
1751 | mcall 4,,0x80000000,message_file_name |
1729 | ret |
1752 | ret |
1730 | ;--------------------------------------------------------------------- |
1753 | ;--------------------------------------------------------------------- |
1731 | draw_dir_path: |
1754 | draw_dir_path: |
1732 | mov eax,[file_browser_data_1.x] |
1755 | mov eax,[file_browser_data_1.x] |
1733 | mov ebx,eax |
1756 | mov ebx,eax |
1734 | shr ebx,16 |
1757 | shr ebx,16 |
1735 | add ebx,3 |
1758 | add ebx,3 |
1736 | and eax,0xffff |
1759 | and eax,0xffff |
1737 | sub eax,5 |
1760 | sub eax,5 |
1738 | 1761 | ||
1739 | mov [PathShow_data_1.area_size_x],ax |
1762 | mov [PathShow_data_1.area_size_x],ax |
1740 | mov [PathShow_data_1.start_x],bx |
1763 | mov [PathShow_data_1.start_x],bx |
1741 | ;-------------------------------------- |
1764 | ;-------------------------------------- |
1742 | ;; top line |
1765 | ;; top line |
1743 | ; mov ebx,[file_browser_data_1.x] |
1766 | ; mov ebx,[file_browser_data_1.x] |
1744 | ; mcall 13,,<7,1>,0x0 |
1767 | ; mcall 13,,<7,1>,0x0 |
1745 | ; down line |
1768 | ; down line |
1746 | ; push ebx ecx |
1769 | ; push ebx ecx |
1747 | ; mcall ,,<21,1>, |
1770 | ; mcall ,,<21,1>, |
1748 | ; pop ecx ebx |
1771 | ; pop ecx ebx |
1749 | ; left line |
1772 | ; left line |
1750 | ; push ebx |
1773 | ; push ebx |
1751 | ; mov bx,1 |
1774 | ; mov bx,1 |
1752 | ; mov cx,15 |
1775 | ; mov cx,15 |
1753 | ; mcall |
1776 | ; mcall |
1754 | ; pop ebx |
1777 | ; pop ebx |
1755 | ; right line |
1778 | ; right line |
1756 | ; mov ax,bx |
1779 | ; mov ax,bx |
1757 | ; shr ebx,16 |
1780 | ; shr ebx,16 |
1758 | ; add bx,ax |
1781 | ; add bx,ax |
1759 | ; dec ebx |
1782 | ; dec ebx |
1760 | ; shl ebx,16 |
1783 | ; shl ebx,16 |
1761 | ; mov bx,1 |
1784 | ; mov bx,1 |
1762 | ; mcall 13 |
1785 | ; mcall 13 |
1763 | ;-------------------------------------- |
1786 | ;-------------------------------------- |
1764 | mov ebx,[file_browser_data_1.x] |
1787 | mov ebx,[file_browser_data_1.x] |
1765 | sub ebx,2 |
1788 | sub ebx,2 |
1766 | add ebx,1 shl 16 |
1789 | add ebx,1 shl 16 |
1767 | mcall 13,,<8,13>,0xffffcc |
1790 | mcall 13,,<8,13>,0xffffcc |
1768 | ;-------------------------------------- |
1791 | ;-------------------------------------- |
1769 | ; prepare for PathShow |
1792 | ; prepare for PathShow |
1770 | push dword PathShow_data_1 |
1793 | push dword PathShow_data_1 |
1771 | call [PathShow_prepare] |
1794 | call [PathShow_prepare] |
1772 | 1795 | ||
1773 | ; draw for PathShow |
1796 | ; draw for PathShow |
1774 | push dword PathShow_data_1 |
1797 | push dword PathShow_data_1 |
1775 | call [PathShow_draw] |
1798 | call [PathShow_draw] |
1776 | 1799 | ||
1777 | ret |
1800 | ret |
1778 | ;--------------------------------------------------------------------- |
1801 | ;--------------------------------------------------------------------- |
1779 | draw_draw_file_browser1: |
1802 | draw_draw_file_browser1: |
1780 | call draw_dir_path |
1803 | call draw_dir_path |
1781 | cmp [open_dialog_type],1 |
1804 | cmp [open_dialog_type],1 |
1782 | jne @f |
1805 | jne @f |
1783 | call draw_file_name |
1806 | call draw_file_name |
1784 | @@: |
1807 | @@: |
1785 | xor eax,eax |
1808 | xor eax,eax |
1786 | inc eax |
1809 | inc eax |
1787 | mov [file_browser_data_1.all_redraw],eax |
1810 | mov [file_browser_data_1.all_redraw],eax |
1788 | mov [scroll_bar_data_vertical.all_redraw],eax |
1811 | mov [scroll_bar_data_vertical.all_redraw],eax |
1789 | 1812 | ||
1790 | push dword file_browser_data_1 |
1813 | push dword file_browser_data_1 |
1791 | call [FileBrowser_draw] |
1814 | call [FileBrowser_draw] |
1792 | 1815 | ||
1793 | call draw_open_button_label |
1816 | call draw_open_button_label |
1794 | 1817 | ||
1795 | call prepare_scrollbar_data |
1818 | call prepare_scrollbar_data |
1796 | 1819 | ||
1797 | call draw_scrollbar |
1820 | call draw_scrollbar |
1798 | 1821 | ||
1799 | xor eax,eax |
1822 | xor eax,eax |
1800 | mov [file_browser_data_1.all_redraw],eax |
1823 | mov [file_browser_data_1.all_redraw],eax |
1801 | mov [scroll_bar_data_vertical.all_redraw],eax |
1824 | mov [scroll_bar_data_vertical.all_redraw],eax |
1802 | ret |
1825 | ret |
1803 | ;--------------------------------------------------------------------- |
1826 | ;--------------------------------------------------------------------- |
1804 | draw_draw_file_browser2: |
1827 | draw_draw_file_browser2: |
1805 | mov eax,2 |
1828 | mov eax,2 |
1806 | mov [file_browser_data_1.all_redraw],eax |
1829 | mov [file_browser_data_1.all_redraw],eax |
1807 | 1830 | ||
1808 | call get_scrollbar_data |
1831 | call get_scrollbar_data |
1809 | 1832 | ||
1810 | push dword file_browser_data_1 |
1833 | push dword file_browser_data_1 |
1811 | call [FileBrowser_draw] |
1834 | call [FileBrowser_draw] |
1812 | 1835 | ||
1813 | call draw_open_button_label |
1836 | call draw_open_button_label |
1814 | 1837 | ||
1815 | xor eax,eax |
1838 | xor eax,eax |
1816 | mov [file_browser_data_1.all_redraw],eax |
1839 | mov [file_browser_data_1.all_redraw],eax |
1817 | ret |
1840 | ret |
1818 | ;--------------------------------------------------------------------- |
1841 | ;--------------------------------------------------------------------- |
1819 | draw_scrollbar1: |
1842 | draw_scrollbar1: |
1820 | mov eax,[file_browser_data_1.start_draw_line] |
1843 | mov eax,[file_browser_data_1.start_draw_line] |
1821 | mov [scroll_bar_data_vertical.position],eax |
1844 | mov [scroll_bar_data_vertical.position],eax |
1822 | 1845 | ||
1823 | call draw_scrollbar |
1846 | call draw_scrollbar |
1824 | 1847 | ||
1825 | ret |
1848 | ret |
1826 | ;--------------------------------------------------------------------- |
1849 | ;--------------------------------------------------------------------- |
1827 | draw_scrollbar: |
1850 | draw_scrollbar: |
1828 | mov eax,[scroll_bar_data_vertical.max_area] |
1851 | mov eax,[scroll_bar_data_vertical.max_area] |
1829 | cmp eax,[scroll_bar_data_vertical.cur_area] |
1852 | cmp eax,[scroll_bar_data_vertical.cur_area] |
1830 | jbe @f |
1853 | jbe @f |
1831 | cmp [scroll_bar_data_vertical.cur_area],0 |
1854 | cmp [scroll_bar_data_vertical.cur_area],0 |
1832 | je @f |
1855 | je @f |
1833 | push dword scroll_bar_data_vertical |
1856 | push dword scroll_bar_data_vertical |
1834 | call [scrollbar_ver_draw] |
1857 | call [scrollbar_ver_draw] |
1835 | @@: |
1858 | @@: |
1836 | ret |
1859 | ret |
1837 | ;--------------------------------------------------------------------- |
1860 | ;--------------------------------------------------------------------- |
1838 | get_scrollbar_data: |
1861 | get_scrollbar_data: |
1839 | mov eax,[scroll_bar_data_vertical.position] |
1862 | mov eax,[scroll_bar_data_vertical.position] |
1840 | mov [file_browser_data_1.start_draw_line],eax |
1863 | mov [file_browser_data_1.start_draw_line],eax |
1841 | ret |
1864 | ret |
1842 | ;--------------------------------------------------------------------- |
1865 | ;--------------------------------------------------------------------- |
1843 | prepare_scrollbar_data: |
1866 | prepare_scrollbar_data: |
1844 | mov eax,[file_browser_data_1.folder_block] |
1867 | mov eax,[file_browser_data_1.folder_block] |
1845 | mov [scroll_bar_data_vertical.max_area],eax |
1868 | mov [scroll_bar_data_vertical.max_area],eax |
1846 | mov eax,[file_browser_data_1.max_panel_line] |
1869 | mov eax,[file_browser_data_1.max_panel_line] |
1847 | mov [scroll_bar_data_vertical.cur_area],eax |
1870 | mov [scroll_bar_data_vertical.cur_area],eax |
1848 | ret |
1871 | ret |
1849 | ;--------------------------------------------------------------------- |
1872 | ;--------------------------------------------------------------------- |
1850 | get_active_pocess: |
1873 | get_active_pocess: |
1851 | mcall 9,procinfo,-1 |
1874 | mcall 9,procinfo,-1 |
1852 | mov ecx,[ebx+30] ; PID |
1875 | mov ecx,[ebx+30] ; PID |
1853 | mcall 18,21 |
1876 | mcall 18,21 |
1854 | mov [active_process],eax ; WINDOW SLOT |
1877 | mov [active_process],eax ; WINDOW SLOT |
1855 | mov ebx,[communication_area] |
1878 | mov ebx,[communication_area] |
1856 | test ebx,ebx |
1879 | test ebx,ebx |
1857 | jz .1 |
1880 | jz .1 |
1858 | mov [ebx+12],eax ; WINDOW SLOT to com. area |
1881 | mov [ebx+12],eax ; WINDOW SLOT to com. area |
1859 | .1: |
1882 | .1: |
1860 | ret |
1883 | ret |
1861 | ;--------------------------------------------------------------------- |
1884 | ;--------------------------------------------------------------------- |
1862 | get_window_param: |
1885 | get_window_param: |
1863 | mcall 9,procinfo,-1 |
1886 | mcall 9,procinfo,-1 |
1864 | mov eax,[ebx+66] |
1887 | mov eax,[ebx+66] |
1865 | inc eax |
1888 | inc eax |
1866 | mov [window_high],eax |
1889 | mov [window_high],eax |
1867 | mov eax,[ebx+62] |
1890 | mov eax,[ebx+62] |
1868 | inc eax |
1891 | inc eax |
1869 | mov [window_width],eax |
1892 | mov [window_width],eax |
1870 | mov eax,[ebx+70] |
1893 | mov eax,[ebx+70] |
1871 | mov [window_status],eax |
1894 | mov [window_status],eax |
1872 | ret |
1895 | ret |
1873 | ;--------------------------------------------------------------------- |
1896 | ;--------------------------------------------------------------------- |
1874 | convert_icons: |
1897 | convert_icons: |
1875 | xor eax,eax |
1898 | xor eax,eax |
1876 | mov [return_code],eax |
1899 | mov [return_code],eax |
1877 | ; mov eax,image_file |
1900 | ; mov eax,image_file |
1878 | push image_file |
1901 | push image_file |
1879 | call [cnv_png_import.Start] |
1902 | call [cnv_png_import.Start] |
1880 | 1903 | ||
1881 | mov ecx,[image_file] |
1904 | mov ecx,[image_file] |
1882 | mcall 68,13, |
1905 | mcall 68,13, |
1883 | test eax,eax |
1906 | test eax,eax |
1884 | jz memory_free_error |
1907 | jz memory_free_error |
1885 | 1908 | ||
1886 | cmp [return_code],dword 0 |
1909 | cmp [return_code],dword 0 |
1887 | je @f |
1910 | je @f |
1888 | mov [N_error],6 |
1911 | mov [N_error],6 |
1889 | jmp button.exit |
1912 | jmp button.exit |
1890 | @@: |
1913 | @@: |
1891 | 1914 | ||
1892 | mov ebx,[raw_pointer] |
1915 | mov ebx,[raw_pointer] |
1893 | mov eax,[ebx+4] |
1916 | mov eax,[ebx+4] |
1894 | ; set of icon size x |
1917 | ; set of icon size x |
1895 | mov [file_browser_data_1.icon_size_x],ax |
1918 | mov [file_browser_data_1.icon_size_x],ax |
1896 | ; mov eax,[ebx+8] |
1919 | ; mov eax,[ebx+8] |
1897 | ; set of icon size y |
1920 | ; set of icon size y |
1898 | mov [file_browser_data_1.icon_size_y],ax |
1921 | mov [file_browser_data_1.icon_size_y],ax |
1899 | inc ax |
1922 | inc ax |
1900 | mov [file_browser_data_1.line_size_y],ax |
1923 | mov [file_browser_data_1.line_size_y],ax |
1901 | mov eax,[ebx+12] |
1924 | mov eax,[ebx+12] |
1902 | ; set of RAW resolution to pixel |
1925 | ; set of RAW resolution to pixel |
1903 | mov [file_browser_data_1.resolution_raw],eax |
1926 | mov [file_browser_data_1.resolution_raw],eax |
1904 | 1927 | ||
1905 | mov eax,[ebx+20] |
1928 | mov eax,[ebx+20] |
1906 | add eax,ebx |
1929 | add eax,ebx |
1907 | ; set RAW palette,use else resolution 8bit or less |
1930 | ; set RAW palette,use else resolution 8bit or less |
1908 | mov [file_browser_data_1.palette_raw],eax |
1931 | mov [file_browser_data_1.palette_raw],eax |
1909 | 1932 | ||
1910 | mov eax,[ebx+28] |
1933 | mov eax,[ebx+28] |
1911 | add eax,ebx |
1934 | add eax,ebx |
1912 | ; set RAW area for icon |
1935 | ; set RAW area for icon |
1913 | mov [file_browser_data_1.icon_raw_area],eax |
1936 | mov [file_browser_data_1.icon_raw_area],eax |
1914 | ret |
1937 | ret |
1915 | ;--------------------------------------------------------------------- |
1938 | ;--------------------------------------------------------------------- |
1916 | calc_ini: |
1939 | calc_ini: |
1917 | mov eax,[image_file] |
1940 | mov eax,[image_file] |
1918 | mov [file_browser_data_1.ini_file_start],eax |
1941 | mov [file_browser_data_1.ini_file_start],eax |
1919 | add eax,[img_size] |
1942 | add eax,[img_size] |
1920 | mov [file_browser_data_1.ini_file_end],eax |
1943 | mov [file_browser_data_1.ini_file_end],eax |
1921 | ret |
1944 | ret |
1922 | ;--------------------------------------------------------------------- |
1945 | ;--------------------------------------------------------------------- |
1923 | load_ini: |
1946 | load_ini: |
1924 | mov ebx,ini_file_name |
1947 | mov ebx,ini_file_name |
1925 | mov esi,path |
1948 | mov esi,path |
1926 | mov edi,file_name |
1949 | mov edi,file_name |
1927 | call copy_file_path |
1950 | call copy_file_path |
1928 | 1951 | ||
1929 | mov [fileinfo.subfunction],dword 5 |
1952 | mov [fileinfo.subfunction],dword 5 |
1930 | mov [fileinfo.size],dword 0 |
1953 | mov [fileinfo.size],dword 0 |
1931 | mov [fileinfo.return],dword file_info |
1954 | mov [fileinfo.return],dword file_info |
1932 | mcall 70,fileinfo |
1955 | mcall 70,fileinfo |
1933 | test eax,eax |
1956 | test eax,eax |
1934 | jnz .error |
1957 | jnz .error |
1935 | 1958 | ||
1936 | mov [fileinfo.subfunction],dword 0 |
1959 | mov [fileinfo.subfunction],dword 0 |
1937 | 1960 | ||
1938 | mov ecx,[file_info+32] |
1961 | mov ecx,[file_info+32] |
1939 | mov [fileinfo.size],ecx |
1962 | mov [fileinfo.size],ecx |
1940 | mov [img_size],ecx |
1963 | mov [img_size],ecx |
1941 | 1964 | ||
1942 | mcall 68,12 |
1965 | mcall 68,12 |
1943 | test eax,eax |
1966 | test eax,eax |
1944 | jz memory_get_error |
1967 | jz memory_get_error |
1945 | 1968 | ||
1946 | mov [fileinfo.return],eax |
1969 | mov [fileinfo.return],eax |
1947 | mov [image_file],eax |
1970 | mov [image_file],eax |
1948 | 1971 | ||
1949 | mcall 70,fileinfo |
1972 | mcall 70,fileinfo |
1950 | test eax,eax |
1973 | test eax,eax |
1951 | jnz .error |
1974 | jnz .error |
1952 | ret |
1975 | ret |
1953 | .error: |
1976 | .error: |
1954 | mov [N_error],1 |
1977 | mov [N_error],1 |
1955 | mov [error_type],eax |
1978 | mov [error_type],eax |
1956 | jmp button.exit |
1979 | jmp button.exit |
1957 | ;--------------------------------------------------------------------- |
1980 | ;--------------------------------------------------------------------- |
1958 | load_icons: |
1981 | load_icons: |
1959 | mov ebx,icons_file_name_2 |
1982 | mov ebx,icons_file_name_2 |
1960 | mov esi,path |
1983 | mov esi,path |
1961 | mov edi,file_name |
1984 | mov edi,file_name |
1962 | call copy_file_path |
1985 | call copy_file_path |
1963 | 1986 | ||
1964 | mov [fileinfo.subfunction],dword 5 |
1987 | mov [fileinfo.subfunction],dword 5 |
1965 | mov [fileinfo.size],dword 0 |
1988 | mov [fileinfo.size],dword 0 |
1966 | mov [fileinfo.return],dword file_info |
1989 | mov [fileinfo.return],dword file_info |
1967 | mcall 70,fileinfo |
1990 | mcall 70,fileinfo |
1968 | test eax,eax |
1991 | test eax,eax |
1969 | jz @f |
1992 | jz @f |
1970 | 1993 | ||
1971 | mov ebx,icons_file_name |
1994 | mov ebx,icons_file_name |
1972 | mov esi,path |
1995 | mov esi,path |
1973 | mov edi,file_name |
1996 | mov edi,file_name |
1974 | call copy_file_path |
1997 | call copy_file_path |
1975 | 1998 | ||
1976 | mov [fileinfo.subfunction],dword 5 |
1999 | mov [fileinfo.subfunction],dword 5 |
1977 | mov [fileinfo.size],dword 0 |
2000 | mov [fileinfo.size],dword 0 |
1978 | mov [fileinfo.return],dword file_info |
2001 | mov [fileinfo.return],dword file_info |
1979 | mcall 70,fileinfo |
2002 | mcall 70,fileinfo |
1980 | test eax,eax |
2003 | test eax,eax |
1981 | jnz .error |
2004 | jnz .error |
1982 | @@: |
2005 | @@: |
1983 | mov [fileinfo.subfunction],dword 0 |
2006 | mov [fileinfo.subfunction],dword 0 |
1984 | 2007 | ||
1985 | mov ecx,[file_info+32] |
2008 | mov ecx,[file_info+32] |
1986 | mov [fileinfo.size],ecx |
2009 | mov [fileinfo.size],ecx |
1987 | mov [img_size],ecx |
2010 | mov [img_size],ecx |
1988 | 2011 | ||
1989 | mcall 68,12 |
2012 | mcall 68,12 |
1990 | test eax,eax |
2013 | test eax,eax |
1991 | jz memory_get_error |
2014 | jz memory_get_error |
1992 | 2015 | ||
1993 | mov [fileinfo.return],eax |
2016 | mov [fileinfo.return],eax |
1994 | mov [image_file],eax |
2017 | mov [image_file],eax |
1995 | 2018 | ||
1996 | mcall 70,fileinfo |
2019 | mcall 70,fileinfo |
1997 | test eax,eax |
2020 | test eax,eax |
1998 | jnz .error |
2021 | jnz .error |
1999 | ret |
2022 | ret |
2000 | .error: |
2023 | .error: |
2001 | mov [N_error],2 |
2024 | mov [N_error],2 |
2002 | mov [error_type],eax |
2025 | mov [error_type],eax |
2003 | jmp button.exit |
2026 | jmp button.exit |
2004 | ;--------------------------------------------------------------------- |
2027 | ;--------------------------------------------------------------------- |
2005 | sort_directory: |
2028 | sort_directory: |
2006 | mov eax,[file_browser_data_1.folder_data] |
2029 | mov eax,[file_browser_data_1.folder_data] |
2007 | mov ebx,[eax+4] ; number of files |
2030 | mov ebx,[eax+4] ; number of files |
2008 | add eax,32 |
2031 | add eax,32 |
2009 | cmp [eax+40],word '..' |
2032 | cmp [eax+40],word '..' |
2010 | jne @f |
2033 | jne @f |
2011 | cmp [eax+40+2],byte 0 |
2034 | cmp [eax+40+2],byte 0 |
2012 | jne @f |
2035 | jne @f |
2013 | dec ebx |
2036 | dec ebx |
2014 | add eax,304 |
2037 | add eax,304 |
2015 | @@: |
2038 | @@: |
2016 | push dword [sort_type] ; sort mode |
2039 | push dword [sort_type] ; sort mode |
2017 | push ebx ; number of files |
2040 | push ebx ; number of files |
2018 | push eax ; data files |
2041 | push eax ; data files |
2019 | call [sort_dir] |
2042 | call [sort_dir] |
2020 | ret |
2043 | ret |
2021 | ;-------------------------------------------------------------------- |
2044 | ;-------------------------------------------------------------------- |
2022 | load_directory: |
2045 | load_directory: |
2023 | xor eax,eax |
2046 | xor eax,eax |
2024 | mov [N_error],eax |
2047 | mov [N_error],eax |
2025 | cmp [file_browser_data_1.folder_data],eax |
2048 | cmp [file_browser_data_1.folder_data],eax |
2026 | je @f |
2049 | je @f |
2027 | mcall 68,13,[file_browser_data_1.folder_data] |
2050 | mcall 68,13,[file_browser_data_1.folder_data] |
2028 | test eax,eax |
2051 | test eax,eax |
2029 | jz memory_free_error |
2052 | jz memory_free_error |
2030 | 2053 | ||
2031 | @@: |
2054 | @@: |
2032 | mov [dirinfo.size],dword 0 |
2055 | mov [dirinfo.size],dword 0 |
2033 | mov [dirinfo.return],dir_header |
2056 | mov [dirinfo.return],dir_header |
2034 | mcall 70,dirinfo |
2057 | mcall 70,dirinfo |
2035 | test eax,eax |
2058 | test eax,eax |
2036 | jz @f |
2059 | jz @f |
2037 | ; mov esi,previous_dir_path |
2060 | ; mov esi,previous_dir_path |
2038 | ; mov edi,dir_path |
2061 | ; mov edi,dir_path |
2039 | ; call copy_dir_name.1 |
2062 | ; call copy_dir_name.1 |
2040 | ; mcall 70,dirinfo |
2063 | ; mcall 70,dirinfo |
2041 | ; test eax,eax |
2064 | ; test eax,eax |
2042 | ; jz @f |
2065 | ; jz @f |
2043 | xor ebx,ebx |
2066 | xor ebx,ebx |
2044 | mov [file_browser_data_1.folder_data],ebx |
2067 | mov [file_browser_data_1.folder_data],ebx |
2045 | jmp .error |
2068 | jmp .error |
2046 | @@: |
2069 | @@: |
2047 | 2070 | ||
2048 | mov ecx,[dir_header.totl_blocks] |
2071 | mov ecx,[dir_header.totl_blocks] |
2049 | mov [dirinfo.size],ecx |
2072 | mov [dirinfo.size],ecx |
2050 | imul ecx,304 |
2073 | imul ecx,304 |
2051 | add ecx,32 |
2074 | add ecx,32 |
2052 | mcall 68,12 |
2075 | mcall 68,12 |
2053 | test eax,eax |
2076 | test eax,eax |
2054 | jz memory_get_error |
2077 | jz memory_get_error |
2055 | 2078 | ||
2056 | mov [dirinfo.return],eax |
2079 | mov [dirinfo.return],eax |
2057 | mov [file_browser_data_1.folder_data],eax |
2080 | mov [file_browser_data_1.folder_data],eax |
2058 | 2081 | ||
2059 | mcall 70,dirinfo |
2082 | mcall 70,dirinfo |
2060 | test eax,eax |
2083 | test eax,eax |
2061 | jnz .error |
2084 | jnz .error |
2062 | 2085 | ||
2063 | ; test for empty directory |
2086 | ; test for empty directory |
2064 | mov eax,[dirinfo.return] |
2087 | mov eax,[dirinfo.return] |
2065 | mov eax,[eax+4] |
2088 | mov eax,[eax+4] |
2066 | test eax,eax |
2089 | test eax,eax |
2067 | jz @f |
2090 | jz @f |
2068 | 2091 | ||
2069 | call delete_point_dir |
2092 | call delete_point_dir |
2070 | ; call files_name_normalize |
2093 | ; call files_name_normalize |
2071 | call check_filter |
2094 | call check_filter |
2072 | call prepare_extension_and_mark |
2095 | call prepare_extension_and_mark |
2073 | call clear_data_fb_and_sb |
2096 | call clear_data_fb_and_sb |
2074 | @@: |
2097 | @@: |
2075 | ret |
2098 | ret |
2076 | 2099 | ||
2077 | .error: |
2100 | .error: |
2078 | mov [N_error],5 |
2101 | mov [N_error],5 |
2079 | mov [error_type],eax |
2102 | mov [error_type],eax |
2080 | ret |
2103 | ret |
2081 | ;--------------------------------------------------------------------- |
2104 | ;--------------------------------------------------------------------- |
2082 | clear_data_fb_and_sb: |
2105 | clear_data_fb_and_sb: |
2083 | xor eax,eax |
2106 | xor eax,eax |
2084 | mov [file_browser_data_1.start_draw_cursor_line],ax |
2107 | mov [file_browser_data_1.start_draw_cursor_line],ax |
2085 | mov [file_browser_data_1.start_draw_line],eax |
2108 | mov [file_browser_data_1.start_draw_line],eax |
2086 | mov [scroll_bar_data_vertical.position],eax |
2109 | mov [scroll_bar_data_vertical.position],eax |
2087 | ret |
2110 | ret |
2088 | ;--------------------------------------------------------------------- |
2111 | ;--------------------------------------------------------------------- |
2089 | check_filter: |
2112 | check_filter: |
2090 | cmp [open_dialog_type],2 ; Select dir |
2113 | cmp [open_dialog_type],2 ; Select dir |
2091 | je .1 |
2114 | je .1 |
2092 | xor eax,eax |
2115 | xor eax,eax |
2093 | mov al,[filter_flag] |
2116 | mov al,[filter_flag] |
2094 | test eax,eax |
2117 | test eax,eax |
2095 | jz @f |
2118 | jz @f |
2096 | 2119 | ||
2097 | mov eax,[communication_area] |
2120 | mov eax,[communication_area] |
2098 | test eax,eax |
2121 | test eax,eax |
2099 | jz @f |
2122 | jz @f |
2100 | mov eax,[eax+4096] |
2123 | mov eax,[eax+4096] |
2101 | test eax,eax |
2124 | test eax,eax |
2102 | jz @f |
2125 | jz @f |
2103 | .1: |
2126 | .1: |
2104 | call delete_unsupported_BDFE |
2127 | call delete_unsupported_BDFE |
2105 | @@: |
2128 | @@: |
2106 | ret |
2129 | ret |
2107 | ;--------------------------------------------------------------------- |
2130 | ;--------------------------------------------------------------------- |
2108 | delete_unsupported_BDFE: |
2131 | delete_unsupported_BDFE: |
2109 | mov ebx,[file_browser_data_1.folder_data] |
2132 | mov ebx,[file_browser_data_1.folder_data] |
2110 | add ebx,4 |
2133 | add ebx,4 |
2111 | xor ecx,ecx |
2134 | xor ecx,ecx |
2112 | dec ecx |
2135 | dec ecx |
2113 | 2136 | ||
2114 | mov eax,[file_browser_data_1.folder_data] |
2137 | mov eax,[file_browser_data_1.folder_data] |
2115 | add eax,32+40 |
2138 | add eax,32+40 |
2116 | sub eax,304 |
2139 | sub eax,304 |
2117 | .start: |
2140 | .start: |
2118 | inc ecx |
2141 | inc ecx |
2119 | add eax,304 |
2142 | add eax,304 |
2120 | .1: |
2143 | .1: |
2121 | cmp [ebx],ecx |
2144 | cmp [ebx],ecx |
2122 | je .end |
2145 | je .end |
2123 | cmp [eax],byte '.' |
2146 | cmp [eax],byte '.' |
2124 | jne @f |
2147 | jne @f |
2125 | cmp [eax+1],byte 0 |
2148 | cmp [eax+1],byte 0 |
2126 | je .delete |
2149 | je .delete |
2127 | @@: |
2150 | @@: |
2128 | test [eax-40],byte 0x10 |
2151 | test [eax-40],byte 0x10 |
2129 | jnz .start |
2152 | jnz .start |
2130 | 2153 | ||
2131 | cmp [open_dialog_type],2 ; Select dir |
2154 | cmp [open_dialog_type],2 ; Select dir |
2132 | je .delete |
2155 | je .delete |
2133 | 2156 | ||
2134 | push eax ebx |
2157 | push eax ebx |
2135 | mov esi,eax |
2158 | mov esi,eax |
2136 | call search_expansion |
2159 | call search_expansion |
2137 | test eax,eax |
2160 | test eax,eax |
2138 | pop ebx eax |
2161 | pop ebx eax |
2139 | jnz .delete |
2162 | jnz .delete |
2140 | 2163 | ||
2141 | push eax ebx ecx esi |
2164 | push eax ebx ecx esi |
2142 | mov edi,[communication_area] |
2165 | mov edi,[communication_area] |
2143 | add edi,4100 |
2166 | add edi,4100 |
2144 | call compare_expansion |
2167 | call compare_expansion |
2145 | test eax,eax |
2168 | test eax,eax |
2146 | pop esi ecx ebx eax |
2169 | pop esi ecx ebx eax |
2147 | jz .start |
2170 | jz .start |
2148 | 2171 | ||
2149 | ;------------------------------------------- |
2172 | ;------------------------------------------- |
2150 | .delete: |
2173 | .delete: |
2151 | dec dword [ebx] |
2174 | dec dword [ebx] |
2152 | mov esi,[ebx] |
2175 | mov esi,[ebx] |
2153 | sub esi,ecx |
2176 | sub esi,ecx |
2154 | 2177 | ||
2155 | push ecx |
2178 | push ecx |
2156 | mov ecx,esi |
2179 | mov ecx,esi |
2157 | imul ecx,304/4 |
2180 | imul ecx,304/4 |
2158 | mov edi,eax |
2181 | mov edi,eax |
2159 | sub edi,40 |
2182 | sub edi,40 |
2160 | mov esi,edi |
2183 | mov esi,edi |
2161 | add esi,304 |
2184 | add esi,304 |
2162 | cld |
2185 | cld |
2163 | rep movsd |
2186 | rep movsd |
2164 | pop ecx |
2187 | pop ecx |
2165 | 2188 | ||
2166 | jmp .1 |
2189 | jmp .1 |
2167 | .end: |
2190 | .end: |
2168 | ret |
2191 | ret |
2169 | ;--------------------------------------------------------------------- |
2192 | ;--------------------------------------------------------------------- |
2170 | search_expansion: |
2193 | search_expansion: |
2171 | mov edi,esi |
2194 | mov edi,esi |
2172 | xor eax,eax |
2195 | xor eax,eax |
2173 | @@: |
2196 | @@: |
2174 | cld |
2197 | cld |
2175 | lodsb |
2198 | lodsb |
2176 | test eax,eax |
2199 | test eax,eax |
2177 | jnz @b |
2200 | jnz @b |
2178 | mov ebx,esi |
2201 | mov ebx,esi |
2179 | dec esi |
2202 | dec esi |
2180 | @@: |
2203 | @@: |
2181 | std |
2204 | std |
2182 | lodsb |
2205 | lodsb |
2183 | cmp esi,edi |
2206 | cmp esi,edi |
2184 | jb .end_err |
2207 | jb .end_err |
2185 | cmp al,'.' |
2208 | cmp al,'.' |
2186 | jne @b |
2209 | jne @b |
2187 | 2210 | ||
2188 | add esi,2 |
2211 | add esi,2 |
2189 | sub ebx,esi |
2212 | sub ebx,esi |
2190 | mov [expansion_length],ebx |
2213 | mov [expansion_length],ebx |
2191 | cld |
2214 | cld |
2192 | xor eax,eax |
2215 | xor eax,eax |
2193 | ret |
2216 | ret |
2194 | 2217 | ||
2195 | .end_err: |
2218 | .end_err: |
2196 | cld |
2219 | cld |
2197 | xor eax,eax |
2220 | xor eax,eax |
2198 | inc eax |
2221 | inc eax |
2199 | ret |
2222 | ret |
2200 | ;--------------------------------------------------------------------- |
2223 | ;--------------------------------------------------------------------- |
2201 | compare_expansion: |
2224 | compare_expansion: |
2202 | mov ebx,[edi] |
2225 | mov ebx,[edi] |
2203 | add ebx,edi |
2226 | add ebx,edi |
2204 | add edi,3 |
2227 | add edi,3 |
2205 | .start: |
2228 | .start: |
2206 | cmp ebx,edi |
2229 | cmp ebx,edi |
2207 | jb .end_err |
2230 | jb .end_err |
2208 | mov ecx,[expansion_length] |
2231 | mov ecx,[expansion_length] |
2209 | inc edi |
2232 | inc edi |
2210 | 2233 | ||
2211 | push esi edi |
2234 | push esi edi |
2212 | @@: |
2235 | @@: |
2213 | cld |
2236 | cld |
2214 | lodsb |
2237 | lodsb |
2215 | xchg esi,edi |
2238 | xchg esi,edi |
2216 | shl eax,8 |
2239 | shl eax,8 |
2217 | lodsb |
2240 | lodsb |
2218 | xchg esi,edi |
2241 | xchg esi,edi |
2219 | call char_todown |
2242 | call char_todown |
2220 | xchg al,ah |
2243 | xchg al,ah |
2221 | call char_todown |
2244 | call char_todown |
2222 | cmp al,ah |
2245 | cmp al,ah |
2223 | jne @f |
2246 | jne @f |
2224 | dec ecx |
2247 | dec ecx |
2225 | jnz @b |
2248 | jnz @b |
2226 | jmp .end |
2249 | jmp .end |
2227 | @@: |
2250 | @@: |
2228 | pop edi esi |
2251 | pop edi esi |
2229 | jmp .start |
2252 | jmp .start |
2230 | .end: |
2253 | .end: |
2231 | pop edi esi |
2254 | pop edi esi |
2232 | xor eax,eax |
2255 | xor eax,eax |
2233 | ret |
2256 | ret |
2234 | 2257 | ||
2235 | .end_err: |
2258 | .end_err: |
2236 | xor eax,eax |
2259 | xor eax,eax |
2237 | inc eax |
2260 | inc eax |
2238 | ret |
2261 | ret |
2239 | ;--------------------------------------------------------------------- |
2262 | ;--------------------------------------------------------------------- |
2240 | prepare_extension_and_mark: |
2263 | prepare_extension_and_mark: |
2241 | mov esi,[dirinfo.return] |
2264 | mov esi,[dirinfo.return] |
2242 | mov ebp,[esi+4] |
2265 | mov ebp,[esi+4] |
2243 | add esi,32+40 |
2266 | add esi,32+40 |
2244 | .start: |
2267 | .start: |
2245 | push esi |
2268 | push esi |
2246 | call search_extension_start |
2269 | call search_extension_start |
2247 | mov eax,esi |
2270 | mov eax,esi |
2248 | pop esi |
2271 | pop esi |
2249 | sub eax,esi |
2272 | sub eax,esi |
2250 | sub ebx,esi |
2273 | sub ebx,esi |
2251 | shl eax,16 |
2274 | shl eax,16 |
2252 | mov ax,bx |
2275 | mov ax,bx |
2253 | mov [esi+300-40],eax |
2276 | mov [esi+300-40],eax |
2254 | mov [esi+299-40],byte 0 |
2277 | mov [esi+299-40],byte 0 |
2255 | add esi,304 |
2278 | add esi,304 |
2256 | dec ebp |
2279 | dec ebp |
2257 | jnz .start |
2280 | jnz .start |
2258 | ret |
2281 | ret |
2259 | ;--------------------------------------------------------------------- |
2282 | ;--------------------------------------------------------------------- |
2260 | search_extension_start: |
2283 | search_extension_start: |
2261 | mov edx,esi |
2284 | mov edx,esi |
2262 | xor eax,eax |
2285 | xor eax,eax |
2263 | cld |
2286 | cld |
2264 | @@: |
2287 | @@: |
2265 | lodsb |
2288 | lodsb |
2266 | test eax,eax |
2289 | test eax,eax |
2267 | jnz @b |
2290 | jnz @b |
2268 | dec esi |
2291 | dec esi |
2269 | dec edx |
2292 | dec edx |
2270 | push esi |
2293 | push esi |
2271 | std |
2294 | std |
2272 | @@: |
2295 | @@: |
2273 | lodsb |
2296 | lodsb |
2274 | cmp esi,edx |
2297 | cmp esi,edx |
2275 | je .end |
2298 | je .end |
2276 | cmp al,'.' |
2299 | cmp al,'.' |
2277 | jnz @b |
2300 | jnz @b |
2278 | add esi,2 |
2301 | add esi,2 |
2279 | cld |
2302 | cld |
2280 | pop ebx |
2303 | pop ebx |
2281 | ret |
2304 | ret |
2282 | .end: |
2305 | .end: |
2283 | cld |
2306 | cld |
2284 | pop esi |
2307 | pop esi |
2285 | mov ebx,esi |
2308 | mov ebx,esi |
2286 | ret |
2309 | ret |
2287 | ;--------------------------------------------------------------------- |
2310 | ;--------------------------------------------------------------------- |
2288 | delete_point_dir: |
2311 | delete_point_dir: |
2289 | mov eax,[dirinfo.return] |
2312 | mov eax,[dirinfo.return] |
2290 | cmp [eax+32+40],byte '.' |
2313 | cmp [eax+32+40],byte '.' |
2291 | jne @f |
2314 | jne @f |
2292 | cmp [eax+32+40+1],byte 0 |
2315 | cmp [eax+32+40+1],byte 0 |
2293 | jne @f |
2316 | jne @f |
2294 | mov edi,eax |
2317 | mov edi,eax |
2295 | add edi,32 |
2318 | add edi,32 |
2296 | mov esi,edi |
2319 | mov esi,edi |
2297 | add esi,304 |
2320 | add esi,304 |
2298 | mov ecx,[eax+4] |
2321 | mov ecx,[eax+4] |
2299 | dec ecx |
2322 | dec ecx |
2300 | mov [eax+4],ecx |
2323 | mov [eax+4],ecx |
2301 | imul ecx,304 |
2324 | imul ecx,304 |
2302 | shr ecx,2 |
2325 | shr ecx,2 |
2303 | cld |
2326 | cld |
2304 | rep movsd |
2327 | rep movsd |
2305 | @@: |
2328 | @@: |
2306 | ret |
2329 | ret |
2307 | ;--------------------------------------------------------------------- |
2330 | ;--------------------------------------------------------------------- |
2308 | ;files_name_normalize: |
2331 | ;files_name_normalize: |
2309 | ; mov esi,[dirinfo.return] |
2332 | ; mov esi,[dirinfo.return] |
2310 | ; mov ebp,[esi+4] |
2333 | ; mov ebp,[esi+4] |
2311 | ; add esi,32+40 |
2334 | ; add esi,32+40 |
2312 | ;.start: |
2335 | ;.start: |
2313 | ; push esi |
2336 | ; push esi |
2314 | ; mov al,[esi] |
2337 | ; mov al,[esi] |
2315 | ; call char_toupper |
2338 | ; call char_toupper |
2316 | ; mov [esi],al |
2339 | ; mov [esi],al |
2317 | ;@@: |
2340 | ;@@: |
2318 | ; inc esi |
2341 | ; inc esi |
2319 | ; mov al,[esi] |
2342 | ; mov al,[esi] |
2320 | ; test al,al |
2343 | ; test al,al |
2321 | ; jz @f |
2344 | ; jz @f |
2322 | ; call char_todown |
2345 | ; call char_todown |
2323 | ; mov [esi],al |
2346 | ; mov [esi],al |
2324 | ; jmp @b |
2347 | ; jmp @b |
2325 | ;@@: |
2348 | ;@@: |
2326 | ; pop esi |
2349 | ; pop esi |
2327 | ; add esi,304 |
2350 | ; add esi,304 |
2328 | ; dec ebp |
2351 | ; dec ebp |
2329 | ; jnz .start |
2352 | ; jnz .start |
2330 | ; ret |
2353 | ; ret |
2331 | ;--------------------------------------------------------------------- |
2354 | ;--------------------------------------------------------------------- |
2332 | char_toupper: |
2355 | char_toupper: |
2333 | ; convert character to uppercase,using cp866 encoding |
2356 | ; convert character to uppercase,using cp866 encoding |
2334 | ; in: al=symbol |
2357 | ; in: al=symbol |
2335 | ; out: al=converted symbol |
2358 | ; out: al=converted symbol |
2336 | cmp al,'a' |
2359 | cmp al,'a' |
2337 | jb .ret |
2360 | jb .ret |
2338 | cmp al,'z' |
2361 | cmp al,'z' |
2339 | jbe .az |
2362 | jbe .az |
2340 | cmp al,' ' |
2363 | cmp al,' ' |
2341 | jb .ret |
2364 | jb .ret |
2342 | cmp al,'à' |
2365 | cmp al,'à' |
2343 | jb .rus1 |
2366 | jb .rus1 |
2344 | cmp al,'ï' |
2367 | cmp al,'ï' |
2345 | ja .ret |
2368 | ja .ret |
2346 | ; 0xE0-0xEF -> 0x90-0x9F |
2369 | ; 0xE0-0xEF -> 0x90-0x9F |
2347 | sub al,'à'-'' |
2370 | sub al,'à'-'' |
2348 | .ret: |
2371 | .ret: |
2349 | ret |
2372 | ret |
2350 | .rus1: |
2373 | .rus1: |
2351 | ; 0xA0-0xAF -> 0x80-0x8F |
2374 | ; 0xA0-0xAF -> 0x80-0x8F |
2352 | .az: |
2375 | .az: |
2353 | and al,not 0x20 |
2376 | and al,not 0x20 |
2354 | ret |
2377 | ret |
2355 | ;--------------------------------------------------------------------- |
2378 | ;--------------------------------------------------------------------- |
2356 | char_todown: |
2379 | char_todown: |
2357 | ; convert character to uppercase,using cp866 encoding |
2380 | ; convert character to uppercase,using cp866 encoding |
2358 | ; in: al=symbol |
2381 | ; in: al=symbol |
2359 | ; out: al=converted symbol |
2382 | ; out: al=converted symbol |
2360 | cmp al,'A' |
2383 | cmp al,'A' |
2361 | jb .ret |
2384 | jb .ret |
2362 | cmp al,'Z' |
2385 | cmp al,'Z' |
2363 | jbe .az |
2386 | jbe .az |
2364 | cmp al,'' |
2387 | cmp al,'' |
2365 | jb .ret |
2388 | jb .ret |
2366 | cmp al,'' |
2389 | cmp al,'' |
2367 | jb .rus1 |
2390 | jb .rus1 |
2368 | cmp al,'' |
2391 | cmp al,'' |
2369 | ja .ret |
2392 | ja .ret |
2370 | ; 0x90-0x9F -> 0xE0-0xEF |
2393 | ; 0x90-0x9F -> 0xE0-0xEF |
2371 | add al,'à'-'' |
2394 | add al,'à'-'' |
2372 | .ret: |
2395 | .ret: |
2373 | ret |
2396 | ret |
2374 | .rus1: |
2397 | .rus1: |
2375 | ; 0x80-0x8F -> 0xA0-0xAF |
2398 | ; 0x80-0x8F -> 0xA0-0xAF |
2376 | .az: |
2399 | .az: |
2377 | add al,0x20 |
2400 | add al,0x20 |
2378 | ret |
2401 | ret |
2379 | ;--------------------------------------------------------------------- |
2402 | ;--------------------------------------------------------------------- |
2380 | copy_file_path: |
2403 | copy_file_path: |
2381 | xor eax,eax |
2404 | xor eax,eax |
2382 | cld |
2405 | cld |
2383 | @@: |
2406 | @@: |
2384 | lodsb |
2407 | lodsb |
2385 | stosb |
2408 | stosb |
2386 | test eax,eax |
2409 | test eax,eax |
2387 | jnz @b |
2410 | jnz @b |
2388 | mov esi,edi |
2411 | mov esi,edi |
2389 | dec esi |
2412 | dec esi |
2390 | std |
2413 | std |
2391 | @@: |
2414 | @@: |
2392 | lodsb |
2415 | lodsb |
2393 | cmp al,'/' |
2416 | cmp al,'/' |
2394 | jnz @b |
2417 | jnz @b |
2395 | mov edi,esi |
2418 | mov edi,esi |
2396 | add edi,2 |
2419 | add edi,2 |
2397 | mov esi,ebx |
2420 | mov esi,ebx |
2398 | cld |
2421 | cld |
2399 | @@: |
2422 | @@: |
2400 | lodsb |
2423 | lodsb |
2401 | stosb |
2424 | stosb |
2402 | test eax,eax |
2425 | test eax,eax |
2403 | jnz @b |
2426 | jnz @b |
2404 | ret |
2427 | ret |
2405 | ;--------------------------------------------------------------------- |
2428 | ;--------------------------------------------------------------------- |
2406 | copy_dir_path: |
2429 | copy_dir_path: |
2407 | mov ecx,esi |
2430 | mov ecx,esi |
2408 | inc ecx |
2431 | inc ecx |
2409 | inc ecx |
2432 | inc ecx |
2410 | xor eax,eax |
2433 | xor eax,eax |
2411 | cld |
2434 | cld |
2412 | @@: |
2435 | @@: |
2413 | lodsb |
2436 | lodsb |
2414 | test eax,eax |
2437 | test eax,eax |
2415 | jnz @b |
2438 | jnz @b |
2416 | 2439 | ||
2417 | cmp ecx,esi |
2440 | cmp ecx,esi |
2418 | jb @f |
2441 | jb @f |
2419 | dec esi |
2442 | dec esi |
2420 | @@: |
2443 | @@: |
2421 | mov [esi-1],byte '/' |
2444 | mov [esi-1],byte '/' |
2422 | mov edi,esi |
2445 | mov edi,esi |
2423 | mov esi,ebx |
2446 | mov esi,ebx |
2424 | @@: |
2447 | @@: |
2425 | lodsb |
2448 | lodsb |
2426 | stosb |
2449 | stosb |
2427 | test eax,eax |
2450 | test eax,eax |
2428 | jnz @b |
2451 | jnz @b |
2429 | ret |
2452 | ret |
2430 | ;--------------------------------------------------------------------- |
2453 | ;--------------------------------------------------------------------- |
2431 | copy_exit_dir: |
2454 | copy_exit_dir: |
2432 | mov ebx,esi |
2455 | mov ebx,esi |
2433 | inc ebx |
2456 | inc ebx |
2434 | xor eax,eax |
2457 | xor eax,eax |
2435 | cld |
2458 | cld |
2436 | @@: |
2459 | @@: |
2437 | lodsb |
2460 | lodsb |
2438 | test eax,eax |
2461 | test eax,eax |
2439 | jnz @b |
2462 | jnz @b |
2440 | sub esi,2 |
2463 | sub esi,2 |
2441 | std |
2464 | std |
2442 | @@: |
2465 | @@: |
2443 | lodsb |
2466 | lodsb |
2444 | cmp al,'/' |
2467 | cmp al,'/' |
2445 | jnz @b |
2468 | jnz @b |
2446 | xor eax,eax |
2469 | xor eax,eax |
2447 | cmp ebx,esi |
2470 | cmp ebx,esi |
2448 | jb @f |
2471 | jb @f |
2449 | inc esi |
2472 | inc esi |
2450 | @@: |
2473 | @@: |
2451 | mov [esi+1],al |
2474 | mov [esi+1],al |
2452 | cld |
2475 | cld |
2453 | ret |
2476 | ret |
2454 | ;--------------------------------------------------------------------- |
2477 | ;--------------------------------------------------------------------- |
2455 | copy_dir_name: |
2478 | copy_dir_name: |
2456 | push esi edi |
2479 | push esi edi |
2457 | mov esi,edi |
2480 | mov esi,edi |
2458 | mov edi,previous_dir_path |
2481 | mov edi,previous_dir_path |
2459 | call .1 |
2482 | call .1 |
2460 | pop edi esi |
2483 | pop edi esi |
2461 | .1: |
2484 | .1: |
2462 | xor eax,eax |
2485 | xor eax,eax |
- | 2486 | cmp [esi],al |
|
- | 2487 | je .exit |
|
2463 | cld |
2488 | cld |
2464 | @@: |
2489 | @@: |
2465 | lodsb |
2490 | lodsb |
2466 | stosb |
2491 | stosb |
2467 | test eax,eax |
2492 | test eax,eax |
2468 | jnz @b |
2493 | jnz @b |
- | 2494 | .exit: |
|
2469 | ret |
2495 | ret |
2470 | ;--------------------------------------------------------------------- |
2496 | ;--------------------------------------------------------------------- |
2471 | ;--------------------------------------------------------------------- |
2497 | ;--------------------------------------------------------------------- |
2472 | 2498 | ||
2473 | ;plugins_directory db 'plugins/',0 |
2499 | ;plugins_directory db 'plugins/',0 |
2474 | plugins_directory db 0 |
2500 | plugins_directory db 0 |
2475 | 2501 | ||
2476 | system_dir_Boxlib db '/sys/lib/box_lib.obj',0 |
2502 | system_dir_Boxlib db '/sys/lib/box_lib.obj',0 |
2477 | system_dir_CnvPNG db '/sys/lib/cnv_png.obj',0 |
2503 | system_dir_CnvPNG db '/sys/lib/cnv_png.obj',0 |
2478 | system_dir_Sort db '/sys/lib/sort.obj',0 |
2504 | system_dir_Sort db '/sys/lib/sort.obj',0 |
2479 | system_dir_UNPACK db '/sys/lib/archiver.obj',0 |
2505 | system_dir_UNPACK db '/sys/lib/archiver.obj',0 |
2480 | 2506 | ||
2481 | ihead_f_i: |
2507 | ihead_f_i: |
2482 | ihead_f_l db 'System error',0 |
2508 | ihead_f_l db 'System error',0 |
2483 | 2509 | ||
2484 | er_message_found_lib db 'box_lib.obj - Not found!',0 |
2510 | er_message_found_lib db 'box_lib.obj - Not found!',0 |
2485 | er_message_import db 'box_lib.obj - Wrong import!',0 |
2511 | er_message_import db 'box_lib.obj - Wrong import!',0 |
2486 | 2512 | ||
2487 | er_message_found_lib2 db 'cnv_png.obj - Not found!',0 |
2513 | er_message_found_lib2 db 'cnv_png.obj - Not found!',0 |
2488 | er_message_import2 db 'cnv_png.obj - Wrong import!',0 |
2514 | er_message_import2 db 'cnv_png.obj - Wrong import!',0 |
2489 | 2515 | ||
2490 | err_message_found_lib3 db 'sort.obj - Not found!',0 |
2516 | err_message_found_lib3 db 'sort.obj - Not found!',0 |
2491 | err_message_import3 db 'sort.obj - Wrong import!',0 |
2517 | err_message_import3 db 'sort.obj - Wrong import!',0 |
2492 | 2518 | ||
2493 | err_message_found_lib4 db 'archiver.obj - Not found!',0 |
2519 | err_message_found_lib4 db 'archiver.obj - Not found!',0 |
2494 | err_message_import4 db 'archiver.obj - Wrong import!',0 |
2520 | err_message_import4 db 'archiver.obj - Wrong import!',0 |
2495 | 2521 | ||
2496 | align 4 |
2522 | align 4 |
2497 | l_libs_start: |
2523 | l_libs_start: |
2498 | library01 l_libs system_dir_Boxlib+9,path,file_name,system_dir_Boxlib,\ |
2524 | library01 l_libs system_dir_Boxlib+9,path,file_name,system_dir_Boxlib,\ |
2499 | er_message_found_lib,ihead_f_l,Box_lib_import,er_message_import,ihead_f_i,plugins_directory |
2525 | er_message_found_lib,ihead_f_l,Box_lib_import,er_message_import,ihead_f_i,plugins_directory |
2500 | 2526 | ||
2501 | library02 l_libs system_dir_CnvPNG+9,path,file_name,system_dir_CnvPNG,\ |
2527 | library02 l_libs system_dir_CnvPNG+9,path,file_name,system_dir_CnvPNG,\ |
2502 | er_message_found_lib2,ihead_f_l,cnv_png_import,er_message_import2,ihead_f_i,plugins_directory |
2528 | er_message_found_lib2,ihead_f_l,cnv_png_import,er_message_import2,ihead_f_i,plugins_directory |
2503 | 2529 | ||
2504 | library03 l_libs system_dir_Sort+9,path,file_name,system_dir_Sort,\ |
2530 | library03 l_libs system_dir_Sort+9,path,file_name,system_dir_Sort,\ |
2505 | err_message_found_lib3,ihead_f_l,Sort_import,err_message_import3,ihead_f_i,plugins_directory |
2531 | err_message_found_lib3,ihead_f_l,Sort_import,err_message_import3,ihead_f_i,plugins_directory |
2506 | 2532 | ||
2507 | library04 l_libs system_dir_UNPACK+9,path,file_name,system_dir_UNPACK,\ |
2533 | library04 l_libs system_dir_UNPACK+9,path,file_name,system_dir_UNPACK,\ |
2508 | err_message_found_lib4,ihead_f_l,UNPACK_import,err_message_import4,ihead_f_i,plugins_directory |
2534 | err_message_found_lib4,ihead_f_l,UNPACK_import,err_message_import4,ihead_f_i,plugins_directory |
2509 | 2535 | ||
2510 | end_l_libs: |
2536 | end_l_libs: |
2511 | 2537 | ||
2512 | ;--------------------------------------------------------------------- |
2538 | ;--------------------------------------------------------------------- |
2513 | align 4 |
2539 | align 4 |
2514 | UNPACK_import: |
2540 | UNPACK_import: |
2515 | ;unpack_Version dd aUnpack_Version |
2541 | ;unpack_Version dd aUnpack_Version |
2516 | ;unpack_PluginLoad dd aUnpack_PluginLoad |
2542 | ;unpack_PluginLoad dd aUnpack_PluginLoad |
2517 | ;unpack_OpenFilePlugin dd aUnpack_OpenFilePlugin |
2543 | ;unpack_OpenFilePlugin dd aUnpack_OpenFilePlugin |
2518 | ;unpack_ClosePlugin dd aUnpack_ClosePlugin |
2544 | ;unpack_ClosePlugin dd aUnpack_ClosePlugin |
2519 | ;unpack_ReadFolder dd aUnpack_ReadFolder |
2545 | ;unpack_ReadFolder dd aUnpack_ReadFolder |
2520 | ;unpack_SetFolder dd aUnpack_SetFolder |
2546 | ;unpack_SetFolder dd aUnpack_SetFolder |
2521 | ;unpack_GetFiles dd aUnpack_GetFiles |
2547 | ;unpack_GetFiles dd aUnpack_GetFiles |
2522 | ;unpack_GetOpenPluginInfo dd aUnpack_GetOpenPluginInfo |
2548 | ;unpack_GetOpenPluginInfo dd aUnpack_GetOpenPluginInfo |
2523 | ;unpack_Getattr dd aUnpack_Getattr |
2549 | ;unpack_Getattr dd aUnpack_Getattr |
2524 | ;unpack_Open dd aUnpack_Open |
2550 | ;unpack_Open dd aUnpack_Open |
2525 | ;unpack_Read dd aUnpack_Read |
2551 | ;unpack_Read dd aUnpack_Read |
2526 | ;unpack_Setpos dd aUnpack_Setpos |
2552 | ;unpack_Setpos dd aUnpack_Setpos |
2527 | ;unpack_Close dd aUnpack_Close |
2553 | ;unpack_Close dd aUnpack_Close |
2528 | ;unpack_DeflateUnpack dd aUnpack_DeflateUnpack |
2554 | ;unpack_DeflateUnpack dd aUnpack_DeflateUnpack |
2529 | unpack_DeflateUnpack2 dd aUnpack_DeflateUnpack2 |
2555 | unpack_DeflateUnpack2 dd aUnpack_DeflateUnpack2 |
2530 | dd 0 |
2556 | dd 0 |
2531 | dd 0 |
2557 | dd 0 |
2532 | 2558 | ||
2533 | ;aUnpack_Version db 'version',0 |
2559 | ;aUnpack_Version db 'version',0 |
2534 | ;aUnpack_PluginLoad db 'plugin_load',0 |
2560 | ;aUnpack_PluginLoad db 'plugin_load',0 |
2535 | ;aUnpack_OpenFilePlugin db 'OpenFilePlugin',0 |
2561 | ;aUnpack_OpenFilePlugin db 'OpenFilePlugin',0 |
2536 | ;aUnpack_ClosePlugin db 'ClosePlugin',0 |
2562 | ;aUnpack_ClosePlugin db 'ClosePlugin',0 |
2537 | ;aUnpack_ReadFolder db 'ReadFolder',0 |
2563 | ;aUnpack_ReadFolder db 'ReadFolder',0 |
2538 | ;aUnpack_SetFolder db 'SetFolder',0 |
2564 | ;aUnpack_SetFolder db 'SetFolder',0 |
2539 | ;aUnpack_GetFiles db 'GetFiles',0 |
2565 | ;aUnpack_GetFiles db 'GetFiles',0 |
2540 | ;aUnpack_GetOpenPluginInfo db 'GetOpenPluginInfo',0 |
2566 | ;aUnpack_GetOpenPluginInfo db 'GetOpenPluginInfo',0 |
2541 | ;aUnpack_Getattr db 'getattr',0 |
2567 | ;aUnpack_Getattr db 'getattr',0 |
2542 | ;aUnpack_Open db 'open',0 |
2568 | ;aUnpack_Open db 'open',0 |
2543 | ;aUnpack_Read db 'read',0 |
2569 | ;aUnpack_Read db 'read',0 |
2544 | ;aUnpack_Setpos db 'setpos',0 |
2570 | ;aUnpack_Setpos db 'setpos',0 |
2545 | ;aUnpack_Close db 'close',0 |
2571 | ;aUnpack_Close db 'close',0 |
2546 | ;aUnpack_DeflateUnpack db 'deflate_unpack',0 |
2572 | ;aUnpack_DeflateUnpack db 'deflate_unpack',0 |
2547 | aUnpack_DeflateUnpack2 db 'deflate_unpack2',0 |
2573 | aUnpack_DeflateUnpack2 db 'deflate_unpack2',0 |
2548 | 2574 | ||
2549 | ;--------------------------------------------------------------------- |
2575 | ;--------------------------------------------------------------------- |
2550 | ;--------------------------------------------------------------------- |
2576 | ;--------------------------------------------------------------------- |
2551 | align 4 |
2577 | align 4 |
2552 | Sort_import: |
2578 | Sort_import: |
2553 | sort_init dd aSort_init |
2579 | sort_init dd aSort_init |
2554 | sort_version dd aSort_version |
2580 | sort_version dd aSort_version |
2555 | sort_dir dd aSort_SortDir |
2581 | sort_dir dd aSort_SortDir |
2556 | sort_strcmpi dd aSort_strcmpi |
2582 | sort_strcmpi dd aSort_strcmpi |
2557 | dd 0 |
2583 | dd 0 |
2558 | dd 0 |
2584 | dd 0 |
2559 | 2585 | ||
2560 | aSort_init db 'START',0 |
2586 | aSort_init db 'START',0 |
2561 | aSort_version db 'version',0 |
2587 | aSort_version db 'version',0 |
2562 | aSort_SortDir db 'SortDir',0 |
2588 | aSort_SortDir db 'SortDir',0 |
2563 | aSort_strcmpi db 'strcmpi',0 |
2589 | aSort_strcmpi db 'strcmpi',0 |
2564 | 2590 | ||
2565 | ;--------------------------------------------------------------------- |
2591 | ;--------------------------------------------------------------------- |
2566 | align 4 |
2592 | align 4 |
2567 | cnv_png_import: |
2593 | cnv_png_import: |
2568 | .Start dd aCP_Start |
2594 | .Start dd aCP_Start |
2569 | .Version dd aCP_Version |
2595 | .Version dd aCP_Version |
2570 | .Check dd aCP_Check |
2596 | .Check dd aCP_Check |
2571 | .Assoc dd aCP_Assoc |
2597 | .Assoc dd aCP_Assoc |
2572 | dd 0 |
2598 | dd 0 |
2573 | dd 0 |
2599 | dd 0 |
2574 | aCP_Start db 'START',0 |
2600 | aCP_Start db 'START',0 |
2575 | aCP_Version db 'version',0 |
2601 | aCP_Version db 'version',0 |
2576 | aCP_Check db 'Check_Header',0 |
2602 | aCP_Check db 'Check_Header',0 |
2577 | aCP_Assoc db 'Associations',0 |
2603 | aCP_Assoc db 'Associations',0 |
2578 | ;--------------------------------------------------------------------- |
2604 | ;--------------------------------------------------------------------- |
2579 | align 4 |
2605 | align 4 |
2580 | Box_lib_import: |
2606 | Box_lib_import: |
2581 | ;init_lib dd a_init |
2607 | ;init_lib dd a_init |
2582 | ;version_lib dd a_version |
2608 | ;version_lib dd a_version |
2583 | 2609 | ||
2584 | 2610 | ||
2585 | edit_box_draw dd aEdit_box_draw |
2611 | edit_box_draw dd aEdit_box_draw |
2586 | edit_box_key dd aEdit_box_key |
2612 | edit_box_key dd aEdit_box_key |
2587 | edit_box_mouse dd aEdit_box_mouse |
2613 | edit_box_mouse dd aEdit_box_mouse |
2588 | ;version_ed dd aVersion_ed |
2614 | ;version_ed dd aVersion_ed |
2589 | 2615 | ||
2590 | ;check_box_draw dd aCheck_box_draw |
2616 | ;check_box_draw dd aCheck_box_draw |
2591 | ;check_box_mouse dd aCheck_box_mouse |
2617 | ;check_box_mouse dd aCheck_box_mouse |
2592 | ;version_ch dd aVersion_ch |
2618 | ;version_ch dd aVersion_ch |
2593 | 2619 | ||
2594 | ;option_box_draw dd aOption_box_draw |
2620 | ;option_box_draw dd aOption_box_draw |
2595 | ;option_box_mouse dd aOption_box_mouse |
2621 | ;option_box_mouse dd aOption_box_mouse |
2596 | ;version_op dd aVersion_op |
2622 | ;version_op dd aVersion_op |
2597 | 2623 | ||
2598 | scrollbar_ver_draw dd aScrollbar_ver_draw |
2624 | scrollbar_ver_draw dd aScrollbar_ver_draw |
2599 | scrollbar_ver_mouse dd aScrollbar_ver_mouse |
2625 | scrollbar_ver_mouse dd aScrollbar_ver_mouse |
2600 | ;scrollbar_hor_draw dd aScrollbar_hor_draw |
2626 | ;scrollbar_hor_draw dd aScrollbar_hor_draw |
2601 | ;scrollbar_hor_mouse dd aScrollbar_hor_mouse |
2627 | ;scrollbar_hor_mouse dd aScrollbar_hor_mouse |
2602 | ;version_scrollbar dd aVersion_scrollbar |
2628 | ;version_scrollbar dd aVersion_scrollbar |
2603 | 2629 | ||
2604 | ;dinamic_button_draw dd aDbutton_draw |
2630 | ;dinamic_button_draw dd aDbutton_draw |
2605 | ;dinamic_button_mouse dd aDbutton_mouse |
2631 | ;dinamic_button_mouse dd aDbutton_mouse |
2606 | ;version_dbutton dd aVersion_dbutton |
2632 | ;version_dbutton dd aVersion_dbutton |
2607 | 2633 | ||
2608 | menu_bar_draw dd aMenu_bar_draw |
2634 | menu_bar_draw dd aMenu_bar_draw |
2609 | menu_bar_mouse dd aMenu_bar_mouse |
2635 | menu_bar_mouse dd aMenu_bar_mouse |
2610 | menu_bar_activate dd aMenu_bar_activate |
2636 | menu_bar_activate dd aMenu_bar_activate |
2611 | ;version_menu_bar dd aVersion_menu_bar |
2637 | ;version_menu_bar dd aVersion_menu_bar |
2612 | 2638 | ||
2613 | FileBrowser_draw dd aFileBrowser_draw |
2639 | FileBrowser_draw dd aFileBrowser_draw |
2614 | FileBrowser_mouse dd aFileBrowser_mouse |
2640 | FileBrowser_mouse dd aFileBrowser_mouse |
2615 | FileBrowser_key dd aFileBrowser_key |
2641 | FileBrowser_key dd aFileBrowser_key |
2616 | ;Version_FileBrowser dd aVersion_FileBrowser |
2642 | ;Version_FileBrowser dd aVersion_FileBrowser |
2617 | 2643 | ||
2618 | PathShow_prepare dd sz_PathShow_prepare |
2644 | PathShow_prepare dd sz_PathShow_prepare |
2619 | PathShow_draw dd sz_PathShow_draw |
2645 | PathShow_draw dd sz_PathShow_draw |
2620 | ;Version_path_show dd szVersion_path_show |
2646 | ;Version_path_show dd szVersion_path_show |
2621 | dd 0 |
2647 | dd 0 |
2622 | dd 0 |
2648 | dd 0 |
2623 | 2649 | ||
2624 | ;a_init db 'lib_init',0 |
2650 | ;a_init db 'lib_init',0 |
2625 | ;a_version db 'version',0 |
2651 | ;a_version db 'version',0 |
2626 | 2652 | ||
2627 | aEdit_box_draw db 'edit_box',0 |
2653 | aEdit_box_draw db 'edit_box',0 |
2628 | aEdit_box_key db 'edit_box_key',0 |
2654 | aEdit_box_key db 'edit_box_key',0 |
2629 | aEdit_box_mouse db 'edit_box_mouse',0 |
2655 | aEdit_box_mouse db 'edit_box_mouse',0 |
2630 | ;aVersion_ed db 'version_ed',0 |
2656 | ;aVersion_ed db 'version_ed',0 |
2631 | 2657 | ||
2632 | ;aCheck_box_draw db 'check_box_draw',0 |
2658 | ;aCheck_box_draw db 'check_box_draw',0 |
2633 | ;aCheck_box_mouse db 'check_box_mouse',0 |
2659 | ;aCheck_box_mouse db 'check_box_mouse',0 |
2634 | ;aVersion_ch db 'version_ch',0 |
2660 | ;aVersion_ch db 'version_ch',0 |
2635 | 2661 | ||
2636 | ;aOption_box_draw db 'option_box_draw',0 |
2662 | ;aOption_box_draw db 'option_box_draw',0 |
2637 | ;aOption_box_mouse db 'option_box_mouse',0 |
2663 | ;aOption_box_mouse db 'option_box_mouse',0 |
2638 | ;aVersion_op db 'version_op',0 |
2664 | ;aVersion_op db 'version_op',0 |
2639 | 2665 | ||
2640 | aScrollbar_ver_draw db 'scrollbar_v_draw',0 |
2666 | aScrollbar_ver_draw db 'scrollbar_v_draw',0 |
2641 | aScrollbar_ver_mouse db 'scrollbar_v_mouse',0 |
2667 | aScrollbar_ver_mouse db 'scrollbar_v_mouse',0 |
2642 | ;aScrollbar_hor_draw db 'scrollbar_h_draw',0 |
2668 | ;aScrollbar_hor_draw db 'scrollbar_h_draw',0 |
2643 | ;aScrollbar_hor_mouse db 'scrollbar_h_mouse',0 |
2669 | ;aScrollbar_hor_mouse db 'scrollbar_h_mouse',0 |
2644 | ;aVersion_scrollbar db 'version_scrollbar',0 |
2670 | ;aVersion_scrollbar db 'version_scrollbar',0 |
2645 | 2671 | ||
2646 | ;aDbutton_draw db 'dbutton_draw',0 |
2672 | ;aDbutton_draw db 'dbutton_draw',0 |
2647 | ;aDbutton_mouse db 'dbutton_mouse',0 |
2673 | ;aDbutton_mouse db 'dbutton_mouse',0 |
2648 | ;aVersion_dbutton db 'version_dbutton',0 |
2674 | ;aVersion_dbutton db 'version_dbutton',0 |
2649 | 2675 | ||
2650 | aMenu_bar_draw db 'menu_bar_draw',0 |
2676 | aMenu_bar_draw db 'menu_bar_draw',0 |
2651 | aMenu_bar_mouse db 'menu_bar_mouse',0 |
2677 | aMenu_bar_mouse db 'menu_bar_mouse',0 |
2652 | aMenu_bar_activate db 'menu_bar_activate',0 |
2678 | aMenu_bar_activate db 'menu_bar_activate',0 |
2653 | ;aVersion_menu_bar db 'version_menu_bar',0 |
2679 | ;aVersion_menu_bar db 'version_menu_bar',0 |
2654 | 2680 | ||
2655 | aFileBrowser_draw db 'FileBrowser_draw',0 |
2681 | aFileBrowser_draw db 'FileBrowser_draw',0 |
2656 | aFileBrowser_mouse db 'FileBrowser_mouse',0 |
2682 | aFileBrowser_mouse db 'FileBrowser_mouse',0 |
2657 | aFileBrowser_key db 'FileBrowser_key',0 |
2683 | aFileBrowser_key db 'FileBrowser_key',0 |
2658 | ;aVersion_FileBrowser db 'version_FileBrowser',0 |
2684 | ;aVersion_FileBrowser db 'version_FileBrowser',0 |
2659 | 2685 | ||
2660 | sz_PathShow_prepare db 'PathShow_prepare',0 |
2686 | sz_PathShow_prepare db 'PathShow_prepare',0 |
2661 | sz_PathShow_draw db 'PathShow_draw',0 |
2687 | sz_PathShow_draw db 'PathShow_draw',0 |
2662 | ;szVersion_path_show db 'version_PathShow',0 |
2688 | ;szVersion_path_show db 'version_PathShow',0 |
2663 | ;--------------------------------------------------------------------- |
2689 | ;--------------------------------------------------------------------- |
2664 | ;--------------------------------------------------------------------- |
2690 | ;--------------------------------------------------------------------- |
2665 | align 4 |
2691 | align 4 |
2666 | window_high dd 0 |
2692 | window_high dd 0 |
2667 | window_width dd 0 |
2693 | window_width dd 0 |
2668 | window_status dd 0 |
2694 | window_status dd 0 |
2669 | 2695 | ||
2670 | active_process dd 0 |
2696 | active_process dd 0 |
2671 | PID dd 0 |
2697 | PID dd 0 |
2672 | sort_type dd 2 |
2698 | sort_type dd 2 |
2673 | root_folder_area dd 0 |
2699 | root_folder_area dd 0 |
2674 | root_folder_block dd 0 |
2700 | root_folder_block dd 0 |
2675 | root1_folder_area dd 0 |
2701 | root1_folder_area dd 0 |
2676 | root1_folder_block dd 0 |
2702 | root1_folder_block dd 0 |
2677 | temp_counter_1 dd 0 |
2703 | temp_counter_1 dd 0 |
2678 | retrieved_devices_table_counter dd 0 |
2704 | retrieved_devices_table_counter dd 0 |
2679 | communication_area dd 0 |
2705 | communication_area dd 0 |
2680 | open_dialog_type dd 0 |
2706 | open_dialog_type dd 0 |
2681 | 2707 | ||
2682 | open_dialog_title_pointer: |
2708 | open_dialog_title_pointer: |
2683 | dd title_0 |
2709 | dd title_0 |
2684 | dd title_1 |
2710 | dd title_1 |
2685 | dd title_2 |
2711 | dd title_2 |
2686 | dd 0 |
2712 | dd 0 |
2687 | 2713 | ||
2688 | message_open_dialog_button: |
2714 | message_open_dialog_button: |
2689 | dd message_0 |
2715 | dd message_0 |
2690 | dd message_1 |
2716 | dd message_1 |
2691 | dd message_2 |
2717 | dd message_2 |
2692 | dd 0 |
2718 | dd 0 |
2693 | ;--------------------------------------------------------------------- |
2719 | ;--------------------------------------------------------------------- |
2694 | expansion_length dd 0 |
2720 | expansion_length dd 0 |
2695 | ;--------------------------------------------------------------------- |
2721 | ;--------------------------------------------------------------------- |
2696 | N_error dd 0 |
2722 | N_error dd 0 |
2697 | error_type dd 0 |
2723 | error_type dd 0 |
2698 | error_path dd 0 |
2724 | error_path dd 0 |
2699 | error_window_x: dd 100 shl 16+250 |
2725 | error_window_x: dd 100 shl 16+250 |
2700 | error_window_y: dd 100 shl 16+120 |
2726 | error_window_y: dd 100 shl 16+120 |
2701 | ;--------------------------------------------------------------------- |
2727 | ;--------------------------------------------------------------------- |
2702 | mouse_scroll_data: |
2728 | mouse_scroll_data: |
2703 | .vertical dw 0 |
2729 | .vertical dw 0 |
2704 | .horizontal dw 0 |
2730 | .horizontal dw 0 |
2705 | 2731 | ||
2706 | mouse_position: |
2732 | mouse_position: |
2707 | .y dw 0 |
2733 | .y dw 0 |
2708 | .x dw 0 |
2734 | .x dw 0 |
2709 | ;--------------------------------------------------------------------- |
2735 | ;--------------------------------------------------------------------- |
2710 | ; not change this section!!! |
2736 | ; not change this section!!! |
2711 | ; start section |
2737 | ; start section |
2712 | ;--------------------------------------------------------------------- |
2738 | ;--------------------------------------------------------------------- |
2713 | align 4 |
2739 | align 4 |
2714 | image_file dd 0 |
2740 | image_file dd 0 |
2715 | raw_pointer dd 0 |
2741 | raw_pointer dd 0 |
2716 | return_code dd 0 |
2742 | return_code dd 0 |
2717 | img_size dd 0 |
2743 | img_size dd 0 |
2718 | deflate_unpack dd 0 |
2744 | deflate_unpack dd 0 |
2719 | raw_pointer_2 dd 0 ;+20 |
2745 | raw_pointer_2 dd 0 ;+20 |
2720 | ;--------------------------------------------------------------------- |
2746 | ;--------------------------------------------------------------------- |
2721 | ; end section |
2747 | ; end section |
2722 | ;--------------------------------------------------------------------- |
2748 | ;--------------------------------------------------------------------- |
2723 | align 4 |
2749 | align 4 |
2724 | fileinfo: |
2750 | fileinfo: |
2725 | .subfunction dd 5 |
2751 | .subfunction dd 5 |
2726 | .Offset dd 0 |
2752 | .Offset dd 0 |
2727 | .Offset_1 dd 0 |
2753 | .Offset_1 dd 0 |
2728 | .size dd 0 |
2754 | .size dd 0 |
2729 | .return dd file_info |
2755 | .return dd file_info |
2730 | db 0 |
2756 | db 0 |
2731 | .name: dd file_name |
2757 | .name: dd file_name |
2732 | ;--------------------------------------------------------------------- |
2758 | ;--------------------------------------------------------------------- |
2733 | align 4 |
2759 | align 4 |
2734 | dirinfo: |
2760 | dirinfo: |
2735 | .subfunction dd 1 |
2761 | .subfunction dd 1 |
2736 | .start dd 0 |
2762 | .start dd 0 |
2737 | .flags dd 0 |
2763 | .flags dd 0 |
2738 | .size dd 0 |
2764 | .size dd 0 |
2739 | .return dd 0 |
2765 | .return dd 0 |
2740 | db 0 |
2766 | db 0 |
2741 | .name: dd dir_path |
2767 | .name: dd dir_path |
2742 | ;--------------------------------------------------------------------- |
2768 | ;--------------------------------------------------------------------- |
2743 | align 4 |
2769 | align 4 |
2744 | dir_header: |
2770 | dir_header: |
2745 | .version dd 0 ;+0 |
2771 | .version dd 0 ;+0 |
2746 | .curn_blocks dd 0 ;+4 |
2772 | .curn_blocks dd 0 ;+4 |
2747 | .totl_blocks dd 0 ;+8 |
2773 | .totl_blocks dd 0 ;+8 |
2748 | .other rb 20 |
2774 | .other rb 20 |
2749 | ;--------------------------------------------------------------------- |
2775 | ;--------------------------------------------------------------------- |
2750 | load_ini_error_type: |
2776 | load_ini_error_type: |
2751 | db 'Error loading INI file',0 |
2777 | db 'Error loading INI file',0 |
2752 | 2778 | ||
2753 | load_icons_error_type: |
2779 | load_icons_error_type: |
2754 | db 'Error loading of icons file',0 |
2780 | db 'Error loading of icons file',0 |
2755 | 2781 | ||
2756 | memory_free_error_type: |
2782 | memory_free_error_type: |
2757 | db 'Error of free memory',0 |
2783 | db 'Error of free memory',0 |
2758 | 2784 | ||
2759 | memory_get_error_type: |
2785 | memory_get_error_type: |
2760 | db 'Memory allocation error',0 |
2786 | db 'Memory allocation error',0 |
2761 | 2787 | ||
2762 | load_directory_error_type: |
2788 | load_directory_error_type: |
2763 | db 'Error loading directory',0 |
2789 | db 'Error loading directory',0 |
2764 | 2790 | ||
2765 | convert_icons_error_type: |
2791 | convert_icons_error_type: |
2766 | db 'Unsupported or corrupt data for icons file',0 |
2792 | db 'Unsupported or corrupt data for icons file',0 |
2767 | ;--------------------------------------------------------------------- |
2793 | ;--------------------------------------------------------------------- |
2768 | align 4 |
2794 | align 4 |
2769 | error_fs_text_pointers: |
2795 | error_fs_text_pointers: |
2770 | dd error_fs_text_0 |
2796 | dd error_fs_text_0 |
2771 | dd error_fs_text_1 |
2797 | dd error_fs_text_1 |
2772 | dd error_fs_text_2 |
2798 | dd error_fs_text_2 |
2773 | dd error_fs_text_3 |
2799 | dd error_fs_text_3 |
2774 | dd error_fs_text_4 |
2800 | dd error_fs_text_4 |
2775 | dd error_fs_text_5 |
2801 | dd error_fs_text_5 |
2776 | dd error_fs_text_6 |
2802 | dd error_fs_text_6 |
2777 | dd error_fs_text_7 |
2803 | dd error_fs_text_7 |
2778 | dd error_fs_text_8 |
2804 | dd error_fs_text_8 |
2779 | dd error_fs_text_9 |
2805 | dd error_fs_text_9 |
2780 | dd error_fs_text_10 |
2806 | dd error_fs_text_10 |
2781 | dd error_fs_text_11 |
2807 | dd error_fs_text_11 |
2782 | 2808 | ||
2783 | error_fs_text_0: db '0 - Success full',0 |
2809 | error_fs_text_0: db '0 - Success full',0 |
2784 | error_fs_text_1: db '1 - Base and/or partition of a hard disk is not defined',0 |
2810 | error_fs_text_1: db '1 - Base and/or partition of a hard disk is not defined',0 |
2785 | error_fs_text_2: db '2 - Function is not supported for the given file system',0 |
2811 | error_fs_text_2: db '2 - Function is not supported for the given file system',0 |
2786 | error_fs_text_3: db '3 - Unknown file system',0 |
2812 | error_fs_text_3: db '3 - Unknown file system',0 |
2787 | error_fs_text_4: db '4 - Reserved, is never returned in the current implementation',0 |
2813 | error_fs_text_4: db '4 - Reserved, is never returned in the current implementation',0 |
2788 | error_fs_text_5: db '5 - File not found',0 |
2814 | error_fs_text_5: db '5 - File not found',0 |
2789 | error_fs_text_6: db '6 - End of file, EOF',0 |
2815 | error_fs_text_6: db '6 - End of file, EOF',0 |
2790 | error_fs_text_7: db '7 - Pointer lies outside of application memory',0 |
2816 | error_fs_text_7: db '7 - Pointer lies outside of application memory',0 |
2791 | error_fs_text_8: db '8 - Disk is full',0 |
2817 | error_fs_text_8: db '8 - Disk is full',0 |
2792 | error_fs_text_9: db '9 - FAT table is destroyed',0 |
2818 | error_fs_text_9: db '9 - FAT table is destroyed',0 |
2793 | error_fs_text_10: db '10 - Access denied',0 |
2819 | error_fs_text_10: db '10 - Access denied',0 |
2794 | error_fs_text_11: db '11 - Device error',0 |
2820 | error_fs_text_11: db '11 - Device error',0 |
2795 | ;--------------------------------------------------------------------- |
2821 | ;--------------------------------------------------------------------- |
2796 | 2822 | ||
2797 | extended_key db 0 |
2823 | extended_key db 0 |
2798 | 2824 | ||
2799 | shift_flag db 0 |
2825 | shift_flag db 0 |
2800 | ctrl_flag db 0 |
2826 | ctrl_flag db 0 |
2801 | alt_flag db 0 |
2827 | alt_flag db 0 |
2802 | 2828 | ||
2803 | error_window db 0 |
2829 | error_window db 0 |
2804 | 2830 | ||
2805 | Tab_key db 0 |
2831 | Tab_key db 0 |
2806 | Tab_key_block db 0 |
2832 | Tab_key_block db 0 |
2807 | 2833 | ||
2808 | filter_flag db 1 |
2834 | filter_flag db 1 |
2809 | 2835 | ||
2810 | focus_pointer db 0 |
2836 | focus_pointer db 0 |
2811 | ;--------------------------------------------------------------------- |
2837 | ;--------------------------------------------------------------------- |
2812 | start_pach: |
2838 | start_pach: |
2813 | db '/rd/1',0 |
2839 | db '/rd/1',0 |
2814 | 2840 | ||
2815 | root_pach: |
2841 | root_pach: |
2816 | db '/',0 |
2842 | db '/',0 |
2817 | 2843 | ||
2818 | icons_file_name_2 db 'buttons/' |
2844 | icons_file_name_2 db 'buttons/' |
2819 | icons_file_name db 'z_icons.png',0 |
2845 | icons_file_name db 'z_icons.png',0 |
2820 | ini_file_name db 'icons.ini',0 |
2846 | ini_file_name db 'icons.ini',0 |
2821 | ;--------------------------------------------------------------------- |
2847 | ;--------------------------------------------------------------------- |
2822 | 2848 | ||
2823 | message: |
2849 | message: |
2824 | db 'Press any key...',0 |
2850 | db 'Press any key...',0 |
2825 | 2851 | ||
2826 | message_cancel_button: |
2852 | message_cancel_button: |
2827 | db 'Cancel',0 |
2853 | db 'Cancel',0 |
2828 | 2854 | ||
2829 | message_ReloadDir_button: |
2855 | message_ReloadDir_button: |
2830 | db 'Refresh',0 |
2856 | db 'Refresh',0 |
2831 | 2857 | ||
2832 | message_ExitDir_button: |
2858 | message_ExitDir_button: |
2833 | db '^',0 |
2859 | db '^',0 |
2834 | 2860 | ||
2835 | message_file_name: |
2861 | message_file_name: |
2836 | db 'File name:',0 |
2862 | db 'File name:',0 |
2837 | 2863 | ||
2838 | message_0: |
2864 | message_0: |
2839 | db ' Open ',0 |
2865 | db ' Open ',0 |
2840 | message_1: |
2866 | message_1: |
2841 | db ' Save ',0 |
2867 | db ' Save ',0 |
2842 | message_2: |
2868 | message_2: |
2843 | db 'Select',0 |
2869 | db 'Select',0 |
2844 | 2870 | ||
2845 | title_0: |
2871 | title_0: |
2846 | db 'Open Dialog',0 |
2872 | db 'Open Dialog',0 |
2847 | title_1: |
2873 | title_1: |
2848 | db 'Save Dialog',0 |
2874 | db 'Save Dialog',0 |
2849 | title_2: |
2875 | title_2: |
2850 | db 'Select Dir',0 |
2876 | db 'Select Dir',0 |
2851 | ;--------------------------------------------------------------------- |
2877 | ;--------------------------------------------------------------------- |
2852 | align 4 |
2878 | align 4 |
2853 | menu_data_1: |
2879 | menu_data_1: |
2854 | .type: dd 1 ;+0 |
2880 | .type: dd 1 ;+0 |
2855 | .x: |
2881 | .x: |
2856 | .size_x dw 80 ;+4 |
2882 | .size_x dw 80 ;+4 |
2857 | .start_x dw 10 ;+6 |
2883 | .start_x dw 10 ;+6 |
2858 | .y: |
2884 | .y: |
2859 | .size_y dw 15 ;+8 |
2885 | .size_y dw 15 ;+8 |
2860 | .start_y dw 26 ;+10 |
2886 | .start_y dw 26 ;+10 |
2861 | .text_pointer: dd menu_text_area_1 ;0 ;+12 |
2887 | .text_pointer: dd menu_text_area_1 ;0 ;+12 |
2862 | .pos_pointer: dd menu_text_area_1_1 ;0 ;+16 |
2888 | .pos_pointer: dd menu_text_area_1_1 ;0 ;+16 |
2863 | .text_end dd menu_text_area_1_1 ;0 ;+20 |
2889 | .text_end dd menu_text_area_1_1 ;0 ;+20 |
2864 | .ret_key dd 0 ;+24 |
2890 | .ret_key dd 0 ;+24 |
2865 | .mouse_keys dd 0 ;+28 |
2891 | .mouse_keys dd 0 ;+28 |
2866 | .x1: |
2892 | .x1: |
2867 | .size_x1 dw 80 ;+32 |
2893 | .size_x1 dw 80 ;+32 |
2868 | .start_x1 dw 10 ;+34 |
2894 | .start_x1 dw 10 ;+34 |
2869 | .y1: |
2895 | .y1: |
2870 | .size_y1 dw 100 ;+36 |
2896 | .size_y1 dw 100 ;+36 |
2871 | .start_y1 dw 41 ;+38 |
2897 | .start_y1 dw 41 ;+38 |
2872 | .bckg_col dd 0xffffff ;0xe5e5e5 ;+40 |
2898 | .bckg_col dd 0xffffff ;0xe5e5e5 ;+40 |
2873 | .frnt_col dd 0xff ;+44 |
2899 | .frnt_col dd 0xff ;+44 |
2874 | .menu_col dd 0xeef0ff ;0xffffff ;+48 |
2900 | .menu_col dd 0xeef0ff ;0xffffff ;+48 |
2875 | .select dd 0 ;+52 |
2901 | .select dd 0 ;+52 |
2876 | .out_select dd 0 ;+56 |
2902 | .out_select dd 0 ;+56 |
2877 | .buf_adress dd 0 ;+60 |
2903 | .buf_adress dd 0 ;+60 |
2878 | .procinfo dd procinfo ;+64 |
2904 | .procinfo dd procinfo ;+64 |
2879 | .click dd 0 ;+68 |
2905 | .click dd 0 ;+68 |
2880 | .cursor dd 0 ;+72 |
2906 | .cursor dd 0 ;+72 |
2881 | .cursor_old dd 0 ;+76 |
2907 | .cursor_old dd 0 ;+76 |
2882 | .interval dd 16 ;+80 |
2908 | .interval dd 16 ;+80 |
2883 | .cursor_max dd 0 ;+84 |
2909 | .cursor_max dd 0 ;+84 |
2884 | .extended_key dd 0 ;+88 |
2910 | .extended_key dd 0 ;+88 |
2885 | .menu_sel_col dd 0x00cc00 ;+92 |
2911 | .menu_sel_col dd 0x00cc00 ;+92 |
2886 | .bckg_text_col dd 0 ; +96 |
2912 | .bckg_text_col dd 0 ; +96 |
2887 | .frnt_text_col dd 0xffffff ;+100 |
2913 | .frnt_text_col dd 0xffffff ;+100 |
2888 | .mouse_keys_old dd 0 ;+104 |
2914 | .mouse_keys_old dd 0 ;+104 |
2889 | .font_height dd 8 ;+108 |
2915 | .font_height dd 8 ;+108 |
2890 | .cursor_out dd 0 ;+112 |
2916 | .cursor_out dd 0 ;+112 |
2891 | .get_mouse_flag dd 0 ;+116 |
2917 | .get_mouse_flag dd 0 ;+116 |
2892 | ;--------------------------------------------------------------------- |
2918 | ;--------------------------------------------------------------------- |
2893 | menu_text_area_1: |
2919 | menu_text_area_1: |
2894 | db 'Select Disk',0 |
2920 | db 'Select Disk',0 |
2895 | ;--------------------------------------------------------------------- |
2921 | ;--------------------------------------------------------------------- |
2896 | align 4 |
2922 | align 4 |
2897 | menu_data_2: |
2923 | menu_data_2: |
2898 | .type: dd 0 ;+0 |
2924 | .type: dd 0 ;+0 |
2899 | .x: |
2925 | .x: |
2900 | .size_x dw 30 ;+4 |
2926 | .size_x dw 30 ;+4 |
2901 | .start_x dw 95 ;+6 |
2927 | .start_x dw 95 ;+6 |
2902 | .y: |
2928 | .y: |
2903 | .size_y dw 15 ;+8 |
2929 | .size_y dw 15 ;+8 |
2904 | .start_y dw 26 ;+10 |
2930 | .start_y dw 26 ;+10 |
2905 | .text_pointer: dd menu_text_area_2 ;0 ;+12 |
2931 | .text_pointer: dd menu_text_area_2 ;0 ;+12 |
2906 | .pos_pointer: dd menu_text_area_2.1 ;0 ;+16 |
2932 | .pos_pointer: dd menu_text_area_2.1 ;0 ;+16 |
2907 | .text_end dd menu_text_area_2.end ;0 ;+20 |
2933 | .text_end dd menu_text_area_2.end ;0 ;+20 |
2908 | .ret_key dd 0 ;+24 |
2934 | .ret_key dd 0 ;+24 |
2909 | .mouse_keys dd 0 ;+28 |
2935 | .mouse_keys dd 0 ;+28 |
2910 | .x1: |
2936 | .x1: |
2911 | .size_x1 dw 30 ;+32 |
2937 | .size_x1 dw 30 ;+32 |
2912 | .start_x1 dw 95 ;+34 |
2938 | .start_x1 dw 95 ;+34 |
2913 | .y1: |
2939 | .y1: |
2914 | .size_y1 dw 100 ;+36 |
2940 | .size_y1 dw 100 ;+36 |
2915 | .start_y1 dw 41 ;+38 |
2941 | .start_y1 dw 41 ;+38 |
2916 | .bckg_col dd 0xffffff ; 0xe5e5e5 ;+40 |
2942 | .bckg_col dd 0xffffff ; 0xe5e5e5 ;+40 |
2917 | .frnt_col dd 0xff ;+44 |
2943 | .frnt_col dd 0xff ;+44 |
2918 | .menu_col dd 0xeef0ff ;0xffffff ;+48 |
2944 | .menu_col dd 0xeef0ff ;0xffffff ;+48 |
2919 | .select dd 0 ;+52 |
2945 | .select dd 0 ;+52 |
2920 | .out_select dd 0 ;+56 |
2946 | .out_select dd 0 ;+56 |
2921 | .buf_adress dd 0 ;+60 |
2947 | .buf_adress dd 0 ;+60 |
2922 | .procinfo dd procinfo ;+64 |
2948 | .procinfo dd procinfo ;+64 |
2923 | .click dd 0 ;+68 |
2949 | .click dd 0 ;+68 |
2924 | .cursor dd 0 ;+72 |
2950 | .cursor dd 0 ;+72 |
2925 | .cursor_old dd 0 ;+76 |
2951 | .cursor_old dd 0 ;+76 |
2926 | .interval dd 16 ;+80 |
2952 | .interval dd 16 ;+80 |
2927 | .cursor_max dd 0 ;+84 |
2953 | .cursor_max dd 0 ;+84 |
2928 | .extended_key dd 0 ;+88 |
2954 | .extended_key dd 0 ;+88 |
2929 | .menu_sel_col dd 0x00cc00 ;+92 |
2955 | .menu_sel_col dd 0x00cc00 ;+92 |
2930 | .bckg_text_col dd 0 ; +96 |
2956 | .bckg_text_col dd 0 ; +96 |
2931 | .frnt_text_col dd 0xffffff ;+100 |
2957 | .frnt_text_col dd 0xffffff ;+100 |
2932 | .mouse_keys_old dd 0 ;+104 |
2958 | .mouse_keys_old dd 0 ;+104 |
2933 | .font_height dd 8 ;+108 |
2959 | .font_height dd 8 ;+108 |
2934 | .cursor_out dd 0 ;+112 |
2960 | .cursor_out dd 0 ;+112 |
2935 | .get_mouse_flag dd 0 ;+116 |
2961 | .get_mouse_flag dd 0 ;+116 |
2936 | ;--------------------------------------------------------------------- |
2962 | ;--------------------------------------------------------------------- |
2937 | menu_text_area_2: |
2963 | menu_text_area_2: |
2938 | db 'Sort',0 |
2964 | db 'Sort',0 |
2939 | .1: |
2965 | .1: |
2940 | db 'Name',0 |
2966 | db 'Name',0 |
2941 | db 'Type',0 |
2967 | db 'Type',0 |
2942 | db 'Date',0 |
2968 | db 'Date',0 |
2943 | db 'Size',0 |
2969 | db 'Size',0 |
2944 | .end: |
2970 | .end: |
2945 | db 0 |
2971 | db 0 |
2946 | ;--------------------------------------------------------------------- |
2972 | ;--------------------------------------------------------------------- |
2947 | align 4 |
2973 | align 4 |
2948 | menu_data_3: |
2974 | menu_data_3: |
2949 | .type: dd 0 ;+0 |
2975 | .type: dd 0 ;+0 |
2950 | .x: |
2976 | .x: |
2951 | .size_x dw 45 ;+4 |
2977 | .size_x dw 45 ;+4 |
2952 | .start_x dw 130 ;+6 |
2978 | .start_x dw 130 ;+6 |
2953 | .y: |
2979 | .y: |
2954 | .size_y dw 15 ;+8 |
2980 | .size_y dw 15 ;+8 |
2955 | .start_y dw 26 ;+10 |
2981 | .start_y dw 26 ;+10 |
2956 | .text_pointer: dd menu_text_area_3 ;0 ;+12 |
2982 | .text_pointer: dd menu_text_area_3 ;0 ;+12 |
2957 | .pos_pointer: dd menu_text_area_3.1 ;0 ;+16 |
2983 | .pos_pointer: dd menu_text_area_3.1 ;0 ;+16 |
2958 | .text_end dd menu_text_area_3.end ;0 ;+20 |
2984 | .text_end dd menu_text_area_3.end ;0 ;+20 |
2959 | .ret_key dd 0 ;+24 |
2985 | .ret_key dd 0 ;+24 |
2960 | .mouse_keys dd 0 ;+28 |
2986 | .mouse_keys dd 0 ;+28 |
2961 | .x1: |
2987 | .x1: |
2962 | .size_x1 dw 95 ;+32 |
2988 | .size_x1 dw 95 ;+32 |
2963 | .start_x1 dw 130 ;+34 |
2989 | .start_x1 dw 130 ;+34 |
2964 | .y1: |
2990 | .y1: |
2965 | .size_y1 dw 100 ;+36 |
2991 | .size_y1 dw 100 ;+36 |
2966 | .start_y1 dw 41 ;+38 |
2992 | .start_y1 dw 41 ;+38 |
2967 | .bckg_col dd 0xffffff ; 0xe5e5e5 ;+40 |
2993 | .bckg_col dd 0xffffff ; 0xe5e5e5 ;+40 |
2968 | .frnt_col dd 0xff ;+44 |
2994 | .frnt_col dd 0xff ;+44 |
2969 | .menu_col dd 0xeef0ff ;0xffffff ;+48 |
2995 | .menu_col dd 0xeef0ff ;0xffffff ;+48 |
2970 | .select dd 0 ;+52 |
2996 | .select dd 0 ;+52 |
2971 | .out_select dd 0 ;+56 |
2997 | .out_select dd 0 ;+56 |
2972 | .buf_adress dd 0 ;+60 |
2998 | .buf_adress dd 0 ;+60 |
2973 | .procinfo dd procinfo ;+64 |
2999 | .procinfo dd procinfo ;+64 |
2974 | .click dd 0 ;+68 |
3000 | .click dd 0 ;+68 |
2975 | .cursor dd 0 ;+72 |
3001 | .cursor dd 0 ;+72 |
2976 | .cursor_old dd 0 ;+76 |
3002 | .cursor_old dd 0 ;+76 |
2977 | .interval dd 16 ;+80 |
3003 | .interval dd 16 ;+80 |
2978 | .cursor_max dd 0 ;+84 |
3004 | .cursor_max dd 0 ;+84 |
2979 | .extended_key dd 0 ;+88 |
3005 | .extended_key dd 0 ;+88 |
2980 | .menu_sel_col dd 0x00cc00 ;+92 |
3006 | .menu_sel_col dd 0x00cc00 ;+92 |
2981 | .bckg_text_col dd 0 ; +96 |
3007 | .bckg_text_col dd 0 ; +96 |
2982 | .frnt_text_col dd 0xffffff ;+100 |
3008 | .frnt_text_col dd 0xffffff ;+100 |
2983 | .mouse_keys_old dd 0 ;+104 |
3009 | .mouse_keys_old dd 0 ;+104 |
2984 | .font_height dd 8 ;+108 |
3010 | .font_height dd 8 ;+108 |
2985 | .cursor_out dd 0 ;+112 |
3011 | .cursor_out dd 0 ;+112 |
2986 | .get_mouse_flag dd 0 ;+116 |
3012 | .get_mouse_flag dd 0 ;+116 |
2987 | ;--------------------------------------------------------------------- |
3013 | ;--------------------------------------------------------------------- |
2988 | menu_text_area_3: |
3014 | menu_text_area_3: |
2989 | db 'Filter',0 |
3015 | db 'Filter',0 |
2990 | .1: |
3016 | .1: |
2991 | db '*.* - show all',0 |
3017 | db '*.* - show all',0 |
2992 | db 'Only supported',0 |
3018 | db 'Only supported',0 |
2993 | .end: |
3019 | .end: |
2994 | db 0 |
3020 | db 0 |
2995 | ;--------------------------------------------------------------------- |
3021 | ;--------------------------------------------------------------------- |
2996 | 3022 | ||
2997 | align 4 |
3023 | align 4 |
2998 | scroll_bar_data_vertical: |
3024 | scroll_bar_data_vertical: |
2999 | .x: |
3025 | .x: |
3000 | .size_x dw 15 ;+0 |
3026 | .size_x dw 15 ;+0 |
3001 | .start_x dw 500 ;+2 |
3027 | .start_x dw 500 ;+2 |
3002 | .y: |
3028 | .y: |
3003 | .size_y dw 300 ;+4 |
3029 | .size_y dw 300 ;+4 |
3004 | .start_y dw 45 ;+6 |
3030 | .start_y dw 45 ;+6 |
3005 | .btn_high dd 15 ;+8 |
3031 | .btn_high dd 15 ;+8 |
3006 | .type dd 2 ;+12 |
3032 | .type dd 2 ;+12 |
3007 | .max_area dd 10 ;+16 |
3033 | .max_area dd 10 ;+16 |
3008 | .cur_area dd 2 ;+20 |
3034 | .cur_area dd 2 ;+20 |
3009 | .position dd 0 ;+24 |
3035 | .position dd 0 ;+24 |
3010 | .bckg_col dd 0xeeeeee ;+28 |
3036 | .bckg_col dd 0xeeeeee ;+28 |
3011 | .frnt_col dd 0xbbddff ;+32 ;0x8aeaa0 |
3037 | .frnt_col dd 0xbbddff ;+32 ;0x8aeaa0 |
3012 | .line_col dd 0 ;+36 |
3038 | .line_col dd 0 ;+36 |
3013 | .redraw dd 0 ;+40 |
3039 | .redraw dd 0 ;+40 |
3014 | .delta dw 0 ;+44 |
3040 | .delta dw 0 ;+44 |
3015 | .delta2 dw 0 ;+46 |
3041 | .delta2 dw 0 ;+46 |
3016 | .run_x: |
3042 | .run_x: |
3017 | .r_size_x dw 0 ;+48 |
3043 | .r_size_x dw 0 ;+48 |
3018 | .r_start_x dw 0 ;+50 |
3044 | .r_start_x dw 0 ;+50 |
3019 | .run_y: |
3045 | .run_y: |
3020 | .r_size_y dw 0 ;+52 |
3046 | .r_size_y dw 0 ;+52 |
3021 | .r_start_y dw 0 ;+54 |
3047 | .r_start_y dw 0 ;+54 |
3022 | .m_pos dd 0 ;+56 |
3048 | .m_pos dd 0 ;+56 |
3023 | .m_pos_2 dd 0 ;+60 |
3049 | .m_pos_2 dd 0 ;+60 |
3024 | .m_keys dd 0 ;+64 |
3050 | .m_keys dd 0 ;+64 |
3025 | .run_size dd 0 ;+68 |
3051 | .run_size dd 0 ;+68 |
3026 | .position2 dd 0 ;+72 |
3052 | .position2 dd 0 ;+72 |
3027 | .work_size dd 0 ;+76 |
3053 | .work_size dd 0 ;+76 |
3028 | .all_redraw dd 0 ;+80 |
3054 | .all_redraw dd 0 ;+80 |
3029 | .ar_offset dd 1 ;+84 |
3055 | .ar_offset dd 1 ;+84 |
3030 | ;--------------------------------------------------------------------- |
3056 | ;--------------------------------------------------------------------- |
3031 | align 4 |
3057 | align 4 |
3032 | file_browser_data_1: |
3058 | file_browser_data_1: |
3033 | .type dd 0 ;+0 |
3059 | .type dd 0 ;+0 |
3034 | .x: |
3060 | .x: |
3035 | .size_x dw 400 ;+4 |
3061 | .size_x dw 400 ;+4 |
3036 | .start_x dw 10 ;+6 |
3062 | .start_x dw 10 ;+6 |
3037 | .y: |
3063 | .y: |
3038 | .size_y dw 550 ;+8 |
3064 | .size_y dw 550 ;+8 |
3039 | .start_y dw 45 ;+10 |
3065 | .start_y dw 45 ;+10 |
3040 | .icon_size_y dw 16 ; +12 |
3066 | .icon_size_y dw 16 ; +12 |
3041 | .icon_size_x dw 16 ; +14 |
3067 | .icon_size_x dw 16 ; +14 |
3042 | .line_size_x dw 0 ; +16 |
3068 | .line_size_x dw 0 ; +16 |
3043 | .line_size_y dw 18 ; +18 |
3069 | .line_size_y dw 18 ; +18 |
3044 | .type_size_x dw 0 ; +20 |
3070 | .type_size_x dw 0 ; +20 |
3045 | .size_size_x dw 0 ; +22 |
3071 | .size_size_x dw 0 ; +22 |
3046 | .date_size_x dw 0 ; +24 |
3072 | .date_size_x dw 0 ; +24 |
3047 | .attributes_size_x dw 0 ; +26 |
3073 | .attributes_size_x dw 0 ; +26 |
3048 | .icon_assoc_area dd 0 ; +28 |
3074 | .icon_assoc_area dd 0 ; +28 |
3049 | .icon_raw_area dd 0 ; +32 |
3075 | .icon_raw_area dd 0 ; +32 |
3050 | .resolution_raw dd 0 ; +36 |
3076 | .resolution_raw dd 0 ; +36 |
3051 | .palette_raw dd 0 ; +40 |
3077 | .palette_raw dd 0 ; +40 |
3052 | .directory_path_area dd 0 ; +44 |
3078 | .directory_path_area dd 0 ; +44 |
3053 | .file_name_area dd 0 ; +48 |
3079 | .file_name_area dd 0 ; +48 |
3054 | .select_flag dd 0 ; +52 |
3080 | .select_flag dd 0 ; +52 |
3055 | .background_color dd 0xffffff ; +56 |
3081 | .background_color dd 0xffffff ; +56 |
3056 | .select_color dd 0xbbddff ; +60 |
3082 | .select_color dd 0xbbddff ; +60 |
3057 | .seclect_text_color dd 0 ; +64 |
3083 | .seclect_text_color dd 0 ; +64 |
3058 | .text_color dd 0 ; +68 |
3084 | .text_color dd 0 ; +68 |
3059 | .reduct_text_color dd 0xff0000 ; +72 |
3085 | .reduct_text_color dd 0xff0000 ; +72 |
3060 | .marked_text_color dd 0 ; +76 |
3086 | .marked_text_color dd 0 ; +76 |
3061 | .max_panel_line dd 0 ; +80 |
3087 | .max_panel_line dd 0 ; +80 |
3062 | .select_panel_counter dd 1 ; +84 |
3088 | .select_panel_counter dd 1 ; +84 |
3063 | .folder_block dd 0 ; +88 |
3089 | .folder_block dd 0 ; +88 |
3064 | .start_draw_line dd 0 ; +92 |
3090 | .start_draw_line dd 0 ; +92 |
3065 | .start_draw_cursor_line dw 0 ; +96 ; pixels |
3091 | .start_draw_cursor_line dw 0 ; +96 ; pixels |
3066 | .folder_data dd 0 ; +98 |
3092 | .folder_data dd 0 ; +98 |
3067 | .temp_counter dd 0 ; +102 |
3093 | .temp_counter dd 0 ; +102 |
3068 | .file_name_length dd 0 ; +106 |
3094 | .file_name_length dd 0 ; +106 |
3069 | .marked_file dd 0 ; +110 |
3095 | .marked_file dd 0 ; +110 |
3070 | .extension_size dd 0 ; +114 |
3096 | .extension_size dd 0 ; +114 |
3071 | .extension_start dd 0 ; +118 |
3097 | .extension_start dd 0 ; +118 |
3072 | .type_table dd features_table ; +122 |
3098 | .type_table dd features_table ; +122 |
3073 | .ini_file_start dd 0 ; +126 |
3099 | .ini_file_start dd 0 ; +126 |
3074 | .ini_file_end dd 0 ; +130 |
3100 | .ini_file_end dd 0 ; +130 |
3075 | .draw_scroll_bar dd 0 ; +134 |
3101 | .draw_scroll_bar dd 0 ; +134 |
3076 | .font_size_y dw 9 ; +138 |
3102 | .font_size_y dw 9 ; +138 |
3077 | .font_size_x dw 6 ; +140 |
3103 | .font_size_x dw 6 ; +140 |
3078 | .mouse_keys dd 0 ; +142 |
3104 | .mouse_keys dd 0 ; +142 |
3079 | .mouse_keys_old dd 0 ; +146 |
3105 | .mouse_keys_old dd 0 ; +146 |
3080 | .mouse_pos dd 0 ; +150 |
3106 | .mouse_pos dd 0 ; +150 |
3081 | .mouse_keys_delta dd 0 ; +154 |
3107 | .mouse_keys_delta dd 0 ; +154 |
3082 | .mouse_key_delay dd 50 ; +158 |
3108 | .mouse_key_delay dd 50 ; +158 |
3083 | .mouse_keys_tick dd 0 ; +162 |
3109 | .mouse_keys_tick dd 0 ; +162 |
3084 | .start_draw_cursor_line_2 dw 0 ;+166 |
3110 | .start_draw_cursor_line_2 dw 0 ;+166 |
3085 | .all_redraw dd 0 ;+168 |
3111 | .all_redraw dd 0 ;+168 |
3086 | .selected_BDVK_adress dd 0 ;+172 |
3112 | .selected_BDVK_adress dd 0 ;+172 |
3087 | .key_action dw 0 ;+176 |
3113 | .key_action dw 0 ;+176 |
3088 | .key_action_num dw 0 ;+178 |
3114 | .key_action_num dw 0 ;+178 |
3089 | .name_temp_area dd name_temp_area ;+180 |
3115 | .name_temp_area dd name_temp_area ;+180 |
3090 | .max_name_temp_size dd 0 ;+184 |
3116 | .max_name_temp_size dd 0 ;+184 |
3091 | .display_name_max_length dd 0 ;+188 |
3117 | .display_name_max_length dd 0 ;+188 |
3092 | .draw_panel_selection_flag dd 0 ;+192 |
3118 | .draw_panel_selection_flag dd 0 ;+192 |
3093 | .mouse_pos_old dd 0 ;+196 |
3119 | .mouse_pos_old dd 0 ;+196 |
3094 | .marked_counter dd 0 ;+200 |
3120 | .marked_counter dd 0 ;+200 |
3095 | .keymap_pointer dd keymap_area ;+204 |
3121 | .keymap_pointer dd keymap_area ;+204 |
3096 | ;--------------------------------------------------------------------- |
3122 | ;--------------------------------------------------------------------- |
3097 | PathShow_data_1: |
3123 | PathShow_data_1: |
3098 | .type dd 0 ;+0 |
3124 | .type dd 0 ;+0 |
3099 | .start_y dw 11 ;+4 |
3125 | .start_y dw 11 ;+4 |
3100 | .start_x dw 10 ;+6 |
3126 | .start_x dw 10 ;+6 |
3101 | .font_size_x dw 6 ;+8 ; 6 - for font 0, 8 - for font 1 |
3127 | .font_size_x dw 6 ;+8 ; 6 - for font 0, 8 - for font 1 |
3102 | .area_size_x dw 200 ;+10 |
3128 | .area_size_x dw 200 ;+10 |
3103 | .font_number dd 0 ;+12 ; 0 - monospace, 1 - variable |
3129 | .font_number dd 0 ;+12 ; 0 - monospace, 1 - variable |
3104 | .background_flag dd 0 ;+16 |
3130 | .background_flag dd 0 ;+16 |
3105 | .font_color dd 0x0 ;+20 |
3131 | .font_color dd 0x0 ;+20 |
3106 | .background_color dd 0x0 ;+24 |
3132 | .background_color dd 0x0 ;+24 |
3107 | .text_pointer dd dir_path ;+28 |
3133 | .text_pointer dd dir_path ;+28 |
3108 | .work_area_pointer dd text_work_area ;+32 |
3134 | .work_area_pointer dd text_work_area ;+32 |
3109 | .temp_text_length dd 0 ;+36 |
3135 | .temp_text_length dd 0 ;+36 |
3110 | ;--------------------------------------------------------------------- |
3136 | ;--------------------------------------------------------------------- |
3111 | ; for EDITBOX |
3137 | ; for EDITBOX |
3112 | align 4 |
3138 | align 4 |
3113 | name_editboxes: |
3139 | name_editboxes: |
3114 | edit1 edit_box 200,10,7,0xffffff,0xbbddff,0,0,0,4095,user_selected_name,mouse_dd,,0 |
3140 | edit1 edit_box 200,10,7,0xffffff,0xbbddff,0,0,0,4095,user_selected_name,mouse_dd,,0 |
3115 | name_editboxes_end: |
3141 | name_editboxes_end: |
3116 | 3142 | ||
3117 | ;mouse_flag: dd 0x0 |
3143 | ;mouse_flag: dd 0x0 |
3118 | 3144 | ||
3119 | mouse_dd rd 1 |
3145 | mouse_dd rd 1 |
3120 | ;--------------------------------------------------------------------- |
3146 | ;--------------------------------------------------------------------- |
3121 | window_x: |
3147 | window_x: |
3122 | .x_size dw 420 |
3148 | .x_size dw 420 |
3123 | .x_start dw 10 |
3149 | .x_start dw 10 |
3124 | window_y: |
3150 | window_y: |
3125 | .y_size dw 320 |
3151 | .y_size dw 320 |
3126 | .y_start dw 10 |
3152 | .y_start dw 10 |
3127 | ;--------------------------------------------------------------------- |
3153 | ;--------------------------------------------------------------------- |
3128 | features_table: |
3154 | features_table: |
3129 | .type_table: |
3155 | .type_table: |
3130 | db ' |
3156 | db ' |
3131 | ;--------------------------------------------------------------------- |
3157 | ;--------------------------------------------------------------------- |
3132 | .size_table: |
3158 | .size_table: |
3133 | db '1023b ' |
3159 | db '1023b ' |
3134 | ;--------------------------------------------------------------------- |
3160 | ;--------------------------------------------------------------------- |
3135 | .date_table: |
3161 | .date_table: |
3136 | db '00.00.00 00:00 ' |
3162 | db '00.00.00 00:00 ' |
3137 | ;--------------------------------------------------------------------- |
3163 | ;--------------------------------------------------------------------- |
3138 | .year_table: |
3164 | .year_table: |
3139 | db ' ' |
3165 | db ' ' |
3140 | ;--------------------------------------------------------------------- |
3166 | ;--------------------------------------------------------------------- |
3141 | example_name_temp: |
3167 | example_name_temp: |
3142 | db 'temp1.asm',0 |
3168 | db 'temp1.asm',0 |
3143 | ;--------------------------------------------------------------------- |
3169 | ;--------------------------------------------------------------------- |
3144 | IM_END: |
3170 | IM_END: |
3145 | ;--------------------------------------------------------------------- |
3171 | ;--------------------------------------------------------------------- |
3146 | do_not_draw_open_button_label rb 1 |
3172 | do_not_draw_open_button_label rb 1 |
3147 | ;--------------------------------------------------------------------- |
3173 | ;--------------------------------------------------------------------- |
3148 | align 4 |
3174 | align 4 |
3149 | app_colours: |
3175 | app_colours: |
3150 | 3176 | ||
3151 | w_frame rd 1 |
3177 | w_frame rd 1 |
3152 | w_grab rd 1 |
3178 | w_grab rd 1 |
3153 | w_grab_button rd 1 |
3179 | w_grab_button rd 1 |
3154 | w_grab_button_text rd 1 |
3180 | w_grab_button_text rd 1 |
3155 | w_grab_text rd 1 |
3181 | w_grab_text rd 1 |
3156 | w_work rd 1 |
3182 | w_work rd 1 |
3157 | w_work_button rd 1 |
3183 | w_work_button rd 1 |
3158 | w_work_button_text rd 1 |
3184 | w_work_button_text rd 1 |
3159 | w_work_text rd 1 |
3185 | w_work_text rd 1 |
3160 | w_work_graph rd 1 |
3186 | w_work_graph rd 1 |
3161 | ;--------------------------------------------------------------------- |
3187 | ;--------------------------------------------------------------------- |
3162 | open_button_coordinates rd 1 |
3188 | open_button_coordinates rd 1 |
3163 | ;--------------------------------------------------------------------- |
3189 | ;--------------------------------------------------------------------- |
3164 | menu_text_area_1_1: |
3190 | menu_text_area_1_1: |
3165 | rb 256 |
3191 | rb 256 |
3166 | ;--------------------------------------------------------------------- |
3192 | ;--------------------------------------------------------------------- |
3167 | rb 1024 |
3193 | rb 1024 |
3168 | stacktop: |
3194 | stacktop: |
3169 | ;--------------------------------------------------------------------- |
3195 | ;--------------------------------------------------------------------- |
3170 | ; window error message |
3196 | ; window error message |
3171 | rb 1024 |
3197 | rb 1024 |
3172 | thread_stack: |
3198 | thread_stack: |
3173 | ;--------------------------------------------------------------------- |
3199 | ;--------------------------------------------------------------------- |
3174 | retrieved_devices_table: |
3200 | retrieved_devices_table: |
3175 | rb 200 |
3201 | rb 200 |
3176 | ;--------------------------------------------------------------------- |
3202 | ;--------------------------------------------------------------------- |
3177 | keymap_area: |
3203 | keymap_area: |
3178 | rb 128 |
3204 | rb 128 |
3179 | ;--------------------------------------------------------------------- |
3205 | ;--------------------------------------------------------------------- |
3180 | name_temp_area: |
3206 | name_temp_area: |
3181 | rb 256 |
3207 | rb 256 |
3182 | ;--------------------------------------------------------------------- |
3208 | ;--------------------------------------------------------------------- |
3183 | user_selected_name: |
3209 | user_selected_name: |
3184 | rb 256 |
3210 | rb 256 |
3185 | ;--------------------------------------------------------------------- |
3211 | ;--------------------------------------------------------------------- |
3186 | param: |
3212 | param: |
3187 | rb 256 |
3213 | rb 256 |
3188 | ;--------------------------------------------------------------------- |
3214 | ;--------------------------------------------------------------------- |
3189 | path: |
3215 | path: |
3190 | rb 4096 |
3216 | rb 4096 |
3191 | ;--------------------------------------------------------------------- |
3217 | ;--------------------------------------------------------------------- |
3192 | file_name: |
3218 | file_name: |
3193 | rb 4096 |
3219 | rb 4096 |
3194 | ;--------------------------------------------------------------------- |
3220 | ;--------------------------------------------------------------------- |
3195 | previous_dir_path: |
3221 | previous_dir_path: |
3196 | rb 4096 |
3222 | rb 4096 |
3197 | ;--------------------------------------------------------------------- |
3223 | ;--------------------------------------------------------------------- |
3198 | dir_path: |
3224 | dir_path: |
3199 | rb 4096 |
3225 | rb 4096 |
3200 | ;--------------------------------------------------------------------- |
3226 | ;--------------------------------------------------------------------- |
3201 | dir_path_temp: |
3227 | dir_path_temp: |
3202 | rb 4096 |
3228 | rb 4096 |
3203 | ;--------------------------------------------------------------------- |
3229 | ;--------------------------------------------------------------------- |
3204 | text_work_area: |
3230 | text_work_area: |
3205 | rb 1024 |
3231 | rb 1024 |
3206 | ;--------------------------------------------------------------------- |
3232 | ;--------------------------------------------------------------------- |
3207 | procinfo: |
3233 | procinfo: |
3208 | process_info: |
3234 | process_info: |
3209 | rb 1024 |
3235 | rb 1024 |
3210 | ;---------------------- |
3236 | ;---------------------- |
3211 | file_info: |
3237 | file_info: |
3212 | rb 40 |
3238 | rb 40 |
3213 | I_END:8,13>21,1>7,1>3,420>250,0>10,320>10,420>10,70>10,50>10,30>150,0>50,0> |
3239 | I_END:8,13>21,1>7,1>3,420>250,0>10,320>10,420>10,70>10,50>10,30>150,0>50,0> |