Subversion Repositories Kolibri OS

Rev

Rev 1792 | Rev 9464 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1792 Rev 3833
Line 4... Line 4...
4
    mov  [files_counter],eax
4
	mov	[files_counter],eax
5
    mov  [directories_counter],eax
5
	mov	[directories_counter],eax
6
    mov  [files_size.low],eax
6
	mov	[files_size.low],eax
7
    mov  [files_size.high],eax
7
	mov	[files_size.high],eax
8
    call get_files_information
8
	call	get_files_information
9
    mov  eax,files_size
-
 
10
    mov  ebx,type_size_string
-
 
11
    call decimal_string_20
-
 
12
    call start_files_information_thread
9
	call	start_files_information_thread
13
   jmp still
10
	jmp	still
14
;---------------------------------------------------------------------
11
;------------------------------------------------------------------------------
15
start_files_information_thread:
12
start_files_information_thread:
16
    mcall 9, procinfo, -1
13
	mcall	9,procinfo,-1
17
    mov   eax,[ebx+46]
14
	mov	eax,[ebx+46]
18
    shr   eax,1
15
	shr	eax,1
19
    add   eax,[ebx+38]
16
	add	eax,[ebx+38]
Line 24... Line 21...
24
    add   eax,[ebx+34]
21
	add	eax,[ebx+34]
25
    sub   eax,125
22
	sub	eax,125
26
    mov   [files_information_window_x+2],ax
23
	mov	[files_information_window_x+2],ax
27
    mcall 51,1,thread_files_information_start,thread_stack
24
	mcall	51,1,thread_files_information_start,thread_stack
28
    ret
25
	ret
29
;---------------------------------------------------------------------
26
;------------------------------------------------------------------------------
30
draw_files_information_window:
27
draw_files_information_window:
31
    mcall 12, 1
28
	mcall	12,1
32
    mcall 0,[files_information_window_x] ,[files_information_window_y], 0x03ffffcc
29
	mcall	0,[files_information_window_x],[files_information_window_y],0x03ffffcc
33
    mov   edx,90 shl 16+50
30
	mov	edx,100 shl 16+50
34
    mov   ebx,0xa0000
31
	mov	ebx,0x800a0000
35
    mov   esi,0x10000000
32
	mov	esi,0x10000000
36
    cmp  [inf_marked_yes],1
33
	cmp	[inf_marked_yes],1
37
    je	 .continue_4
34
	je	.continue_4
-
 
35
 
38
    cmp  [nesting_direction],1
36
	cmp	[nesting_direction],1
39
    je    @f
37
	je	@f
-
 
38
 
40
    add  edx,15
39
	add	edx,15
-
 
40
;--------------------------------------
41
.continue_4:
41
.continue_4:
-
 
42
; show files counter
42
    mcall 47, ,[files_counter]
43
	mcall	47,,[files_counter]
-
 
44
;--------------------------------------
43
@@:
45
@@:
44
    cmp  [inf_marked_yes],1
46
	cmp	[inf_marked_yes],1
45
    je	 .continue_2
47
	je	.continue_2
-
 
48
 
46
    cmp  [nesting_direction],0
49
	cmp	[nesting_direction],0
47
    je    .continue_2
50
	je	.continue_2
-
 
51
 
48
    cmp  [directories_counter],0
52
	cmp	[directories_counter],0
49
    je   @f
53
	je	@f
-
 
54
;--------------------------------------
50
.continue_2:
55
.continue_2:
-
 
56
; show directories counter
51
    add  edx,15
57
	add	edx,15
52
    mcall 47, ,[directories_counter]
58
	mcall	,,[directories_counter]
-
 
59
;--------------------------------------
53
@@:
60
@@:
-
 
61
; show file or directory size
54
    add  edx,15
62
	add	edx,15
-
 
63
	mcall	47,0x80140001,files_size
-
 
64
;--------------------------------------
55
    mov  ebx,edx
65
	mov	ebp,date.create
56
    mcall 4, ,0x90000000,type_size_string
66
	call	show_date_and_time_of_files_information
-
 
67
;--------------------------------------
-
 
68
	mov	ebp,date.change
-
 
69
	call	show_date_and_time_of_files_information
-
 
70
;--------------------------------------
-
 
71
	mov	ebp,date.access
-
 
72
	call	show_date_and_time_of_files_information
-
 
73
;--------------------------------------
57
    cmp  [select_panel_counter],0
74
	cmp	[select_panel_counter],0
58
    jne  .right_1
75
	jne	.right_1
-
 
76
 
59
    mov   edx,read_folder_name
77
	mov	edx,read_folder_name
60
    jmp  @f
78
	jmp	@f
-
 
79
;--------------------------------------
61
.right_1:
80
.right_1:
62
    mov   edx,read_folder_1_name
81
	mov	edx,read_folder_1_name
-
 
82
;--------------------------------------
63
@@:
83
@@:
64
    mcall 4,<75,35>,0x80000000,   ;file_name
84
	mcall	4,<75,35>,0x80000000,	;file_name
65
    mcall 4,<10,35>,0x90000000,type_location
85
	mcall	,<10,35>,0x90000000,type_location
66
    cmp  [inf_marked_yes],1
86
	cmp	[inf_marked_yes],1
67
    je	 .continue
87
	je	.continue
-
 
88
 
68
    mcall 4,<90,50>,0x80000000,type_name
89
	mcall	,<90,50>,0x80000000,type_name
69
    mov   ecx,0x90000000
90
	mov	ecx,0x90000000
70
    cmp  [nesting_direction],1
91
	cmp	[nesting_direction],1
71
    je    @f
92
	je	@f
-
 
93
 
72
    mcall 4,<10,50>, ,type_dir_name
94
	mcall	,<10,50>,,type_dir_name
73
    jmp   .continue
95
	jmp	.continue
-
 
96
;--------------------------------------
74
@@:
97
@@:
75
    mcall 4,<10,50>, ,type_file_name
98
	mcall	,<10,50>,,type_file_name
-
 
99
;--------------------------------------
76
.continue:
100
.continue:
77
    cmp  [inf_marked_yes],1
101
	cmp	[inf_marked_yes],1
78
    je	 .continue_3
102
	je	.continue_3
-
 
103
 
79
    cmp  [nesting_direction],1
104
	cmp	[nesting_direction],1
80
    je    @f
105
	je	@f
-
 
106
;--------------------------------------
81
.continue_3:
107
.continue_3:
82
    add   ebx,15
108
	add	ebx,15
83
    mcall 4, , ,type_files
109
	mcall	,,,type_files
-
 
110
;--------------------------------------
84
@@:
111
@@:
85
    cmp  [inf_marked_yes],1
112
	cmp	[inf_marked_yes],1
86
    je	 .continue_1
113
	je	.continue_1
-
 
114
 
87
    cmp  [nesting_direction],0
115
	cmp	[nesting_direction],0
88
    je    .continue_1
116
	je	.continue_1
-
 
117
 
89
    cmp  [directories_counter],0
118
	cmp	[directories_counter],0
90
    je   @f
119
	je	@f
-
 
120
;--------------------------------------
91
.continue_1:
121
.continue_1:
92
    add   ebx,15
122
	add	ebx,15
93
    mcall 4, , ,type_dir
123
	mcall	,,,type_dir
-
 
124
;--------------------------------------
94
@@:
125
@@:
95
    add   ebx,15
126
	add	ebx,15
96
    mcall 4, , ,type_size
127
	mcall	,,,type_size
-
 
128
	add	ebx,15
-
 
129
	mcall	,,,type_create
-
 
130
	add	ebx,15
-
 
131
	mcall	,,,type_change
-
 
132
	add	ebx,15
-
 
133
	mcall	,,,type_access
-
 
134
	sub	ebx,30
-
 
135
	add	ebx,107 shl 16
-
 
136
	mcall	,,0x80000000,type_limiters_data_time
-
 
137
	add	ebx,15
-
 
138
	mcall
-
 
139
	add	ebx,15
-
 
140
	mcall
-
 
141
 
97
    mcall 12, 2
142
	mcall	12,2
98
    ret
143
	ret
99
;---------------------------------------------------------------------
144
;------------------------------------------------------------------------------
-
 
145
show_date_and_time_of_files_information:
-
 
146
; show date
-
 
147
	add	edx,15
-
 
148
	push	edx
-
 
149
	movzx	ecx,byte [ebp+0]
-
 
150
	mcall	,0x00020000
-
 
151
	add	edx,24 shl 16
-
 
152
	movzx	ecx,byte [ebp+1]
-
 
153
	mcall
-
 
154
	add	edx,23 shl 16
-
 
155
	movzx	ecx,word [ebp+2]
-
 
156
	mcall	,0x00040000
-
 
157
	sub	ebp,12
-
 
158
; show time
-
 
159
	add	edx,37 shl 16
-
 
160
	movzx	ecx,byte [ebp+2]
-
 
161
	mcall	,0x00020000
-
 
162
	add	edx,24 shl 16
-
 
163
	movzx	ecx,byte [ebp+1]
-
 
164
	mcall
-
 
165
	add	edx,23 shl 16
-
 
166
	movzx	ecx,byte [ebp+0]
-
 
167
	mcall
-
 
168
	pop	edx
-
 
169
	ret
-
 
170
;------------------------------------------------------------------------------
100
thread_files_information_start:
171
thread_files_information_start:
101
.red:
172
.red:
102
    call  draw_files_information_window
173
	call	draw_files_information_window
-
 
174
;--------------------------------------
103
.still:
175
.still:
104
    mcall 10
176
	mcall	10
105
    cmp   eax,1
177
	cmp	eax,1
106
    je	  .red
178
	je	.red
-
 
179
 
107
    cmp   eax,2
180
	cmp	eax,2
108
    je	  .key
181
	je	.key
-
 
182
 
109
    cmp   eax,3
183
	cmp	eax,3
110
    je	  .button
184
	je	.button
-
 
185
 
111
    jmp   .still
186
	jmp	.still
-
 
187
;--------------------------------------
112
.key:
188
.key:
-
 
189
	mcall	2
-
 
190
;--------------------------------------
113
.button:
191
.button:
114
    mcall -1
192
	mcall	-1
115
    jmp   .still
193
	jmp	.still
116
;---------------------------------------------------------------------
194
;------------------------------------------------------------------------------
117
;       ÏÅÐÅÂÎÄ 10-ÍÛÕ ×ÈÑÅË ÑÎ ÇÍÀÊÎÌ Â ÑÒÐÎÊÎÂÛÉ ÂÈÄ
-
 
118
;       Âõîä:
-
 
119
;               EAX - óêàçàòåëü íà ÷èñëî
-
 
120
;               EBX - àäðåñ ñòðîêè
-
 
121
;---------------------------------------------------------------------
-
 
122
decimal_string_20:
-
 
123
	push  eax ebx ecx edx
-
 
124
	mov   [divisor],word 10
-
 
125
	mov   ebp,eax
-
 
126
	xor	  ecx,ecx
-
 
127
;	mov	  [ebx],byte '0'
-
 
128
;	inc	  ebx
-
 
129
.p3:
-
 
130
	xor	  edx,edx
-
 
131
	push  ebx
-
 
132
	call  Division_64bit
-
 
133
	mov   eax,[quotent]
-
 
134
	mov   [ebp],eax
-
 
135
	mov   eax,[quotent+4]
-
 
136
	mov   [ebp+4],eax	
-
 
137
	pop   ebx
-
 
138
	add	  edx,48
-
 
139
	push  edx
-
 
140
	inc	  ecx
-
 
141
	cmp   [ebp],dword 0
-
 
142
	jne	  .p3
-
 
143
	cmp   [ebp+4],dword 0
-
 
144
	jne	  .p3
-
 
145
	cmp   ecx,19
-
 
146
	jbe   .p4
-
 
147
	mov   ecx,20
-
 
148
	dec   ebx
-
 
149
.p4:
-
 
150
	pop	  edx
-
 
151
	mov	  [ebx],dl
-
 
152
	inc	  ebx
-
 
153
	loop  .p4
-
 
154
	mov   [ebx], byte 0
-
 
155
	pop	  edx ecx ebx eax
-
 
156
	ret
-
 
157
;----------------------------------------------------------
-
 
158
; äåëåíèå 64-áèòíîãî ÷èñëà divident íà 16-áèòíîå ÷èñëî divisor.
195
; äåëåíèå 64-áèòíîãî ÷èñëà divident íà 16-áèòíîå ÷èñëî divisor.
159
; ×àñòíîå ïîìåùàåòñÿ â 64-áèòíóþ ïåðåìåííóþ quotent,
196
; ×àñòíîå ïîìåùàåòñÿ â 64-áèòíóþ ïåðåìåííóþ quotent,
160
; à îñòàòîê - â 16-áèòíóþ ïåðåìåííóþ modulo
197
; à îñòàòîê - â 16-áèòíóþ ïåðåìåííóþ modulo
161
Division_64bit:
198
Division_64bit:
162
        mov  ax,[ebp+6]
199
    	mov	ax,[ebp+6]
Line 173... Line 210...
173
        mov  ax,[ebp]
210
    	mov	ax,[ebp]
174
        div  bx
211
	div	bx
175
        mov  [quotent],ax
212
    	mov	[quotent],ax
176
;        mov  [modulo],dx
213
;    	mov	[modulo],dx
177
        ret
214
        ret
178
        
-
 
-
 
215
;--------------------------------------       
179
;divident:
216
;divident:
180
;      rb 8
217
;      rb 8
181
divisor:
218
divisor:
182
      rb 2
219
      rb 2
183
quotent:
220
quotent:
184
      rb 8
221
      rb 8
185
;modulo:
222
;modulo:
186
;      rb 2
223
;      rb 2
187
;---------------------------------------------------------------------
224
;------------------------------------------------------------------------------
188
copy_type_name:
225
copy_type_name:
189
    push  esi
226
	push	esi
190
    mov  esi,ebx
227
	mov	esi,ebx
191
    mov  edi,type_name
228
	mov	edi,type_name
192
@@:
-
 
193
    cld
229
	cld
-
 
230
;--------------------------------------
-
 
231
@@:
194
    lodsb
232
	lodsb
195
    stosb
233
	stosb
196
    test  al,al
234
	test	al,al
197
    jnz   @b
235
	jnz	@b
-
 
236
 
198
    pop  esi
237
	pop	esi
199
    ret
238
	ret
200
;---------------------------------------------------------------------
239
;------------------------------------------------------------------------------
201
get_files_information:
240
get_files_information:
202
    call get_information_marked_files
241
	call	get_information_marked_files
203
    cmp  [inf_marked_yes],1
242
	cmp	[inf_marked_yes],1
204
    je	 .end_2
243
	je	.end_2
-
 
244
 
205
    xor  eax,eax
245
	xor	eax,eax
206
    xor  edx,edx
246
	xor	edx,edx
207
    cmp  [select_panel_counter],0
247
	cmp	[select_panel_counter],0
208
    jne  .right_1
248
	jne	.right_1
-
 
249
 
209
    mov  ax,[left_start_draw_cursor_line]
250
	mov	ax,[left_start_draw_cursor_line]
210
    mov  ebx,10
251
	mov	ebx,10
211
    div  ebx
252
	div	ebx
212
    mov  ebx,[left_start_draw_line]
253
	mov	ebx,[left_start_draw_line]
213
    add  ebx,eax
254
	add	ebx,eax
214
    imul ebx,304
255
	imul	ebx,304
215
    add  ebx,[left_folder_data]
256
	add	ebx,[left_folder_data]
216
    call prepare_data_8
257
	call	prepare_data_8
217
    mov   esi,read_folder_name
258
	mov	esi,read_folder_name
218
    jmp  .end
259
	jmp	.end
-
 
260
;--------------------------------------
219
.right_1:
261
.right_1:
220
    mov  ax,[right_start_draw_cursor_line]
262
	mov	ax,[right_start_draw_cursor_line]
221
    mov  ebx,10
263
	mov	ebx,10
222
    div  ebx
264
	div	ebx
223
    mov  ebx,[right_start_draw_line]
265
	mov	ebx,[right_start_draw_line]
224
    add  ebx,eax
266
	add	ebx,eax
225
    imul ebx,304
267
	imul	ebx,304
226
    add  ebx,[right_folder_data]
268
	add	ebx,[right_folder_data]
227
    call prepare_data_8
269
	call	prepare_data_8
228
    mov   esi,read_folder_1_name
270
	mov	esi,read_folder_1_name
-
 
271
;--------------------------------------
229
.end:
272
.end:
230
    mov   [error_pointer],ebx
273
	mov	[error_pointer],ebx
-
 
274
;--------------------------------------
-
 
275
	push	eax ebx
-
 
276
	sub	ebx,40
-
 
277
; âðåìÿ ñîçäàíèÿ ôàéëà
-
 
278
	mov	eax,[ebx+8]
-
 
279
	mov	[time.create],eax
-
 
280
; äàòà ñîçäàíèÿ ôàéëà
-
 
281
	mov	eax,[ebx+12]
-
 
282
	mov	[date.create],eax  
-
 
283
; âðåìÿ ïîñëåäíåãî äîñòóïà (÷òåíèå èëè çàïèñü)
-
 
284
	mov	eax,[ebx+16]
-
 
285
	mov	[time.access],eax
-
 
286
; äàòà ïîñëåäíåãî äîñòóïà
-
 
287
	mov	eax,[ebx+20]
-
 
288
	mov	[date.access],eax    
-
 
289
; âðåìÿ ïîñëåäíåé ìîäèôèêàöèè
-
 
290
	mov	eax,[ebx+24]
-
 
291
	mov	[time.change],eax
-
 
292
; äàòà ïîñëåäíåé ìîäèôèêàöèè
-
 
293
	mov	eax,[ebx+28]
-
 
294
	mov	[date.change],eax
-
 
295
	pop	ebx eax
-
 
296
;--------------------------------------
231
    call  copy_type_name
297
	call	copy_type_name
232
    mov   edi,file_name
298
	mov	edi,file_name
233
    call  copy_path_1
299
	call	copy_path_1
-
 
300
 
234
    test [ebx-40],byte 0x10
301
	test	[ebx-40],byte 0x10
235
    jz	 @f
302
	jz	@f
-
 
303
 
236
    push eax ebx
304
	push	eax ebx
237
    call get_inf_dir
305
	call	get_inf_dir
238
    mov  [nesting_direction],0
306
	mov	[nesting_direction],0
239
    pop  ebx eax
307
	pop	ebx eax
240
    dec  [directories_counter]
308
	dec	[directories_counter]
241
    jmp  .end_2
309
	jmp	.end_2
-
 
310
;--------------------------------------
242
@@:
311
@@:
243
    mov  [nesting_direction],1
312
	mov	[nesting_direction],1
244
    call get_file_size
313
	call	get_file_size
245
    test  eax,eax
314
	test	eax,eax
246
    jz	 .end_1
315
	jz	.end_1
-
 
316
 
247
    call start_error_window_thread
317
	call	start_error_window_thread
248
    add  esp,4
318
	add	esp,4
249
    jmp  reload_dir_all
319
	jmp	reload_dir_all
-
 
320
;--------------------------------------
250
.end_1:
321
.end_1:
251
;    inc  [files_counter]
-
 
252
    mov  eax,[file_features_temp_area+32]
322
	mov	eax,[file_features_temp_area+32]
253
    add  [files_size.low],eax
323
	add	[files_size.low],eax
254
    mov  eax,[file_features_temp_area+32+4]
324
	mov	eax,[file_features_temp_area+32+4]
255
    adc  [files_size.high],eax
325
	adc	[files_size.high],eax
-
 
326
;--------------------------------------
256
.end_2:
327
.end_2:
257
    ret
328
	ret
258
;---------------------------------------------------------------------
329
;------------------------------------------------------------------------------
259
get_information_marked_files:
330
get_information_marked_files:
260
    xor  eax,eax
331
	xor	eax,eax
261
    mov  [inf_marked_yes],al
332
	mov	[inf_marked_yes],al
262
    cmp  [select_panel_counter],al
333
	cmp	[select_panel_counter],al
263
    jne  .right_1
334
	jne	.right_1
-
 
335
 
264
    mov  ebp,[left_folder_block]
336
	mov	ebp,[left_folder_block]
-
 
337
;--------------------------------------
265
.start:
338
.start:
266
    mov  ebx,ebp
339
	mov	ebx,ebp
267
    dec  ebx
340
	dec	ebx
268
    imul ebx,304
341
	imul	ebx,304
269
    add  ebx,[left_folder_data]
342
	add	ebx,[left_folder_data]
270
    add  ebx,32+40
343
	add	ebx,32+40
271
    cmp  [ebx+299-40],byte 0
344
	cmp	[ebx+299-40],byte 0
272
    je	 @f
345
	je	@f
-
 
346
 
273
    cmp  [ebx],word '..'
347
	cmp	[ebx],word '..'
274
    jne  .continue
348
	jne	.continue
-
 
349
 
275
    cmp  [ebx+2],byte 0
350
	cmp	[ebx+2],byte 0
276
    je	 .continue_1
351
	je	.continue_1
-
 
352
;--------------------------------------
277
.continue:
353
.continue:
278
    mov  esi,read_folder_name
354
	mov	esi,read_folder_name
279
    call prepare_data_9
355
	call	prepare_data_9
-
 
356
;--------------------------------------
280
.continue_1:
357
.continue_1:
281
    mov  [inf_marked_yes],1
358
	mov	[inf_marked_yes],1
-
 
359
;--------------------------------------
282
@@:
360
@@:
283
    dec  ebp
361
	dec	ebp
284
    jnz  .start
362
	jnz	.start
-
 
363
 
285
    ret
364
	ret
-
 
365
;--------------------------------------
286
.right_1:
366
.right_1:
287
    mov  ebp,[right_folder_block]
367
	mov	ebp,[right_folder_block]
-
 
368
;--------------------------------------
288
.start_1:
369
.start_1:
289
    mov  ebx,ebp
370
	mov	ebx,ebp
290
    dec  ebx
371
	dec	ebx
291
    imul ebx,304
372
	imul	ebx,304
292
    add  ebx,[right_folder_data]
373
	add	ebx,[right_folder_data]
293
    add  ebx,32+40
374
	add	ebx,32+40
294
    cmp  [ebx+299-40],byte 0
375
	cmp	[ebx+299-40],byte 0
295
    je	 @f
376
	je	@f
-
 
377
 
296
    cmp  [ebx],word '..'
378
	cmp	[ebx],word '..'
297
    jne  .continue_2
379
	jne	.continue_2
-
 
380
 
298
    cmp  [ebx+2],byte 0
381
	cmp	[ebx+2],byte 0
299
    je	 .continue_3
382
	je	.continue_3
-
 
383
;--------------------------------------
300
.continue_2:
384
.continue_2:
301
    mov   esi,read_folder_1_name
385
	mov	esi,read_folder_1_name
302
    call prepare_data_9
386
	call	prepare_data_9
-
 
387
;--------------------------------------
303
.continue_3:
388
.continue_3:
304
    mov  [inf_marked_yes],1
389
	mov	[inf_marked_yes],1
-
 
390
;--------------------------------------
305
@@:
391
@@:
306
    dec  ebp
392
	dec	ebp
307
    jnz  .start_1
393
	jnz	.start_1
-
 
394
 
308
    ret
395
	ret
309
;---------------------------------------------------------------------
396
;------------------------------------------------------------------------------
310
prepare_data_9:
397
prepare_data_9:
311
    mov   [error_pointer],ebx
398
	mov	[error_pointer],ebx
312
    mov  edi,file_name
399
	mov	edi,file_name
313
    call copy_path_1
400
	call	copy_path_1
314
    test [ebx-40],byte 0x10
401
	test	[ebx-40],byte 0x10
315
    jz	 @f
402
	jz	@f
-
 
403
 
316
    call get_inf_dir
404
	call	get_inf_dir
317
    ret
405
	ret
-
 
406
;--------------------------------------
318
@@:
407
@@:
319
    inc  [files_counter]
408
	inc	[files_counter]
320
    call get_file_size
409
	call	get_file_size
321
    test eax,eax
410
	test	eax,eax
322
    jz	 .continue
411
	jz	.continue
-
 
412
 
323
    call start_error_window_thread
413
	call	start_error_window_thread
324
    add  esp,8+4
414
	add	esp,8+4
325
    ret
415
	ret
-
 
416
;--------------------------------------
326
.continue:
417
.continue:
327
    mov  eax,[file_features_temp_area+32]
418
	mov	eax,[file_features_temp_area+32]
328
    add  [files_size.low],eax
419
	add	[files_size.low],eax
329
    mov  eax,[file_features_temp_area+32+4]
420
	mov	eax,[file_features_temp_area+32+4]
330
    adc  [files_size.high],eax
421
	adc	[files_size.high],eax
-
 
422
;--------------------------------------
331
.continue_1:
423
.continue_1:
332
    ret
424
	ret
333
;---------------------------------------------------------------------
425
;------------------------------------------------------------------------------
334
prepare_data_8:
426
prepare_data_8:
335
    add  ebx,32+40
427
	add	ebx,32+40
336
    cmp  [ebx],word '..'
428
	cmp	[ebx],word '..'
337
    jne  .continue
429
	jne	.continue
-
 
430
 
338
    cmp  [ebx+2],byte 0
431
	cmp	[ebx+2],byte 0
339
    jne  .continue
432
	jne	.continue
-
 
433
 
340
    add  esp,4+4
434
	add	esp,4+4
341
    jmp  reload_dir
435
	jmp	reload_dir
-
 
436
;--------------------------------------
342
.continue:
437
.continue:
343
    ret
438
	ret
344
;---------------------------------------------------------------------
439
;------------------------------------------------------------------------------
345
get_inf_dir:
440
get_inf_dir:
346
    mov  [nesting_direction],0
441
	mov	[nesting_direction],0
347
    pusha
442
	pusha
348
    mov   [recursive_pointer],0
443
	mov	[recursive_pointer],0
349
    mov   eax,[appl_memory]
444
	mov	eax,[appl_memory]
350
    mov   [appl_memory_old],eax
445
	mov	[appl_memory_old],eax
-
 
446
;--------------------------------------
351
.1:
447
.1:
352
    mov  [read_delete_dir_data.size],0
448
	mov	[read_delete_dir_data.size],0
353
    mov  [read_delete_dir_data.return],delete_dir_data
449
	mov	[read_delete_dir_data.return],delete_dir_data
354
    call read_delete_dir
450
	call	read_delete_dir
355
    test eax,eax
451
	test	eax,eax
356
    jz	 @f
452
	jz	@f
-
 
453
 
357
    mov   [error_pointer],file_name
454
	mov	[error_pointer],file_name
358
    call start_error_window_thread
455
	call	start_error_window_thread
359
    popa
456
	popa
360
    add  esp,8+8
457
	add	esp,8+8
361
    ret
458
	ret
-
 
459
;--------------------------------------
362
@@:
460
@@:
363
    mov  eax,[delete_dir_data+8]
461
	mov	eax,[delete_dir_data+8]
364
    imul  eax,304
462
	imul	eax,304
365
    add   eax,32
463
	add	eax,32
366
    mov   ebx,eax
464
	mov	ebx,eax
367
    add   ebx,[appl_memory_old]
465
	add	ebx,[appl_memory_old]
368
    cmp   ebx,[appl_memory]
466
	cmp	ebx,[appl_memory]
369
    jbe   @f
467
	jbe	@f
-
 
468
 
370
    mov   ecx,[appl_memory]
469
	mov	ecx,[appl_memory]
371
    mov   ecx,ebx
470
	mov	ecx,ebx
372
    mov   [appl_memory],ecx
471
	mov	[appl_memory],ecx
373
    mcall 64,1
472
	mcall	64,1
-
 
473
;--------------------------------------
374
@@:
474
@@:
375
    mov  eax,[delete_dir_data+8]
475
	mov	eax,[delete_dir_data+8]
376
    mov  [read_delete_dir_data.size],eax
476
	mov	[read_delete_dir_data.size],eax
377
    mov   eax,[appl_memory_old]
477
	mov	eax,[appl_memory_old]
378
    mov  [read_delete_dir_data.return],eax
478
	mov	[read_delete_dir_data.return],eax
379
    call read_delete_dir
479
	call	read_delete_dir
380
    test eax,eax
480
	test	eax,eax
381
    jz	 @f
481
	jz	@f
-
 
482
 
382
    mov   [error_pointer],file_name
483
	mov	[error_pointer],file_name
383
    call start_error_window_thread
484
	call	start_error_window_thread
384
    popa
485
	popa
385
    add  esp,8+8
486
	add	esp,8+8
386
    ret
487
	ret
-
 
488
;--------------------------------------
387
@@:
489
@@:
388
    cmp  [nesting_direction],0
490
	cmp	[nesting_direction],0
389
    je	  @f
491
	je	@f
-
 
492
 
390
    call get_inf_dir_2
493
	call	get_inf_dir_2
391
    jnc  .end
494
	jnc	.end
-
 
495
 
392
    dec   ebp
496
	dec	ebp
393
    push  ebp
497
	push	ebp
394
    jmp   .1
498
	jmp	.1
-
 
499
;--------------------------------------
395
@@:
500
@@:
396
    call get_inf_dir_1
501
	call	get_inf_dir_1
397
    jnc  .end
502
	jnc	.end
398
    dec   ebp
503
	dec	ebp
399
    push  ebp
504
	push	ebp
400
    jmp   .1
505
	jmp	.1
-
 
506
;--------------------------------------
401
.end:
507
.end:
402
    call  return_delete_path
508
	call	return_delete_path
403
    dec   [recursive_pointer]
509
	dec	[recursive_pointer]
404
    cmp   [recursive_pointer],0
510
	cmp	[recursive_pointer],0
405
    jge   .1
511
	jge	.1
-
 
512
 
406
    mov   ecx,[appl_memory_old]
513
	mov	ecx,[appl_memory_old]
407
    cmp   [appl_memory],ecx
514
	cmp	[appl_memory],ecx
408
    je	  @f
515
	je	@f
-
 
516
 
409
    mov   [appl_memory],ecx
517
	mov	[appl_memory],ecx
410
    mcall 64,1
518
	mcall	64,1
-
 
519
;--------------------------------------
411
@@:
520
@@:
412
    popa
521
	popa
413
    ret
522
	ret
414
;---------------------------------------------------------------------
523
;------------------------------------------------------------------------------
415
get_inf_dir_2:
524
get_inf_dir_2:
416
    pop  eax
525
	pop	eax
417
    pop  ebp
526
	pop	ebp
418
    push eax
527
	push	eax
419
    jmp  get_inf_dir_1.start
528
	jmp	get_inf_dir_1.start
-
 
529
;--------------------------------------
420
get_inf_dir_1:
530
get_inf_dir_1:
421
    inc  [directories_counter]
531
	inc	[directories_counter]
422
    mov  ebp,[appl_memory_old]
532
	mov	ebp,[appl_memory_old]
423
    mov  ebp,[ebp+8]
533
	mov	ebp,[ebp+8]
-
 
534
;--------------------------------------
424
.start:
535
.start:
425
    mov  ebx,ebp
536
	mov	ebx,ebp
426
    dec  ebx
537
	dec	ebx
427
    imul ebx,304
538
	imul	ebx,304
428
    add  ebx,[appl_memory_old]
539
	add	ebx,[appl_memory_old]
429
    add  ebx,32+40
540
	add	ebx,32+40
430
    cmp  [ebx],byte '.'
541
	cmp	[ebx],byte '.'
431
    jne  @f
542
	jne	@f
-
 
543
 
432
    cmp  [ebx+1],byte 0
544
	cmp	[ebx+1],byte 0
433
    je	 .continue_4
545
	je	.continue_4
-
 
546
;--------------------------------------
434
@@:
547
@@:
435
    cmp  [ebx],word '..'
548
	cmp	[ebx],word '..'
436
    jne  .continue
549
	jne	.continue
-
 
550
 
437
    cmp  [ebx+2],byte 0
551
	cmp	[ebx+2],byte 0
438
    je	 .continue_4
552
	je	.continue_4
-
 
553
;--------------------------------------
439
.continue:
554
.continue:
440
    mov  esi,file_name
555
	mov	esi,file_name
441
    inc  [recursive_pointer]
556
	inc	[recursive_pointer]
442
    call copy_path_2
557
	call	copy_path_2
443
    test [ebx-40],byte 0x10
558
	test	[ebx-40],byte 0x10
444
    jnz  .continue_3
559
	jnz	.continue_3
-
 
560
;--------------------------------------
445
@@:
561
@@:
446
    inc  [files_counter]
562
	inc	[files_counter]
-
 
563
;--------------------------------------
447
.continue_1:
564
.continue_1:
448
    mov  eax,[ebx+32-40]
565
	mov	eax,[ebx+32-40]
449
    add  [files_size.low],eax
566
	add	[files_size.low],eax
450
    mov  eax,[ebx+32+4-40]
567
	mov	eax,[ebx+32+4-40]
451
    adc  [files_size.high],eax
568
	adc	[files_size.high],eax
452
    dec  [recursive_pointer]
569
	dec	[recursive_pointer]
453
    call return_delete_path
570
	call	return_delete_path
454
    dec  ebp
571
	dec	ebp
455
    jnz  .start
572
	jnz	.start
456
 
-
 
-
 
573
;--------------------------------------
457
.continue_4:
574
.continue_4:
458
    clc
575
	clc
459
    mov  [nesting_direction],1
576
	mov	[nesting_direction],1
460
    ret
577
	ret
-
 
578
;--------------------------------------
461
.continue_3:
579
.continue_3:
462
    stc
580
	stc
463
    mov  [nesting_direction],0
581
	mov	[nesting_direction],0
464
    ret
582
	ret
465
;---------------------------------------------------------------------
583
;------------------------------------------------------------------------------
466
;type_patch_test:
584
;type_patch_test:
467
;    pusha
585
;	pusha
468
;    mcall 5,200
586
;	mcall	5,200
469
;    mcall 13,<290,300>,<3,13>,0x0
587
;	mcall	13,<290,300>,<3,13>,0x0
470
;    mcall 4,<300, 5>,0x80FFFFFF,file_name  ;[error_pointer]
588
;	mcall	4,<300,5>,0x80FFFFFF,file_name  ;[error_pointer]
Line 476... Line 594...
476
;temp_value_1 db '1',0
594
;temp_value_1	db '1',0
477
;temp_value_2 db '2',0
595
;temp_value_2	db '2',0
478
;temp_value_3 db '3',0
596
;temp_value_3	db '3',0
479
;temp_value_4 db '4',0
597
;temp_value_4	db '4',0
480
;temp_value_5 db '5',0
598
;temp_value_5	db '5',0
481
;---------------------------------------------------------------------
-
 
482
599
;------------------------------------------------------------------------------
-
 
600
483
601