Subversion Repositories Kolibri OS

Rev

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

Rev Author Line No. Line
255 heavyiron 1
;---------------------------------------------
2
;-----------panel BUTTONS---------------------
3
;---------------------------------------------
4
buttons:
5
 
6
	cmp [Current_instrument],21
6359 IgorA 7
	jne @f
255 heavyiron 8
	cmp [instrument_used],1
6359 IgorA 9
	jne @f
255 heavyiron 10
	cmp [Activate_instrument],0
6359 IgorA 11
	jne @f
255 heavyiron 12
	cmp [crossing],1
6359 IgorA 13
	jne @f
14
		mov [finishing_crossing],1
15
		call TakeButtonInstruments
16
	@@:
255 heavyiron 17
 
6359 IgorA 18
	mcall SF_GET_BUTTON
255 heavyiron 19
 
20
	shr eax,8
21
 
22
	cmp eax,1
23
	jne no_exit
6359 IgorA 24
		mov eax,CursorsID
25
		call delete_cursors
26
		mcall SF_TERMINATE_PROCESS
255 heavyiron 27
	no_exit:
28
 
29
	mov [Current_instrument],eax
6359 IgorA 30
	call button_handler_main_menu
255 heavyiron 31
 
32
	; set cursor for current instrument
33
	pushad
34
 
35
	mov eax,CursorsID
36
	mov ebx,[Current_instrument]
37
 
38
	call set_cursor
39
	popad
40
 
41
	cmp eax,10
42
	jl still
43
 
44
	;save instrumnets 10-40
45
	cmp eax,40
46
	jae no_save_last_instrument
47
 
48
	 mov [Last_instrument],eax
49
 
50
	no_save_last_instrument:
51
 
52
	cmp eax,10
53
	je still
54
 
55
	cmp eax,14
56
	je still
57
 
58
	cmp eax,11
59
	je still
60
 
61
	cmp eax,13
62
	je still
63
 
64
	cmp eax,12
65
	je still
66
 
67
	cmp eax,51
68
	jne no_palette_
69
 
70
	call TakeButtonInstruments
71
	jmp still
72
 
73
	no_palette_:
74
 
75
	cmp eax,17
76
	je still
77
 
78
	cmp eax,21
79
	jne no_allocation__
80
 
81
	and [Activate_instrument],0
82
	jmp still
83
 
84
	no_allocation__:
85
 
86
	cmp eax,20
87
	jne no_kontur__
88
 
89
	and [instrument_used],0
90
	jmp still
91
 
92
	no_kontur__:
93
 
94
	call TakeButtonInstruments
95
 
96
	jmp still