Subversion Repositories Kolibri OS

Rev

Rev 633 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
31 halyavin 1
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2
;                                                   ;
93 diamond 3
;    MENUBAR for KolibriOS  - Compile with fasm     ;
31 halyavin 4
;                                                   ;
5
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
6
 
7
use32
8
  org  0x0
9
  db   'MENUET01'   ; 8 byte id
601 Rus 10
  dd   0x01	    ; header version
11
  dd   START	    ; program start
12
  dd   I_END	    ; program image size
13
  dd   0xA000	    ; reguired amount of memory - 10 Kb
14
  dd   0xA000	    ; esp
15
  dd   0x0,0x0	    ; param, icon
31 halyavin 16
 
17
include 'lang.inc'
485 heavyiron 18
include '..\..\..\macros.inc'
31 halyavin 19
 
601 Rus 20
width		dd  305
21
buttons 	dd    1  ;  0 no frames  ; 1 frames
22
soften_up	dd    1  ;  0 no         ; 1 yes
23
soften_down	dd    0  ;  0 no         ; 1 yes
24
minimize_left	dd    1
25
minimize_right	dd    1
633 diamond 26
icons_position	dd    95
601 Rus 27
menu_enable	dd    1
28
setup_enable	dd    0
29
graph_text	dd    1
30
soften_middle	dd    1  ;  0 no         ; 1 yes
31
icons		dd    1  ;  0 defaults   ; 1 activate
31 halyavin 32
 
42 mikedld 33
PANEL_HEIGHT = 18
31 halyavin 34
 
93 diamond 35
handle_key:
31 halyavin 36
 
37
    mcall 18, 7
38
    mov  [active_process],eax
39
 
601 Rus 40
	mcall 2
41
	cmp	al, 2
42
	jnz	begin_1.ret
43
	mov	ebx, exec_fileinfo
44
	shr	eax, 8
45
	cmp	al, 15
46
	jz	alt_tab_pressed
47
	cmp	al, 88
48
	jz	start_end_application
49
	cmp	al, 91
50
	jz	start_menu_application
51
	cmp	al, 92
52
	jz	start_menu_application
53
	cmp	al, 62
54
	jz	kill_active_application
55
	cmp	al, 71
56
	jz	page_list_next
57
	cmp	al, 72
58
	jz	page_list_prev
59
	cmp	[current_alt_tab_app], -1
60
	jz	@f
61
	test	ah, 0x30
62
	jz	alt_tab_released
443 diamond 63
@@:
304 diamond 64
; this is hotkey Ctrl+Shift ;or LShift+RShift
601 Rus 65
	mov	ebx, setup_exec
304 diamond 66
;        test    ah, 001100b
67
;        jz      change_sys_lang
68
change_key_lang:
601 Rus 69
	mov	dword [ebx+8], chlang
70
	mcall	70
71
	call	chlang_music
93 diamond 72
;       mcall   5, 25
31 halyavin 73
begin_1:
74
    mov  ecx,[active_process]
75
    mcall 18, 3
76
    mcall 5, 25
93 diamond 77
.ret:
601 Rus 78
	ret
93 diamond 79
 
304 diamond 80
;change_sys_lang:
81
;        mov     dword [ebx+8], syslang
82
;        mcall   70
83
;        call    syslang_music
84
;;       mcall   5, 25
85
;        jmp     begin_1
93 diamond 86
 
31 halyavin 87
  start_end_application:
601 Rus 88
	mov	dword [ebx+21], end_name
89
	mcall	70
31 halyavin 90
     mcall 5 ,50
93 diamond 91
     jmp   begin_1.ret
31 halyavin 92
 
93
   kill_active_application:
665 diamond 94
;     mcall  18, 7
95
;     mov    ecx,eax
96
;
97
;     ;//{SPraid.simba do not kill panel and icon
98
;     push eax
99
;     mov eax,9
100
;     mov ebx, process_info_buffer
101
;     int 0x40
102
;     mov eax,process_info_buffer
103
;     add eax,10
104
;     mov ebx,[eax]
105
;     cmp ebx,'ICON'
106
;     je  no_kill
107
;     cmp ebx,'@PAN'
108
;     jne  kill_app
109
;     add eax,4
110
;     mov ebx,[eax]
111
;     and ebx,0x0000FFFF
112
;     cmp ebx,'EL'
113
;     je  no_kill
114
;   kill_app:
115
;     pop ecx
116
;     mcall  18, 2
117
;     jmp if_kill
118
;   no_kill:
119
;     pop eax
120
;   if_kill:
121
;     ;// }SPraid.simba
122
        mcall 72,1,3,1
633 diamond 123
 
93 diamond 124
     jmp    begin_1.ret
125
 
31 halyavin 126
   start_menu_application:
601 Rus 127
	mov	[draw_window_1], 1
128
	mov	dword [ebx+21], menu_name
129
	mcall	70
130
	call	menu_music
31 halyavin 131
     mcall 5,50
93 diamond 132
     jmp   begin_1.ret
133
 
134
page_list_next:
51 mikedld 135
    cmp  [page_list],15
601 Rus 136
    je	   @f
51 mikedld 137
    inc  [page_list]
138
    mov  [draw_window_1],1
139
  @@:
93 diamond 140
    jmp  begin_1.ret
51 mikedld 141
 
93 diamond 142
page_list_prev:
51 mikedld 143
    cmp  [page_list],0
601 Rus 144
    je	   @f
51 mikedld 145
    dec  [page_list]
146
    mov  [draw_window_1],1
147
  @@:
93 diamond 148
    jmp  begin_1.ret
51 mikedld 149
 
443 diamond 150
alt_tab_pressed:
151
; handle Alt+Tab and Alt+Shift+Tab
601 Rus 152
	mov	ebp, eax
153
	cmp	[current_alt_tab_app], -1
154
	jnz	has_alt_tab_app
443 diamond 155
; заполняем таблицу приложений, подлежащих переключению
601 Rus 156
	xor	edx, edx
157
	mov	ebx, 0x8000
158
	mov	ecx, 1
159
	mov	eax, 9
443 diamond 160
.fill:
601 Rus 161
	inc	ecx
162
	int	0x40
163
	call	need_window_tab
164
	jz	@f
165
	cmp	edx, 256
166
	jz	@f
167
	mov	[alt_tab_list+edx*8], ecx
168
	movzx	esi, word [ebx+4]
169
	mov	[alt_tab_list+edx*8+4], esi
170
	inc	edx
443 diamond 171
@@:
601 Rus 172
	cmp	ecx, eax
173
	mov	eax, 9
174
	jb	.fill
175
	mov	[alt_tab_list_size], edx
176
	test	edx, edx
177
	jz	begin_1.ret
178
	mcall	66,4,0,0	; ловим момент отпускания всех управляющих клавиш
179
	test	eax, eax
180
	jnz	begin_1.ret
181
	xor	edx, edx
182
	mov	eax, [alt_tab_list+4]
183
	xor	ecx, ecx
184
	inc	ecx
443 diamond 185
.findmax:
601 Rus 186
	cmp	[alt_tab_list+ecx*8+4], eax
187
	jb	@f
188
	mov	edx, ecx
189
	mov	eax, [alt_tab_list+ecx*8+4]
443 diamond 190
@@:
601 Rus 191
	inc	ecx
192
	cmp	ecx, [alt_tab_list_size]
193
	jb	.findmax
194
	mov	[current_alt_tab_app], edx
443 diamond 195
has_alt_tab_app:
601 Rus 196
	mov	eax, [current_alt_tab_app]
197
	mov	edx, [alt_tab_list+eax*8+4]	; slot
198
	xor	ecx, ecx
199
	or	eax, -1
200
	test	ebp, 300h
201
	jz	.notshift
202
	or	esi, -1
443 diamond 203
.loop1:
601 Rus 204
	cmp	[alt_tab_list+ecx*8+4], edx
205
	jbe	@f
206
	cmp	[alt_tab_list+ecx*8+4], esi
207
	jae	@f
208
	mov	eax, ecx
209
	mov	esi, [alt_tab_list+ecx*8+4]
443 diamond 210
@@:
601 Rus 211
	inc	ecx
212
	cmp	ecx, [alt_tab_list_size]
213
	jb	.loop1
214
	cmp	eax, -1
215
	jnz	.found
216
	xor	edx, edx
217
	xor	ecx, ecx
218
	jmp	.loop1
443 diamond 219
.notshift:
601 Rus 220
	xor	esi, esi
443 diamond 221
.loop2:
601 Rus 222
	cmp	[alt_tab_list+ecx*8+4], edx
223
	jae	@f
224
	cmp	[alt_tab_list+ecx*8+4], esi
225
	jbe	@f
226
	mov	eax, ecx
227
	mov	esi, [alt_tab_list+ecx*8+4]
443 diamond 228
@@:
601 Rus 229
	inc	ecx
230
	cmp	ecx, [alt_tab_list_size]
231
	jb	.loop2
232
	cmp	eax, -1
233
	jnz	.found
234
	or	edx, -1
235
	xor	ecx, ecx
236
	jmp	.loop2
443 diamond 237
.found:
601 Rus 238
	mov	[current_alt_tab_app], eax
239
	push	eax
240
	xor	edx, edx
241
	div	[max_applications]
242
	mov	[page_list], eax
243
	mov	[draw_window_1], 1
244
	mov	edi, app_list
245
	push	edi
246
	mov	ecx, 20
247
	or	eax, -1
248
	rep	stosd
249
	pop	edi
250
	pop	ecx
251
	sub	ecx, edx
443 diamond 252
@@:
601 Rus 253
	cmp	ecx, [alt_tab_list_size]
254
	jae	redraw_window_tabs
255
	mov	eax, [alt_tab_list+ecx*8]
256
	stosd
257
	inc	ecx
258
	jmp	@b
443 diamond 259
 
260
alt_tab_released:
601 Rus 261
	mcall	66,5,0,0	; уже поймали, хватит :)
262
	or	eax, -1
263
	xchg	eax, [current_alt_tab_app]
264
	mov	ecx, [alt_tab_list+eax*8]
265
	mov	eax, 18
266
	mov	ebx, 3
267
	int	0x40
268
	jmp	redraw_window_tabs
443 diamond 269
 
601 Rus 270
active_process	dd 0
31 halyavin 271
 
272
calendar_music:
273
    mcall 55, eax, , , calendarmusic
274
    ret
275
setup_music:
276
    mcall 55,eax, , ,setupmusic
277
    ret
278
sysmeter_music:
279
    mcall 55,eax, , ,sysmetermusic
280
    ret
281
button_music:
282
    mcall 55,eax, , ,buttonmusic
283
    ret
304 diamond 284
;syslang_music:
285
;    mcall 55, eax, , , syslangmusic
286
;    ret
31 halyavin 287
chlang_music:
288
    mcall 55, eax, , , chlangmusic
289
    ret
290
menu_music:
291
    mcall 55,eax, , ,menumusic
292
    ret
293
 
601 Rus 294
chlangmusic:	db 0x82,0x60,0x83,0x65,0x82,0x60,0
31 halyavin 295
 
304 diamond 296
;syslangmusic:   db 0x82,0x65,0x83,0x70,0x82,0x65,0
31 halyavin 297
 
601 Rus 298
menumusic:	db 0x82,0x50,0x84,0x48,0x82,0x50,0x84,0x53,0x82,0x51,0
31 halyavin 299
 
601 Rus 300
activatemusic:	db 0x83,0x30,0x85,0x60,0
31 halyavin 301
 
601 Rus 302
buttonmusic:	db 0x85,0x25,0x85,0x40,0
31 halyavin 303
 
601 Rus 304
sysmetermusic:	db 0x85,0x35,0x85,0x45,0
31 halyavin 305
 
601 Rus 306
setupmusic:	db 0x85,0x40,0x85,0x50,0
31 halyavin 307
 
601 Rus 308
calendarmusic:	db 0x85,0x37,0x85,0x48,0
31 halyavin 309
 
310
;  .exit: mcall -1
311
 
312
 
313
START:
601 Rus 314
	mov	eax, 51
315
	mov	ebx, 1
316
	mov	ecx, detect_start
317
	mov	edx, detect_stack
318
	int	0x40
319
	mcall 66,4,0,2		; LShift+RShift
320
	mcall 66, , ,11h	; Ctrl+Shift
321
	mcall 66,,88,110h	; Alt+Ctrl+F12
322
	mcall 66,,91,100h	; Alt+LWin
323
	mcall 66,,92		; Alt+RWin
324
	mcall 66,,62		; Alt+F4
325
	mcall 66,,71		; Alt+Home
326
	mcall 66,,72		; Alt+Up
327
	mcall 66,,15		; Alt+Tab
328
	mcall 66,,,101h 	; Alt+Shift+Tab
93 diamond 329
    mcall 18, 8, 1
330
    test eax, eax
331
    jne  @f
332
    mcall 18, 8, 2
333
  @@:
601 Rus 334
	mov	eax, 70
335
	mov	ebx, dat_fileinfo
336
	int	0x40
31 halyavin 337
 
338
    mov  edi,width
339
    mov  esi,I_END
93 diamond 340
    xor  eax,eax
31 halyavin 341
  new_number:
342
    cmp  [esi],byte ';'
601 Rus 343
    je	 number_ready
31 halyavin 344
    imul eax,10
345
    movzx ebx,byte [esi]
346
    sub  ebx,'0'
347
    add  eax,ebx
348
    inc  esi
349
    jmp  new_number
350
  number_ready:
93 diamond 351
    stosd
352
    xor  eax,eax
31 halyavin 353
    inc  esi
354
    cmp  [esi],byte 'x'
355
    jne  new_number
356
 
601 Rus 357
	mcall	14
358
	mov	[screen_size],eax
31 halyavin 359
 
601 Rus 360
	mcall	48,5
361
	mov	ecx,eax
362
	lea	edx,[ebx-PANEL_HEIGHT-1]
363
	mcall	48,6
51 mikedld 364
 
633 diamond 365
; // Alver 26.08.2007 // {
366
   mov  eax, 9                      ; info of process
367
   mov  ebx, process_info_buffer
368
   mov  ecx, -1
369
   mcall
370
   mov  ecx, dword [process_info_buffer+30]
371
   mcall 18,21
372
   mov  [this_slot], eax
373
   mov  [max_slot], 255
374
; } \\ Alver \\
375
 
31 halyavin 376
    call set_variables
377
 
378
start_after_minimize:
379
 
380
    call draw_window
381
    call draw_info
382
    call draw_running_applications
383
 
384
    mov  eax, 23
385
    mov  ebx, 30
386
    int  0x40
387
 
388
still:
389
;     mcall  13,<390,70>,<3,11>,0xffffff
390
;     mov    ecx,[button_presssed_alt]
391
;     mcall  47,0x80100,ecx ,400 shl 16+5,0
392
 
393
    call draw_info
394
    call draw_running_applications
395
 
396
    mov  eax, 23
397
    mov  ebx, 20
398
    int  0x40
399
 
601 Rus 400
    cmp  eax,1		; redraw ?
401
    jz	 red
402
    cmp  eax,3		; button ?
403
    jz	 button
404
	call	handle_key
405
	jmp	still
31 halyavin 406
 
601 Rus 407
  red:			 ; redraw window
51 mikedld 408
 
601 Rus 409
	mcall	14
410
	movzx	ecx,ax
411
	mov	edx,eax
412
	shr	edx,16
413
	cmp	[screen_size.height],ax
414
	jne	@f
415
	rol	eax,16
416
	cmp	[screen_size.width],ax
417
	je	.lp1
418
	rol	eax,16
419
    @@: mov	[screen_size],eax
420
	sub	ecx,PANEL_HEIGHT
421
	mcall	67,0,,,PANEL_HEIGHT
51 mikedld 422
 
423
  .lp1:
31 halyavin 424
    call draw_window
425
    call draw_info
426
    jmp  still
427
 
601 Rus 428
  button:		 ; button
31 halyavin 429
    mov  eax,17
430
    int  0x40
431
 
432
    cmp  ah,50
601 Rus 433
    jb	 no_activate
31 halyavin 434
    cmp  ah,70
601 Rus 435
    jg	 no_activate
31 halyavin 436
 
437
    movzx ecx,byte ah
438
    sub  ecx,52
439
    shl  ecx,2
440
 
441
    mov  eax,18
442
    mov  ebx,3
443
    mov  ecx,[app_list+ecx]
444
    int  0x40
445
;    cmp  [music_type],0
446
;    je   still
447
    mcall 55,eax, , ,activatemusic
448
    jmp  still
449
  no_activate:
450
 
451
 
601 Rus 452
    cmp  ah,101 	  ; minimize to left
453
    je	 left_button
31 halyavin 454
 
601 Rus 455
    cmp  ah,102 	  ; minimize to right
456
    je	 right_button
31 halyavin 457
 
633 diamond 458
; // Alver 26.08.2007 // {
459
    cmp  ah, 103
460
    je	 clean_desktop              ; minimize all windows
461
    cmp  ah, 104
462
    je   restore_desktop            ; restore minimized windows
463
    cmp  ah, 105
464
    je   swap_minimized_desktop     ; minimize normal windows, and restore minimized windows
465
; } \\ Alver \\
466
 
601 Rus 467
    cmp  ah,byte 1	  ; start/terminate menu
31 halyavin 468
    jnz  noselect
469
    call menu_handler
470
;    cmp  [music_type],0
471
;    je   still
472
    call menu_music
473
    jmp  still
474
  noselect:
475
 
601 Rus 476
	mov	ebx, exec_fileinfo
477
    cmp  ah,byte 2	       ; start calendar
31 halyavin 478
    jnz  noid15  ;noclock
601 Rus 479
	mov	dword [ebx+21], calendar_name
480
	mov	eax, 70
481
	int	0x40
31 halyavin 482
    call calendar_music
483
    jmp  still
484
 
485
  noid15:
486
    cmp  ah,16
487
    jne  noid16
601 Rus 488
	mov	ebx, setup_exec
489
	mov	dword [ebx+8], chlang
490
	mov	eax, 70
491
	int	0x40
31 halyavin 492
    call chlang_music
493
    mcall 5, 25
494
    jmp  still
495
 
496
  noid16:
304 diamond 497
;    cmp  ah,17
498
;    jne  noid17
499
;        mov     ebx, setup_exec
500
;        mov     dword [ebx+8], syslang
501
;        mov     eax, 70
502
;        int     0x40
503
;    call syslang_music
504
;    mcall 5, 25
505
;    jmp  still
506
;
507
;  noid17:
31 halyavin 508
    cmp  ah,18
509
    jne  noid18
601 Rus 510
	mov	dword [ebx+21], sysmeter_name
511
	mov	eax, 70
512
	int	0x40
31 halyavin 513
    call sysmeter_music
514
    jmp  still
515
 
516
  noid18:
517
    cmp  ah,19
518
    jne  noid19
519
;    inc  [music_type]
520
;    and  [music_type],1
521
    mcall 18,8,2
522
;    mcall 18,8
523
;    mov [sound_flag],al
524
 
525
;    mcall 15,4,2
526
    mcall 15,3
527
    jmp  red
528
 
529
  noid19:
601 Rus 530
    cmp  ah,20		   ; start system setup
31 halyavin 531
    jnz  noid20
601 Rus 532
	mov	ebx, setup_exec
533
	and	dword [ebx+8], 0
534
	mov	eax, 70
535
	int	0x40
31 halyavin 536
    call setup_music
93 diamond 537
    jmp still
31 halyavin 538
 
539
 noid20:
51 mikedld 540
    cmp  ah,21
541
    jnz  noid21
633 diamond 542
; // Alver 25.08.2007 // {
543
    cmp  [page_list], 99
544
    jnc  @f
545
  ;  cmp  [page_list],15
546
  ;  je	   @f
547
; } \\ Alver \\
51 mikedld 548
    inc  [page_list]
549
    jmp  red
550
  @@:
551
    jmp still
31 halyavin 552
 
51 mikedld 553
 noid21:
554
    cmp  ah,22
555
    jnz  noid22
556
    cmp  [page_list],0
601 Rus 557
    je	   @f
51 mikedld 558
    dec  [page_list]
559
    jmp  red
560
  @@:
31 halyavin 561
    jmp  still
562
 
51 mikedld 563
 noid22:
31 halyavin 564
 
51 mikedld 565
    jmp  still
31 halyavin 566
 
633 diamond 567
; // Alver 26.08.2007 //{
568
restore_desktop:
569
    mcall   9,process_info_buffer,-1
570
    mov     [max_slot], eax
571
    mov     ecx, 2
572
    mov     edx, 2
573
@@:
574
    mcall   18, 22
575
    inc     edx
576
    cmp     edx, [max_slot]
577
    jbe     @b
578
    jmp  still
51 mikedld 579
 
633 diamond 580
swap_minimized_desktop:
581
    xor  esi, esi
582
    inc esi
583
    jmp  min_swap_desktop
584
clean_desktop:
585
    xor esi,esi
586
 min_swap_desktop:                 ; input esi 0 - min, <>0 swap
587
     mov    ecx, 2                 ; Начальный номер слота процесса
588
     mov    ebx, process_info_buffer
51 mikedld 589
 
633 diamond 590
.loop1:
591
     cmp    ecx, [this_slot]
592
     je     .loop1xx
593
     mcall  9
594
     mov    [max_slot], eax
595
     mov    dx, word [process_info_buffer+50]
596
     cmp    dx, 9                   ; Проверка свободен ли данный слот
597
     jz     .loop1xx
598
     mov    edx, dword [ebx+10]
599
     cmp    dl, '@'
600
     je     .loop1xx
601
     cmp    dword [ebx+10], 'ICON'
602
     jnz    @f
603
     cmp    [ebx+42], dword 51
604
     jnz    @f
605
     cmp    [ebx+46], dword 51
606
     jz     .loop1xx
607
@@:
608
     cmp    [ebx+10], dword '    '
609
     jz     .loop1xx
610
 
611
     pushad
612
     mov    edx, ecx
613
     xor    ecx, ecx
614
     or     esi, esi
615
     jz     @f
616
     movzx  eax, byte [process_info_buffer+70]
617
     and    eax, 2            ; mask minimize
618
     jz     @f
619
     mov    ecx, 2            ; restore
620
@@:
621
     mcall  18, 22
622
     popad
623
.loop1xx:
624
     inc    ecx
625
     cmp    ecx, [max_slot]
626
     jbe    .loop1
627
     jmp    still
628
; } \\ Alver \\
629
 
31 halyavin 630
draw_running_applications:
631
 
632
    pusha
633
 
634
    cmp  [icons],1
635
    jne  dr_ret
636
 
637
    call calculate_applications
638
 
639
    cmp  edi,[running_applications]
640
    jne  noret
641
    popa
642
    ret
643
  noret:
644
 
645
;    cmp  edi,[running_applications]
646
;    jge  no_application_decrease
647
    call draw_window
648
;  no_application_decrease:
649
 
650
    mov  [running_applications],edi
651
 
601 Rus 652
	call	redraw_window_tabs
31 halyavin 653
 
443 diamond 654
  dr_ret:
51 mikedld 655
 
443 diamond 656
    popa
31 halyavin 657
 
443 diamond 658
    ret
31 halyavin 659
 
443 diamond 660
need_window_tab:
661
; in: ebx->process info
662
; out: ZF set <=> do not draw
601 Rus 663
	cmp	byte [ebx+10], '@'
664
	jz	.nodraw
443 diamond 665
; \begin{diamond}[29.03.2007]
666
; do not draw undefined (zero-sized) windows
601 Rus 667
	cmp	dword [ebx+42], 0
668
	jnz	@f
669
	cmp	dword [ebx+46], 0
670
	jz	.nodraw
443 diamond 671
@@:
672
; \end{diamond}[29.03.2007]
601 Rus 673
	cmp	dword [ebx+10], 'ICON'
674
	jnz	@f
675
	cmp	[ebx+42], dword 51
676
	jnz	@f
677
	cmp	[ebx+46], dword 51
678
	jz	.nodraw
443 diamond 679
@@:
601 Rus 680
	cmp	[ebx+10], dword '    '
443 diamond 681
.nodraw:
601 Rus 682
	ret
31 halyavin 683
 
443 diamond 684
redraw_window_tabs:
601 Rus 685
	xor	edi, edi
686
	mov	[contrast], 0
443 diamond 687
.loop:
601 Rus 688
	mov	ecx, [app_list+edi*4]
689
	cmp	ecx, -1
690
	jz	.done
31 halyavin 691
 
601 Rus 692
	push	ecx
693
	mov	eax, 9
694
	mov	ebx, 0x8000
695
	int	0x40
31 halyavin 696
 
601 Rus 697
	mov	eax, 13
698
	imul	ebx, edi, 6*10*10000h
633 diamond 699
; // Alver 26.08.2007 // {
700
;	add	ebx, 6*10*10000h + 7*10000h + 54
701
	add	ebx, 12*10*10000h + 7*10000h + 54
702
; } // Alver //
601 Rus 703
	mov	ecx, 3*10000h + 14
704
	xor	edx, edx
705
	int	0x40
706
	sub	ebx, 10000h + 53
707
	mov	ecx, 4*10000h + 12
708
	int	0x40
709
	sub	ebx, 10000h
710
	mov	ecx, 5*10000h + 10
711
	int	0x40
712
	add	ebx, 56*10000h
713
	mov	ecx, 4*10000h + 12
714
	int	0x40
715
	add	ebx, 10000h
716
	mov	ecx, 5*10000h + 10
717
	int	0x40
31 halyavin 718
 
601 Rus 719
	mov	edx, 0x88FF
720
	xor	[contrast], 1
721
	jz	@f
722
	mov	dh, 0x55
443 diamond 723
@@:
601 Rus 724
	pop	ecx
725
	mov	esi, [current_alt_tab_app]
726
	cmp	esi, -1
727
	jz	@f
728
	cmp	ecx, [alt_tab_list+esi*8]
729
	jnz	@f
443 diamond 730
;        xor     edx, 0xFFFFFF
601 Rus 731
	mov	edx, 0xFF8000
443 diamond 732
@@:
601 Rus 733
	sub	ebx, 55*10000h - 53
734
	mov	ecx, 4*10000h + 12
735
	int	0x40
736
	sub	ebx, 10000h + 53
737
	mov	ecx, 5*10000h + 10
738
	int	0x40
739
	add	ebx, 55*10000h
740
	int	0x40
31 halyavin 741
 
601 Rus 742
	mov	eax, 4
743
	sub	ebx, 51*10000h - 6
744
	mov	ecx, 0xffffff	;[wcolor]
745
	mov	edx, 0x8000+10
746
	mov	esi, 11
747
	int	0x40
31 halyavin 748
 
601 Rus 749
	inc	edi
750
	cmp	edi, [max_applications]
751
	jb	.loop
443 diamond 752
.done:
601 Rus 753
	ret
31 halyavin 754
 
755
calculate_applications:
756
 
51 mikedld 757
    mov  eax,[max_applications]
93 diamond 758
    mul  [page_list]
759
    test eax,eax
601 Rus 760
    je	  @f
51 mikedld 761
    inc  eax
762
  @@:
763
    mov  [draw_start_position],eax
764
 
31 halyavin 765
    mov  edi,app_list
766
    mov  ecx,20
443 diamond 767
    mov  eax,-1
31 halyavin 768
    cld
769
    rep  stosd
770
 
771
    mov  edi,0
772
    mov  ecx,2
773
 
774
  cnewpr:
775
 
776
    mov  eax,9
777
    mov  ebx,0x8000
778
    int  0x40
779
 
601 Rus 780
	call	need_window_tab
781
	jz	cnorpl
782
	sub	[draw_start_position], 1
783
	jg	cnorpl
31 halyavin 784
 
785
    mov  [app_list+edi*4],ecx
786
 
787
    inc  edi
788
 
789
  cnorpl:
790
    inc  ecx
791
 
792
    cmp  eax,ecx
793
    jge  cnewpr
794
 
795
    ret
796
 
797
 
798
draw_application_buttons:
799
 
800
    pusha
801
 
802
    cmp [icons],1
803
    jne da_ret
804
 
805
    mov  eax,14
806
    int  0x40
807
 
808
    shr  eax,16
809
 
633 diamond 810
; // Alver 25.08.2007 // {
811
 ;   cmp  eax,639
812
 ;   jne  now1
813
 ;   mov  [max_applications],7	;6
814
 ; now1:
815
 ;   cmp  eax,799
816
 ;   jne  now2
817
 ;   mov  [max_applications],9 ;10    ;8
818
 ; now2:
819
 ;   cmp  eax,1023
820
 ;   jne  now3
821
 ;   mov  [max_applications],12 ;13   ;8
822
 ; now3:
823
 ;   cmp  eax,1279
824
 ;   jne  now4
825
 ;   mov  [max_applications],17 ;18    ;8
826
 ; now4:
827
 ;   mov  edi,1
31 halyavin 828
 
633 diamond 829
     sub  eax, 281
830
     jnc  ._01
831
     xor  eax, eax
832
._01:
833
     mov  bl, 60
834
     div  bl
835
     xor  ah, ah                       ; eax - количество умещаюшихся пиктов
836
     mov  [max_applications], eax
837
     mov  edi,1
838
;  } \\ Alver \\
839
 
31 halyavin 840
  nb:
841
 
842
    mov  eax,8
843
    mov  ebx,edi
844
    shl  ebx,16
601 Rus 845
    imul ebx,6*10	     ;13
633 diamond 846
    add  ebx,75*65536+10*6-1 ; << Alver 25.08.2007 >> 15*65536+10*6-1  ;13
31 halyavin 847
    mov  ecx,1*65536+17
848
    mov  edx,edi
849
    add  edx,51
850
    cmp  [buttons],1
601 Rus 851
    je	 bufr
852
    or	 edx,0x60000000
31 halyavin 853
  bufr:
854
    mov  esi,[wcolor]
855
    sub  ebx,11 shl 16
856
    int  0x40
857
 
858
    inc  edi
859
    cmp  edi,[max_applications]
860
    jbe  nb
861
 
862
  da_ret:
863
 
864
    popa
865
 
866
    ret
867
 
868
 
869
menu_handler:
601 Rus 870
	mov	eax, 70
871
	mov	ebx, exec_fileinfo
872
	mov	dword [ebx+21], menu_name
873
	int	0x40
874
	ret
31 halyavin 875
 
876
draw_small_right:
877
 
878
    pusha
879
 
880
    mov  eax,12
881
    mov  ebx,1
882
    int  0x40
883
 
884
    mov  eax,0
885
    mov  edx,[wcolor]
886
    mov  esi,edx
887
    mov  edi,edx
601 Rus 888
    or	 edx, 0x01000000
31 halyavin 889
    int  0x40
890
 
891
    mov  eax,8
892
    mov  ebx,0*65536+9
893
    mov  ecx,0*65536
894
    mov  cx,[b_size_y]
895
    mov  edx,1
896
    mov  esi,[wcolor]
897
    int  0x40
898
 
899
    mov  eax,4
900
    mov  ebx,2*65536+16
901
    cmp  [graph_text],1
902
    jne  nos3
903
    mov  ebx,2*65536+7
904
  nos3:
905
    mov  ecx,[wcolor]
906
    add  ecx,0x303030
907
    mov  edx,hidetext
908
    mov  esi,1
909
    int  0x40
910
 
911
    mov  eax,12
912
    mov  ebx,2
913
    int  0x40
914
 
915
    popa
916
 
917
    ret
918
 
919
 
920
 
921
draw_small_left:
922
 
923
    pusha
924
 
925
    mov  eax,12
926
    mov  ebx,1
927
    int  0x40
928
 
929
    mov  eax,0
930
    mov  edx,[wcolor]
931
    mov  esi,edx
932
    mov  edi,edx
601 Rus 933
    or	 edx, 0x01000000
31 halyavin 934
    int  0x40
935
 
936
    cmp  [graph_text],1
601 Rus 937
    je	 nos4
31 halyavin 938
 
939
    mov  eax,8
940
    mov  ebx,0*65536+9
941
    mov  ecx,0*65536+18-6
942
    mov  edx,2
943
    mov  esi,[wcolor]
944
    int  0x40
945
 
946
    mov  eax,4
947
    mov  ebx,2*65536+4
948
    mov  ecx,[wcolor]
949
    add  ecx,0x303030
950
    mov  edx,hidetext+2
951
    mov  esi,1
952
    int  0x40
953
 
954
  nos4:
955
 
956
    mov  eax,8
957
    mov  ebx,0*65536+9
958
    mov  ecx,13*65536+25
959
    cmp  [graph_text],1
960
    jne  nos6
961
    mov  ecx,0*65536
962
    mov  cx,word [b_size_y]
963
  nos6:
964
    mov  edx,1
965
    mov  esi,[wcolor]
966
    int  0x40
967
 
968
    mov  eax,4
969
    mov  ebx,3*65536+22
970
    cmp  [graph_text],1
971
    jne  nos7
972
    mov  ebx,3*65536+7
973
  nos7:
974
    mov  ecx,[wcolor]
975
    add  ecx,0x303030
976
    mov  edx,hidetext+1
977
    mov  esi,1
978
    int  0x40
979
 
980
    mov  eax,12
981
    mov  ebx,2
982
    int  0x40
983
 
984
    popa
985
    ret
986
 
987
 
988
;-------------------------------------------------
989
 
990
right_button:
991
 
992
    call button_music
993
 
994
    mov  [small_draw],dword draw_small_right
995
 
996
    mcall 14
997
    shr eax, 16
998
    mov ebx, eax
999
    mov ecx, -1
1000
    mov edx, 9
1001
    sub ebx, edx
1002
    mov esi, -1
1003
    mcall 67
1004
 
1005
    call draw_small_right
1006
 
1007
    jmp  small_wait
1008
 
1009
;-------------------------------------------------
1010
 
1011
left_button:
1012
 
1013
    call  button_music
1014
 
1015
    mov  [small_draw],dword draw_small_left
1016
 
1017
    mov   ebx, 0
1018
    mov   edx, 9
1019
    mov   ecx, -1
1020
    mov   esi, -1
1021
    mcall 67
1022
 
1023
    call draw_small_left
1024
 
1025
;-------------------------------------------------
1026
 
1027
  small_wait:
1028
 
1029
    mov  eax, 10
1030
    int  0x40
1031
 
1032
    cmp  eax,1
1033
    jne  no_win
1034
    call [small_draw]
1035
    jmp  small_wait
1036
  no_win:
93 diamond 1037
    cmp  eax,2
1038
    jne  no_key
1039
    call handle_key
1040
    jmp  small_wait
1041
no_key:
31 halyavin 1042
 
1043
    mov  eax,17
1044
    int  0x40
1045
 
1046
    cmp  ah,1
1047
    jne  no_full
1048
 
601 Rus 1049
    mov   eax, 14		    ; get screen max x & max y
31 halyavin 1050
    int   0x40
1051
    mov   edx, eax
1052
    shr   edx, 16
50 halyavin 1053
    xor   ebx, ebx
31 halyavin 1054
    mov   ecx, -1
1055
    mov   esi, -1
1056
    mcall 67 ; x0 y0 xs ys
1057
 
1058
    call  button_music
1059
 
1060
    jmp   still
1061
 
1062
 
1063
  no_full:
1064
 
1065
    call menu_handler
1066
 
1067
    jmp  small_wait
1068
 
1069
 
1070
 
1071
set_variables:
1072
 
1073
     pusha
1074
 
1075
     mov  [b_size_y],dword 38
1076
     cmp  [graph_text],1
1077
     jne  noy2
1078
     mov  [b_size_y],dword 18
1079
   noy2:
1080
 
1081
     mov  [button_frames],0x0
1082
     cmp  [buttons],0
1083
     jne  no_frames
1084
     mov  [button_frames],0x40000000
1085
   no_frames:
1086
 
1087
 
601 Rus 1088
     mov  eax,48	   ; 3d button look
31 halyavin 1089
     mov  ebx,1
1090
     mov  ecx,1
1091
     int  0x40
1092
 
1093
     mov  eax,0x40404040   ; dividers for processes
1094
     mov  edi,pros
1095
     mov  ecx,10
1096
     cld
1097
     rep  stosd
1098
 
1099
     popa
1100
     ret
1101
 
1102
 
1103
 
1104
; eax = number (1 or 2)
1105
; ebx = language id
1106
draw_flag:
1107
    pusha
1108
 
1109
;    cmp  [graph_text],0
1110
;    je   mini_flag
1111
 
1112
; eax = 2 BIG
1113
; eax = 1 small
1114
 
1115
    mov  edx,ebx
1116
 
1117
    mov  ebx,[maxx]
1118
    and  eax,1
1119
    imul eax,17  ;17
1120
    sub  ebx,eax
1121
    sub  ebx,76 ;79 ;28
1122
 
1123
    pushad
1124
;    dec  ebx
1125
    sub  ebx,2
1126
    shl  ebx, 16
1127
    add  ebx, 15 ;25
1128
    mov  ecx, 4*65536+13
1129
    mov  edx,0
1130
    mov  eax,13
1131
    int  0x40
1132
    add  ebx,1 shl 16
1133
    sub  ebx,2
1134
    mov  ecx, 5 shl 16+11
1135
    cmp  [type_lang],1
601 Rus 1136
    je	label_1
31 halyavin 1137
    mov  edx,0xff ;[wcolor]
1138
    jmp  label_2
1139
label_1:
1140
    mov  edx,0x7700
1141
label_2:
1142
    mov  eax, 13
1143
    int  0x40
1144
    popad
1145
 
1146
    shl  ebx,16
601 Rus 1147
    add  ebx,7	;24
31 halyavin 1148
 
1149
    mov  ecx,[bte] ; color
1150
 
1151
    dec  edx
1152
    shl  edx,1
1153
    add  edx,flag_text
1154
    mov  esi,2
1155
    mov  eax,4
1156
    int  0x40
1157
 
1158
    mov  ebx,[maxx]
1159
    sub  ebx,48
1160
    shl  ebx,16
1161
    mov  bx,34
1162
    mov  ecx,3 shl 16+14
1163
    xor  edx,edx
1164
    mov  eax,13
1165
    int  0x40
1166
    add  ebx,1 shl 16
1167
    sub  ebx,2
1168
    mov  ecx,4 shl 16+12
1169
    mov  edx,0x66cc
1170
    int  0x40
1171
 
1172
    popa
1173
    ret
1174
 
1175
;mini_flag:
1176
;    popa
1177
;    ret
1178
 
1179
 
1180
 
1181
 
1182
; ***************************************************
1183
; ********* WINDOW DEFINITIONS AND DRAW *************
1184
; ***************************************************
1185
 
1186
 
1187
draw_window:
1188
 
1189
    pusha
1190
 
1191
    mov  [running_applications],-1
1192
    mov  [checks],-1
1193
 
601 Rus 1194
    mov  eax, 12		   ; tell os about redraw
31 halyavin 1195
    mov  ebx, 1
1196
    int  0x40
1197
 
1198
    mov  eax, 48
1199
    mov  ebx, 3
1200
    mov  ecx, system_colours
1201
    mov  edx, 10*4
1202
    int  0x40
1203
 
1204
    mov  eax, [system_colours+4*6]
318 heavyiron 1205
    sub  eax, 0x101010
31 halyavin 1206
    mov  [wcolor], eax
1207
 
601 Rus 1208
    mov  eax,14 		   ; get screen max x & max y
31 halyavin 1209
    int  0x40
1210
 
1211
    cmp  [width],0
601 Rus 1212
    je	 no_def_width
31 halyavin 1213
    and  eax,0xffff
1214
    mov  ebx,[width]
1215
    shl  ebx,16
1216
    add  eax,ebx
1217
  no_def_width:
1218
 
1219
    mov  ebx,eax
1220
    mov  [screenxy],ebx
1221
    shr  ebx,16
1222
    sub  ax,38
1223
    shl  eax,16
1224
    mov  ecx,eax
1225
    add  ecx,0*65536+38
1226
    cmp  [graph_text],1
1227
    jne  no_text_1
42 mikedld 1228
    mov  cx,PANEL_HEIGHT
31 halyavin 1229
    add  ecx,20*65536
1230
  no_text_1:
601 Rus 1231
    mov  eax, 0 		    ; DEFINE AND DRAW WINDOW
31 halyavin 1232
    mov  edx, [wcolor]
601 Rus 1233
    or	 edx, 0x01000000 ; do not draw the window
31 halyavin 1234
    mov  esi, [wcolor]
601 Rus 1235
    or	 esi, 0x01000000 ; unmovable window
31 halyavin 1236
    mov  edi, [wcolor]
601 Rus 1237
 
1238
    mov  [panel_x_pos], ebx
633 diamond 1239
    mov  [panel_y_pos], ecx	 ; Пока что так.
601 Rus 1240
 
31 halyavin 1241
    int  0x40
1242
 
1243
    movzx ebx,word [screenxy+2]
1244
    mov  ecx,0*65536+0
1245
    mov  edx,[wcolor]
1246
    add  edx,0x161616
1247
  newline:
1248
    sub  edx,0x040404
1249
    mov  eax,38
1250
    cmp  [soften_up],1
1251
    jne  no_su
51 mikedld 1252
    and  edx,0x00FFFFFF
31 halyavin 1253
    int  0x40
1254
  no_su:
1255
 
1256
    pusha
1257
    cmp  [soften_down],1
1258
    jne  no_sd
1259
    sub  edx,0x141414
1260
    mov  edi,[b_size_y]
1261
    shl  edi,16
1262
    add  edi,[b_size_y]
1263
    add  ecx,edi
1264
    sub  ecx,3*65536+3
51 mikedld 1265
    and  edx,0x00FFFFFF
31 halyavin 1266
    int  0x40
1267
  no_sd:
1268
    popa
1269
 
1270
    add  ecx,1*65536+1
1271
    cmp  cx,5
601 Rus 1272
    jb	 newline
31 halyavin 1273
 
1274
    cmp   [soften_middle],1
1275
    jne   no_sm
1276
 
1277
    movzx ebx,word [screenxy+2]
1278
    mov   ecx,5*65536+5
1279
    mov   esi,stripe
1280
    mov   edx,[wcolor]
1281
  newline3:
1282
    add  edx,[esi]
1283
    add  esi,4
1284
 
1285
    mov  eax,38
51 mikedld 1286
    and  edx,0x00FFFFFF
31 halyavin 1287
    int  0x40
1288
    add  ecx,1*65536+1
1289
    cmp  cx,15
601 Rus 1290
    jb	 newline3
31 halyavin 1291
 
1292
  no_sm:
1293
 
1294
    cmp  [minimize_left],1
1295
    jne  no_mleft
601 Rus 1296
    mov  eax,8				     ; ABS LEFT
31 halyavin 1297
    mov  ebx,0 *65536+9
1298
    mov  ecx,1 *65536
1299
    add  ecx,[b_size_y]
1300
    dec  ecx
1301
    mov  edx,101
1302
    add  edx,[button_frames]
1303
    mov  esi,[wcolor]
1304
    int  0x40
601 Rus 1305
    mov  eax,4				     ; HIDE TEXT
31 halyavin 1306
    mov  ebx,2*65536+17
1307
    cmp  [graph_text],1
1308
    jne  no_y1
1309
    mov  bx,7
1310
  no_y1:
1311
    mov  ecx,[wcolor]
1312
    add  ecx,0x303030
1313
    mov  edx,hidetext
1314
    mov  esi,1
1315
    int  0x40
1316
  no_mleft:
1317
 
1318
    movzx eax,word [screenxy+2]
1319
    mov  [maxx],eax
1320
 
1321
    cmp  [minimize_right],1
1322
    jne  no_mright
1323
    mov  eax,[maxx]
1324
    sub  eax,77
1325
    shl  eax,16
1326
    mov  ebx,eax
1327
    add  ebx,67
601 Rus 1328
    mov  eax,8				     ; ABS RIGHT
31 halyavin 1329
    mov  ecx,1 *65536
1330
    add  ecx,[b_size_y]
1331
    dec  ecx
1332
    add  ebx,68*65536
1333
    mov  bx,9
1334
    mov  edx,102
1335
    add  edx,[button_frames]
1336
    mov  esi,[wcolor]
1337
    int  0x40
1338
    mov  edx,hidetext+1
1339
    mov  eax,4
1340
    mov  ebx,[maxx]
1341
    sub  ebx,6
1342
    shl  ebx,16
1343
    mov  bx,17
1344
    cmp  [graph_text],1
1345
    jne  no_y2
1346
    mov  bx,7
1347
  no_y2:
1348
    mov  ecx,[wcolor]
1349
    add  ecx,0x303030
1350
    mov  esi,1
1351
    int  0x40
1352
  no_mright:
1353
 
1354
    call draw_menuet_icon
1355
 
1356
    call draw_program_icons
1357
 
1358
    mov  [ptime],0
1359
    call draw_info
1360
 
1361
    call draw_application_buttons
1362
 
1363
;     mov    ecx,[button_presssed_alt]
1364
;     mcall  47,0x80100,ecx ,400 shl 16+5,0
1365
 
1366
    mov  eax,12
1367
    mov  ebx,2
1368
    int  0x40
1369
 
1370
    popa
1371
    ret
1372
 
633 diamond 1373
; // Alver 26.08.2007 // {
1374
dr_button_clean:
1375
    mov  ecx, 3*65536+13
1376
    mcall 8
1377
    ret
1378
; } \\ Alver \\
31 halyavin 1379
 
1380
draw_menuet_icon:
1381
 
1382
    pusha
1383
 
633 diamond 1384
; // Alver 26.08.2007 // {
1385
; Inserted code for drowing buttons 103, 104, 105 (Clean, Restore, Exchange windows)
1386
    mov  esi, dword [system_colours+24]    ; drawing buttons
1387
    and  esi, 0x00ffffff
1388
    mov  edx, 103
1389
    mov  ebx, 67*65536+13
1390
    call dr_button_clean
1391
    inc  edx
1392
    mov  ebx, 86*65536+13
1393
    call dr_button_clean
1394
    inc  edx
1395
    mov  ebx, 105*65536+13
1396
    call dr_button_clean
1397
    mov  ecx, dword [system_colours+28]
1398
    and  ecx, 0x00ffffff
1399
    xor  esi, esi
1400
    inc  esi
1401
    mov  edx, page_clean_but
1402
    mov  eax, 4
1403
    mov  ebx, 71*65536+6
1404
    int  0x40
1405
    inc  edx
1406
    mov  ebx, 90*65536+6
1407
    int  0x40
1408
    inc  edx
1409
    mov  ebx, 109*65536+6
1410
    int  0x40
1411
; } \\ Alver \\
1412
 
31 halyavin 1413
    cmp  [menu_enable],1
1414
    jne  no_menu
1415
 
1416
 
601 Rus 1417
    mov  eax, 8 			      ; M BUTTON
31 halyavin 1418
    mov  ebx, 10*65536 + 47
1419
    cmp  [minimize_left], 0
1420
    jne  @f
1421
    sub  ebx, 10*65536
1422
  @@:
1423
    mov  ecx, 1*65536
1424
    add  ecx, [b_size_y]
1425
    dec  ecx
1426
    mov  edx, 0x20000001
1427
    add  edx, [button_frames]
1428
    mov  esi, [wcolor]
1429
    int  0x40
1430
 
1431
    cmp  [graph_text], 1
1432
    jne  no_mtext
1433
 
1434
    push ebx
1435
    mov  eax,13
1436
    mov  ebx,12 shl 16+44  ;51
1437
    mov  ecx,1 shl 16+17
1438
    xor  edx,edx
1439
    int  0x40
1440
;    mov  ebx,63 shl 16+1
1441
    mov  ebx,56 shl 16+1
1442
    mov  ecx,2 shl 16+15
1443
    int  0x40
1444
    mov  ebx,57 shl 16+1
1445
    mov  ecx,4 shl 16+11
1446
    int  0x40
1447
    mov  ebx,58 shl 16+1
601 Rus 1448
    mov  ecx,6	shl 16+7
31 halyavin 1449
    int  0x40
1450
;    mov  ebx,66  shl 16+1
1451
;    mov  ecx,9 shl 16+1
1452
;    int  0x40
1453
    mov  ebx,13 shl 16+43 ;50
1454
    mov  ecx,2 shl 16+15
1455
    mov  edx,0x7700
1456
    int  0x40
1457
;    mov  ebx,62 shl 16+1
1458
;    mov  ecx,3 shl 16+14
1459
;    int  0x40
1460
    mov  ebx,56 shl 16+1
1461
    mov  ecx,4 shl 16+11
1462
    int  0x40
1463
    mov  ebx,57 shl 16+1
1464
    mov  ecx,6 shl 16+7
1465
    int  0x40
1466
    pop  ebx
1467
 
1468
    mov  eax, 4
1469
    mov  bx,  7
1470
    add  ebx, 8*65536
1471
    mov  ecx, 0x10ffffff
1472
    mov  edx, m_text
1473
    mov  esi, 4
1474
    int  0x40
1475
 
1476
    popa
1477
    ret
1478
 
1479
  no_mtext:
1480
 
1481
 
1482
 
1483
    mov  eax,[wcolor]
1484
    mov  [m_icon+4],eax
1485
 
93 diamond 1486
; load & display menuet.bmp
601 Rus 1487
	mov	eax, 70
1488
	mov	ebx, m_bmp_fileinfo
1489
	int	0x40
31 halyavin 1490
 
1491
    mov  eax,40
1492
    mov  ebx,0
1493
    mov  edi,image+53
1494
 
1495
   new_m_pix:
1496
 
1497
;    movzx ecx,byte [edi]
1498
;    shr  ecx,5
1499
 
93 diamond 1500
    cmp    byte [edi], 10
601 Rus 1501
    jb	   nopix
93 diamond 1502
    cmp    byte [edi+1], 10
601 Rus 1503
    jb	   nopix
93 diamond 1504
    cmp    byte [edi+2], 10
601 Rus 1505
    jb	   nopix
31 halyavin 1506
 
1507
    pusha
1508
    cmp  [minimize_left],0
1509
    jne  no_m_s2
1510
    sub  ebx,10
1511
  no_m_s2:
1512
;    mov  edx,[ecx*4+m_icon]
1513
    mov  edx,[edi+1]
1514
 
1515
    mov  ecx,eax
1516
    mov  eax,1
1517
    add  ebx,12
1518
    int  0x40
1519
    popa
1520
 
1521
   nopix:
1522
 
1523
    add  edi,3
1524
    add  ebx,1
1525
    cmp  ebx,40
1526
    jnz  new_m_pix
1527
 
1528
    mov  ebx,0
1529
    dec  eax
1530
    jnz  new_m_pix
1531
 
1532
  no_menu:
1533
 
1534
    popa
1535
    ret
1536
 
1537
 
1538
draw_program_icons:
1539
 
1540
    pusha
1541
 
1542
    cmp  [icons],0
1543
    jne  dp_ret
1544
 
1545
    mov  edi,1
1546
    push edi
1547
 
1548
  new_icon_file:
1549
 
1550
    pusha
1551
    mov  edx,[esp+32]
1552
    add  edx,10
1553
    push edx
1554
    mov  esi,[wcolor]
1555
    mov  ecx,1*65536
1556
    add  ecx,[b_size_y]
1557
    dec  ecx
1558
    mov  eax,edi
1559
    dec  eax
1560
    imul eax,40
1561
    mov  ebx,eax
1562
    add  ebx,[icons_position]
1563
    shl  ebx,16
1564
    mov  bx,39
1565
    pop  edx
1566
    add  edx,[button_frames]
601 Rus 1567
    or	 edx, 0x20000000
31 halyavin 1568
    mov  eax,8
1569
    int  0x40
1570
    popa
1571
 
1572
    mov  ecx,[esp]
1573
    add  ecx,48
1574
    mov  [iconf+6],cl
1575
 
601 Rus 1576
	mov	eax, 70
1577
	mov	ebx, iconf_fileinfo
1578
	int	0x40
31 halyavin 1579
 
1580
    mov  eax,0
1581
    mov  ebx,32
1582
    mov  edi,image+51+32*33*3
1583
 
601 Rus 1584
   np2: 			    ; new pixel of file
31 halyavin 1585
 
1586
    mov  edx,[edi]
1587
    and  edx,0xffffff
1588
 
601 Rus 1589
    cmp  eax,3			    ; Y draw limits
1590
    jb	 nopix2
31 halyavin 1591
    cmp  eax,36
601 Rus 1592
    jg	 nopix2
1593
    cmp  ebx,38 		    ; X draw limits
1594
    jg	 nopix2
31 halyavin 1595
    cmp  ebx,2
601 Rus 1596
    jb	 nopix2
31 halyavin 1597
 
1598
    cmp  edx,0
601 Rus 1599
    jz	 nopix2
31 halyavin 1600
 
1601
    cmp  [graph_text],1
1602
    jne  no_icon_text
1603
 
1604
    pusha
1605
 
1606
    mov  ebx,[esp+32]
1607
    dec  ebx
1608
    imul ebx,40
1609
    add  ebx,8
1610
    add  ebx,[icons_position]
1611
    shl  ebx,16
1612
    mov  bx,7
1613
 
1614
    mov  eax,4
1615
    mov  ecx,0xffffff
1616
    mov  edx,[esp+32]
1617
    dec  edx
1618
    imul edx,4
1619
    add  edx,mi_text
1620
    mov  esi,4
1621
    int  0x40
1622
 
1623
    popa
1624
 
1625
    jmp  nopix2
1626
 
1627
  no_icon_text:
1628
 
1629
    mov  esi,[esp]
1630
    pusha
1631
    push edx
1632
    mov  ecx,eax
1633
    add  ecx,2
1634
    mov  eax,esi
1635
    dec  eax
1636
    imul eax,40
1637
    add  ebx,eax
1638
    add  ebx,3
1639
    add  ebx,[icons_position]
1640
    pop  edx
1641
    mov  eax,1
1642
    int  0x40
1643
    popa
1644
 
1645
  nopix2:
1646
 
1647
    sub  edi,3
1648
    dec  ebx
1649
    jnz  np2
1650
 
1651
    mov  ebx,32
1652
    add  eax,1
1653
    cmp  eax,32
1654
    jnz  np2
1655
 
1656
    add  dword [esp],1
1657
    mov  edi,[esp]
1658
    cmp  dword [esp],4
1659
    jbe  new_icon_file
1660
    add  esp,4
1661
 
1662
    mov  eax,4
1663
    mov  ebx,40
1664
    imul ebx,3
1665
    add  ebx,[icons_position]
1666
    add  ebx,10
1667
    shl  ebx,16
1668
    mov  bx,23
1669
    mov  ecx,[wcolor]
1670
    mov  edx,gpl
1671
    mov  esi,3
1672
    int  0x40
1673
 
1674
  dp_ret:
1675
 
1676
    popa
1677
    ret
1678
 
1679
 
1680
 
1681
draw_info:    ; draw cpu usage, time, date
1682
 
1683
    pusha
1684
 
1685
    cmp  [setup_enable],1
1686
    jne  no_setup
1687
 
1688
    cmp  [minimize_right],0
1689
    jne  no_m_r
1690
    add  [maxx],10
1691
 
1692
   no_m_r:
1693
 
1694
    mov  eax,3
1695
    int  0x40
1696
    cmp  eax,[ptime]
601 Rus 1697
    jz	 _ret
31 halyavin 1698
    mov  [ptime],eax
1699
 
1700
    call draw_cpu_usage
1701
 
1702
    mov  eax,[maxx]   ; blink sec
1703
    sub  eax,33
1704
    shl  eax,16
1705
    mov  ebx,eax
1706
    add  ebx,9
1707
    mov  eax,3
1708
    int  0x40
1709
    cmp  [graph_text],1
1710
    jne  no_y4
1711
    sub  bx,2
1712
  no_y4:
1713
    mov  ecx,eax
1714
    shr  ecx,16
1715
    and  ecx,1
1716
    mov  edx,[bte]
1717
    sub  edx,[wcolor]
1718
    imul ecx,edx
1719
    add  ecx,[wcolor]
1720
    mov  edx,sec
1721
    mov  eax,4
1722
    mov  esi,1
1723
    int  0x40
1724
 
1725
 
304 diamond 1726
;    mov  eax,26          ; check for change in time or country
1727
;    mov  ebx,5
1728
;    int  0x40
1729
;    mov  edx,eax
31 halyavin 1730
    mov  eax,26
1731
    mov  ebx,2
1732
    mov  ecx,9
1733
    int  0x40
304 diamond 1734
;    add  edx,eax
1735
    mov  edx,eax
31 halyavin 1736
    mov  eax,3
1737
    int  0x40
1738
    and  eax,0xffff
1739
    add  edx,eax
1740
    cmp  edx,[checks]
601 Rus 1741
    je	 _ret
31 halyavin 1742
    mov  [checks],edx
1743
 
1744
    mov  ebx,[maxx]
1745
    sub  ebx,48 ;;94 ;;74
1746
    shl  ebx,16
1747
    add  ebx,33 ;;84 ;;64
1748
 
601 Rus 1749
    mov  eax,8		     ; time/date button
31 halyavin 1750
    mov  ecx,3 *65536
1751
    add  ecx,[b_size_y]
1752
;    dec  ecx
1753
    sub  cx,5
1754
    mov  edx,2+0x20000000
1755
    mov  esi,[wcolor]
1756
    int  0x40
1757
    pusha
1758
    mov  eax,13
1759
    add  ebx,10*65536-16
1760
    add  ecx,5*65536-8
1761
    mov  edx,[wcolor]
1762
    int  0x40
1763
    popa
1764
    and  edx,0xffff
1765
    add  edx,[button_frames]
1766
    int  0x40
1767
 
1768
    mov  eax,8
1769
    mov  ebx,[maxx]
1770
    sub  ebx,77 ;80
1771
    shl  ebx,16
1772
    add  ebx,12
1773
    mov  ecx,5 shl 16+10
1774
    mov  edx,16+0x20000000  ;button 16
1775
    mov  esi,[wcolor]
1776
    int  0x40
1777
    sub  ebx,17 shl 16
601 Rus 1778
    inc  edx		    ;button 17
304 diamond 1779
;    int  0x40
31 halyavin 1780
    add  ebx,33 shl 16
1781
    mov  bx,8
601 Rus 1782
    inc  edx		    ;button 18
31 halyavin 1783
    int  0x40
304 diamond 1784
    sub  ebx,30 shl 16
31 halyavin 1785
    mov  bx,10
601 Rus 1786
    inc  edx		    ;button 19
31 halyavin 1787
    int  0x40
1788
    sub  ebx,14 shl 16
601 Rus 1789
    inc  edx		    ;button 20
31 halyavin 1790
    int  0x40
51 mikedld 1791
    sub  ebx,12 shl 16
1792
    mov  bx,8
1793
    mov  ecx,6 shl 16+10
601 Rus 1794
    inc  edx	    ;button 21
51 mikedld 1795
    int  0x40
633 diamond 1796
    sub  ebx,24 shl 16  ; << Alver 25.08.2007 >> 18 shl 16
601 Rus 1797
    inc  edx	    ;button 22
51 mikedld 1798
    int  0x40
1799
 
31 halyavin 1800
    ; flags
1801
 
304 diamond 1802
;    mov  eax,26
1803
;    mov  ebx,5
1804
;    int  0x40
1805
;    mov  ebx,eax
1806
;
1807
;    mov  eax,1
1808
;    mov  [type_lang],al
1809
;    call draw_flag
31 halyavin 1810
 
1811
    mov  eax,26
1812
    mov  ebx,2
1813
    mov  ecx,9
1814
    int  0x40
1815
    mov  ebx,eax
1816
 
1817
    mov  eax,2
1818
    mov  [type_lang],al
1819
    call draw_flag
1820
 
1821
    mcall 18,8,1
1822
    mov  [sound_flag],al
1823
 
1824
    mov  ebx,[maxx]
304 diamond 1825
    sub  ebx,92 ;109 ;112 ;28
31 halyavin 1826
    shl  ebx,16
1827
    mov  bx,12
1828
    mov  ecx, 4*65536+13
1829
    mov  edx,0
1830
    mov  eax,13
1831
    int  0x40
1832
    add  ebx,1 shl 16
1833
    sub  bx,2
1834
    mov  ecx,5 shl 16+11
1835
    mov  edx,0xcc
1836
    int  0x40
1837
    add  ebx,1 shl 16
1838
    mov  bx,5
1839
    mov  ecx,8 shl 16+5
1840
    mov  edx,0xdddd00
1841
    int  0x40
1842
    add  ebx,5 shl 16
1843
    mov  bx,1
1844
    mov  ecx,7 shl 16+7
1845
    int  0x40
1846
    add  ebx,1 shl 16
1847
    mov  ecx,6 shl 16+9
1848
    int  0x40
1849
    add  ebx,1 shl 16
1850
    mov  ecx,5 shl 16+11
1851
    int  0x40
1852
 
1853
;    cmp  [music_type],0
1854
;    jne   dalshe
1855
    cmp  [sound_flag],0
601 Rus 1856
    je	 dalshe
31 halyavin 1857
 
1858
    sub  ebx,8 shl 16
1859
    ror  ebx,16
1860
    mov  cx,bx
1861
    rol  ebx,16
1862
    mov  bx,cx
1863
    add  bx,8
1864
    mov  ecx,5 shl 16+15
1865
    mov  edx,0xff0000
1866
    mov  eax,38
1867
    int  0x40
1868
    add  ebx,1 shl 16
1869
    inc  bx
1870
    int  0x40
1871
    rol  ecx,16
1872
    int  0x40
1873
    sub  ebx,1 shl 16
1874
    dec  bx
1875
    int  0x40
1876
 
1877
dalshe:
1878
 
1879
    mov  ebx,[maxx]
304 diamond 1880
    sub  ebx,106;123
31 halyavin 1881
    shl  ebx,16
1882
    mov  bx,12
1883
    mov  ecx, 4*65536+13
1884
    mov  edx,0
1885
    mov  eax,13
1886
    int  0x40
1887
    add  ebx,1 shl 16
1888
    sub  bx,2
1889
    mov  ecx,5 shl 16+11
1890
    mov  edx,0xffcc00
1891
    int  0x40
1892
    mov  eax,4
1893
    mov  ebx,[maxx]
304 diamond 1894
    sub  ebx,104;121
31 halyavin 1895
    shl  ebx,16
1896
    mov  bx,7
1897
    mov  ecx,0x10000000
1898
    mov  edx,file_sys
1899
    mov  esi,1
1900
    int  0x40
1901
    add  ebx,1 shl 16
1902
    int  0x40
1903
 
51 mikedld 1904
    mov  edx,0
1905
    mov  eax,13
1906
    mov  ebx,[maxx]
304 diamond 1907
    sub  ebx,117;134
51 mikedld 1908
    shl  ebx,16
1909
    mov  bx,9
1910
    mov  ecx,6 shl 16+11
1911
    int  0x40
633 diamond 1912
; // Alver 25.08.2007 // {
1913
  ;  sub  ebx,18 shl 16
1914
  ;  int  0x40
1915
  ;  add  ebx,19 shl 16
1916
    sub  ebx,24 shl 16 ; 18 shl 16
51 mikedld 1917
    int  0x40
633 diamond 1918
    add  ebx,25 shl 16 ; 19 shl 16
1919
; } \\ Alver \\
51 mikedld 1920
    sub  bx,2
1921
    mov  ecx,7 shl 16+9
1922
    mov  edx,0xffffff
1923
    int  0x40
633 diamond 1924
; // Alver 25.08.2007 // {
1925
 ;   sub  ebx,18 shl 16
1926
    sub  ebx,24 shl 16
1927
; } \\ Alver \\
51 mikedld 1928
    int  0x40
1929
 
1930
    mov  eax,4
1931
    mov  edx,page_a1
1932
    mov  ebx,[maxx]
633 diamond 1933
; // Alver 25.08.2007 // {
1934
   ; sub  ebx,133;150
1935
    sub  ebx, 139
1936
; } \\ Alver \\
51 mikedld 1937
    shl  ebx,16
1938
    mov  bx,8
633 diamond 1939
    mov  esi,5     ;4
51 mikedld 1940
    int  0x40
1941
    add  ebx,1 shl 16
1942
    int  0x40
1943
 
1944
    mov  eax,47
633 diamond 1945
    mov  ebx,0x20000  ; 0x10100 (
51 mikedld 1946
    mov  ecx,[page_list]
1947
    mov  edx,[maxx]
633 diamond 1948
    sub  edx,130 ; 124 (
51 mikedld 1949
    shl  edx,16
1950
    mov  dx,7
1951
    mov  esi,0xffffff
1952
    int  0x40
1953
 
31 halyavin 1954
;    sub  ebx,14 shl 16
1955
;    mov  bx,7
1956
;    mov  edx,turn_text
1957
;    mov  esi,1
1958
 
1959
;    mov  ecx,0x60a060 ;[wcolor]
1960
;    add  ecx,0x303030
1961
;    mov  eax,4
1962
;    int  0x40
1963
;    add  ebx,1 shl 16
1964
;    int  0x40
1965
;    add  ebx,1 shl 16
1966
;    int  0x40
1967
;    add  ebx,1 shl 16
1968
;    int  0x40
1969
 
1970
;    add  ebx,1 shl 16
1971
;    mov  ecx,0x60a060 ;[wcolor]
1972
;    int  0x40
1973
;    add  ebx,1 shl 16
1974
;    int  0x40
1975
;    add  ebx,1 shl 16
1976
;    sub  ecx,0x303030
1977
;    int  0x40
1978
 
1979
;    sub  ebx,6 shl 16
1980
;    mov  bx,1
1981
;    mov  ecx,2 shl 16+15
1982
;    mov  edx,0x60a060  ;[wcolor]
1983
;    add  edx,0x303030
1984
;    mov  eax,13
1985
;    int  0x40
1986
;    add  ebx,1 shl 16
1987
;    mov  bx,1
1988
;    mov  edx,0x60a060  ;[wcolor]
1989
;    int  0x40
1990
;    add  ebx,1 shl 16
1991
;    mov  bx,1
1992
;    sub  edx,0x303030
1993
;    int  0x40
1994
;    add  ebx,1 shl 16
1995
;    mov  edx,[wcolor]
1996
;    int  0x40
1997
 
601 Rus 1998
    mov  eax,3			; get time
31 halyavin 1999
    int  0x40
2000
 
2001
    movzx ebx,al
2002
    shr   eax,8
2003
    movzx ecx,al
2004
    shr   eax,8
2005
    movzx edx,al
2006
 
2007
    ; ebx ecx edx h m s
2008
 
2009
    push ebx
2010
    push ecx
2011
 
2012
    mov  eax,[maxx]
2013
    sub  eax,32
2014
    shl  eax,16
2015
    mov  ebx,eax
2016
    add  ebx,9
2017
 
2018
    mov  ecx,[bte]
2019
 
2020
    cmp  [graph_text],1
2021
    jne  no_y3
2022
    sub  bx,2
2023
    mov  ecx,0xffffff
2024
  no_y3:
2025
 
2026
 
601 Rus 2027
    mov  edx,[esp]	       ; __:_X
31 halyavin 2028
    and  edx,15
2029
    mov  eax,4
2030
    add  ebx,10*65536
2031
    add  edx,text
2032
    mov  esi,1
2033
    int  0x40
2034
 
601 Rus 2035
    pop  edx			; __:X_
31 halyavin 2036
    shr  edx,4
2037
    and  edx,15
2038
    mov  eax,4
2039
    sub  ebx,6*65536
2040
    add  edx,text
2041
    mov  esi,1
2042
    int  0x40
2043
 
601 Rus 2044
    mov  edx,[esp]	       ; _X:__
31 halyavin 2045
    and  edx,15
2046
    mov  eax,4
2047
    sub  ebx,11*65536
2048
    add  edx,text
2049
    mov  esi,1
2050
    int  0x40
2051
 
601 Rus 2052
    pop  edx			; X_:__
31 halyavin 2053
    shr  edx,4
2054
    and  edx,15
2055
    mov  eax,4
2056
    sub  ebx,6*65536
2057
    add  edx,text
2058
    mov  esi,1
2059
    int  0x40
2060
 
2061
    call draw_cpu_usage
2062
 
2063
  _ret:
2064
 
2065
    cmp  [minimize_right],0
2066
    jne  no_m_r2
2067
    sub  [maxx],10
2068
   no_m_r2:
2069
 
2070
   no_setup:
2071
 
2072
    popa
2073
    ret
2074
 
2075
 
2076
 
2077
draw_cpu_usage:
2078
 
318 heavyiron 2079
    pushad
31 halyavin 2080
 
2081
    mov  [ysi],30
2082
    cmp  [graph_text],1
2083
    jne  @f
318 heavyiron 2084
    mov  [ysi],12
31 halyavin 2085
  @@:
2086
 
2087
 
2088
    mov  eax,18    ; TSC / SEC
2089
    mov  ebx,5
2090
    int  0x40
2091
    shr  eax,20
2092
    push eax
2093
    mov  eax,18    ; IDLE / SEC
2094
    mov  ebx,4
2095
    int  0x40
2096
    shr  eax,20
2097
    xor  edx,edx
2098
    imul eax,[ysi]
2099
 
2100
    cdq
2101
    pop  ebx
2102
    inc  ebx
2103
    div  ebx
318 heavyiron 2104
    cmp  eax,[ysi]
2105
    jng  no_bug
2106
    mov  eax,[ysi]
2107
no_bug:
31 halyavin 2108
    push eax
2109
 
2110
    mov  eax,13
2111
    mov  ebx,[maxx]
372 heavyiron 2112
    sub  ebx,60
31 halyavin 2113
    shl  ebx,16
372 heavyiron 2114
    add  ebx,8
2115
    mov  ecx,5 shl 16
318 heavyiron 2116
    add  ecx,[ysi]
372 heavyiron 2117
    mov  edx,0xdd2222
31 halyavin 2118
    int  0x40
372 heavyiron 2119
 
31 halyavin 2120
    pop  eax
372 heavyiron 2121
    mov  ecx,5 shl 16
2122
    add  ecx,eax
31 halyavin 2123
    mov  eax,13
372 heavyiron 2124
    mov  edx,0x44aa44
31 halyavin 2125
    int  0x40
2126
 
318 heavyiron 2127
    popad
31 halyavin 2128
    ret
2129
 
601 Rus 2130
include 'detect.asm'
2131
include 'ctx_menu.asm'
2132
 
31 halyavin 2133
; DATA
2134
 
2135
stripe:
601 Rus 2136
    dd	-0x010101
2137
    dd	-0x010101
2138
    dd	-0x020202
2139
    dd	-0x010101
2140
    dd	-0x000000
31 halyavin 2141
 
601 Rus 2142
    dd	 0x000000
2143
    dd	 0x010101
2144
    dd	 0x020202
2145
    dd	 0x010101
2146
    dd	 0x010101
31 halyavin 2147
 
2148
m_icon:
601 Rus 2149
    dd	0x0
2150
    dd	0x808080
2151
    dd	0x000000
2152
    dd	0x000000
2153
    dd	0xffffff
31 halyavin 2154
 
2155
 
2156
lsz m_text,\
2157
  ru, "МЕНЮ",\
275 kaitz 2158
  en, "MENU",\
2159
  et, "MEN▄▄"
31 halyavin 2160
 
2161
mi_text   db   'WAVETETRBGRDGPL '
2162
 
275 kaitz 2163
flag_text db 'EnFiGeRuFrEt'
31 halyavin 2164
 
2165
type_lang db 0
2166
;music_type db 1
2167
sound_flag db 0
2168
button_frames  dd  0x0
2169
 
601 Rus 2170
checks	  dd -1
31 halyavin 2171
hidetext  db 0x11,0x10,0x1e
2172
 
2173
turn_text db  '><'
601 Rus 2174
gpl	  db  'GPL'
31 halyavin 2175
 
2176
chlang db 'LANG',0
304 diamond 2177
;syslang db 'SLAN',0
31 halyavin 2178
 
2179
contrast  db 0
2180
 
2181
running_applications  dd  0x100
2182
max_applications      dd  11
2183
 
601 Rus 2184
current_alt_tab_app	dd	-1
443 diamond 2185
 
51 mikedld 2186
page_list  dd 0
2187
draw_start_position dd 0
2188
draw_window_1 db 0
2189
 
31 halyavin 2190
b_size_y:  dd  0x0
2191
ysi  dd  0
2192
small_draw dd 0x0
2193
 
601 Rus 2194
ptime	dd 0x0
2195
maxx	dd 0x0
2196
text	db '0123456789'
633 diamond 2197
; // Alver 25.08.2007 // {
2198
;page_a1 db '<  >'
2199
page_a1        db '<   >'
2200
page_clean_but db 25,24,18
2201
; } \\ Alver \\
601 Rus 2202
bte	dd 0xccddee
31 halyavin 2203
 
601 Rus 2204
wcolor	dd 0x506070
31 halyavin 2205
 
601 Rus 2206
sec	db ': '
2207
pros	db '                                                  '
2208
	db '                                                  '
31 halyavin 2209
 
601 Rus 2210
screenxy    dd	0x0
2211
stcount     dd	0x0
31 halyavin 2212
 
93 diamond 2213
setup_exec:
601 Rus 2214
	dd	7
2215
	dd	0
2216
.cmdline dd	?
2217
	dd	0
2218
	dd	0
2219
	db	'/sys/'
2220
file_sys db	'SETUP',0
93 diamond 2221
 
2222
exec_fileinfo:
601 Rus 2223
	dd	7
2224
	dd	0
2225
	dd	0
2226
	dd	0
2227
	dd	0
2228
	db	0
2229
.name	dd	?
93 diamond 2230
 
601 Rus 2231
end_name	db	'/sys/END',0
2232
menu_name	db	'/sys/@MENU',0
2233
calendar_name	db	'/sys/CALENDAR',0
2234
sysmeter_name	db	'/sys/GMON',0
93 diamond 2235
 
2236
dat_fileinfo:
601 Rus 2237
	dd	0
2238
	dd	0
2239
	dd	0
2240
	dd	1024
2241
	dd	I_END
2242
	db	'/sys/PANEL.DAT',0
93 diamond 2243
 
2244
m_bmp_fileinfo:
601 Rus 2245
	dd	0
2246
	dd	0
2247
	dd	0
2248
	dd	8192
2249
	dd	image
2250
	db	'/sys/MENUET.BMP',0
93 diamond 2251
 
2252
iconf_fileinfo:
601 Rus 2253
	dd	0
2254
	dd	0
2255
	dd	0
2256
	dd	8192
2257
	dd	image
2258
	db	'/sys/'
2259
iconf	db	'MBAR_IX.BMP',0
93 diamond 2260
 
31 halyavin 2261
I_END:
51 mikedld 2262
 
2263
screen_size:
2264
  .height dw ?
2265
  .width  dw ?
2266
 
633 diamond 2267
this_slot      dd 0           ; Slot of this process
2268
max_slot       dd 255
31 halyavin 2269
system_colours rd 10
2270
app_list rd 50
601 Rus 2271
alt_tab_list	rd	256*2
2272
alt_tab_list_size dd	?
494 spraid 2273
process_info_buffer  rb 1024
633 diamond 2274
procinfo_for_detect  rb 1024
31 halyavin 2275
tictable:
2276
  rd 256
601 Rus 2277
 
2278
	rb	256
2279
detect_stack:
2280
	rb	256
2281
ctx_menu_stack:
2282
 
2283
panel_x_pos	rd	1
2284
panel_y_pos	rd	1
31 halyavin 2285
image: