Rev 178 | Rev 280 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 178 | Rev 267 | ||
---|---|---|---|
Line 1... | Line 1... | ||
1 | ;POP_WIDTH = (popup_text.max_title+popup_text.max_accel+6)*6 |
1 | ;POP_WIDTH = (popup_text.max_title+popup_text.max_accel+6)*6 |
2 | POP_IHEIGHT = 16 |
2 | POP_IHEIGHT = 16 |
3 | ;POP_HEIGHT = popup_text.cnt_item*POP_IHEIGHT+popup_text.cnt_sep*4+4 |
3 | ;POP_HEIGHT = popup_text.cnt_item*POP_IHEIGHT+popup_text.cnt_sep*4+4 |
Line 4... | Line -... | ||
4 | - | ||
5 | func calc_middle |
- | |
6 | shr eax,1 |
- | |
7 | shr ebx,1 |
- | |
8 | and eax,0x007F7F7F |
- | |
9 | and ebx,0x007F7F7F |
- | |
10 | add eax,ebx |
- | |
11 | ret |
- | |
12 | endf |
- | |
13 | - | ||
14 | func calc_3d_colors |
- | |
15 | pushad |
- | |
16 | m2m [cl_3d_normal],[sc.work] |
- | |
17 | m2m [cl_3d_inset],[sc.work_graph] |
- | |
18 | push [cl_3d_normal] |
- | |
19 | add byte[esp],48 |
- | |
20 | jnc @f |
- | |
21 | mov byte[esp],255 |
- | |
22 | @@: add byte[esp+1],48 |
- | |
23 | jnc @f |
- | |
24 | mov byte[esp+1],255 |
- | |
25 | @@: add byte[esp+2],48 |
- | |
26 | jnc @f |
- | |
27 | mov byte[esp+2],255 |
- | |
28 | @@: pop [cl_3d_outset] |
- | |
29 | mov eax,[cl_3d_inset] |
- | |
30 | mov ebx,[cl_3d_outset] |
- | |
31 | call calc_middle |
- | |
32 | mov [cl_3d_pushed],eax |
- | |
33 | mov eax,[cl_3d_normal] |
- | |
34 | mov ebx,[sc.work_text] |
- | |
35 | call calc_middle |
- | |
36 | mov [cl_3d_grayed],eax |
- | |
37 | popad |
- | |
38 | ret |
- | |
39 | endf |
- | |
40 | - | ||
41 | func draw_3d_panel ; x,y,w,h |
- | |
42 | cmp dword[esp+8],4 |
- | |
43 | jl .exit |
- | |
44 | cmp dword[esp+4],4 |
- | |
45 | jl .exit |
- | |
46 | mov ebx,[esp+16-2] |
- | |
47 | mov bx,[esp+8] |
- | |
48 | inc ebx |
- | |
49 | mov ecx,[esp+12-2] |
- | |
50 | mov cx,[esp+4] |
- | |
51 | inc ecx |
- | |
52 | mcall 13,,,[cl_3d_normal];0x00EEEEEE;[sc.work] |
- | |
53 | dec ebx |
- | |
54 | add bx,[esp+16] |
- | |
55 | mov cx,[esp+12] |
- | |
56 | mcall 38,,,[cl_3d_inset];0x006382BF;[sc.work_text] |
- | |
57 | add ecx,[esp+4-2] |
- | |
58 | add cx,[esp+4] |
- | |
59 | mcall |
- | |
60 | mov bx,[esp+16] |
- | |
61 | mov ecx,[esp+12-2] |
- | |
62 | mov cx,[esp+4] |
- | |
63 | add cx,[esp+12] |
- | |
64 | mcall |
- | |
65 | add ebx,[esp+8-2] |
- | |
66 | add bx,[esp+8] |
- | |
67 | mcall |
- | |
68 | mov ebx,[esp+16-2] |
- | |
69 | mov bx,[esp+8] |
- | |
70 | add bx,[esp+16] |
- | |
71 | add ebx,1*65536-1 |
- | |
72 | mov ecx,[esp+12-2] |
- | |
73 | mov cx,[esp+12] |
- | |
74 | add ecx,0x00010001 |
- | |
75 | mcall ,,,[cl_3d_outset] |
- | |
76 | mov bx,[esp+16] |
- | |
77 | inc ebx |
- | |
78 | mov ecx,[esp+12-2] |
- | |
79 | mov cx,[esp+4] |
- | |
80 | add cx,[esp+12] |
- | |
81 | add ecx,2*65536-1 |
- | |
82 | mcall |
- | |
83 | .exit: |
- | |
84 | ret 4*4 |
- | |
85 | endf |
- | |
86 | 4 | ||
87 | popup_thread_start: |
5 | popup_thread_start: |
88 | mov [popup_active],1 |
6 | mov [popup_active],1 |
89 | mov [pi_cur],0 |
7 | mov [pi_cur],0 |
90 | mov ebp,[esp] |
8 | mov ebp,[esp] |
Line 313... | Line 231... | ||
313 | .exit: |
231 | .exit: |
314 | mcall 12,2 |
232 | mcall 12,2 |
315 | ret |
233 | ret |
316 | endf |
234 | endf |
Line -... | Line 235... | ||
- | 235 | ||
- | 236 | func setup_main_menu_popup |
|
- | 237 | mov ebx,[p_info.box.left] |
|
- | 238 | add ebx,[p_info.client_box.left] |
|
- | 239 | @@: dec ecx |
|
- | 240 | jz @f |
|
- | 241 | add edx,8+1 |
|
- | 242 | movzx esi,byte[edx-1] |
|
- | 243 | add edx,esi |
|
- | 244 | jmp @b |
|
- | 245 | @@: movzx ecx,word[edx+2] |
|
- | 246 | add ebx,ecx |
|
- | 247 | ||
- | 248 | mov [eax+POPUP.x],bx |
|
- | 249 | mov ebx,[p_info.box.top] |
|
- | 250 | add ebx,[p_info.client_box.top] |
|
- | 251 | add ebx,ATOPH-1 |
|
- | 252 | mov [eax+POPUP.y],bx |
|
- | 253 | mov [POPUP_STACK],eax |
|
- | 254 | ret |
|
- | 255 | endf |
|
- | 256 | ||
- | 257 | onshow: |
|
- | 258 | ||
- | 259 | .file: |
|
- | 260 | or byte[mm.File+3],0x01 |
|
- | 261 | cmp [f_info.length],0 |
|
- | 262 | jne @f |
|
- | 263 | and byte[mm.File+3],0xFE |
|
- | 264 | @@: ret |
|
- | 265 | ||
- | 266 | .edit: |
|
- | 267 | or byte[mm.Edit+2],0x01 |
|
- | 268 | cmp [copy_size],0 |
|
- | 269 | jne @f |
|
- | 270 | and byte[mm.Edit+2],0xFE |
|
- | 271 | @@: or dword[mm.Edit+0],0x01000101 |
|
- | 272 | cmp [sel.selected],0 |
|
- | 273 | jne @f |
|
- | 274 | and dword[mm.Edit+0],0xFEFFFEFE |
|
- | 275 | @@: ret |
|
- | 276 | ||
- | 277 | .search: |
|
- | 278 | mov byte[mm.Search+0],0 |
|
- | 279 | ret |
|
- | 280 | .run: |
|
- | 281 | ret |
|
- | 282 | .recode: |
|
- | 283 | ret |
|
- | 284 | .options: |
|
- | 285 | mov word[mm.Options+0],0 |
|
- | 286 | mov byte[mm.Options+5],0 |
|
- | 287 | or byte[mm.Options+2],0x02 |
|
- | 288 | test [options],OPTS_SECURESEL |
|
- | 289 | jnz @f |
|
- | 290 | and byte[mm.Options+2],0xFD |
|
- | 291 | @@: or byte[mm.Options+3],0x02 |
|
- | 292 | test [options],OPTS_AUTOBRACES |
|
- | 293 | jnz @f |
|
- | 294 | and byte[mm.Options+3],0xFD |
|
- | 295 | @@: or byte[mm.Options+4],0x02 |
|
- | 296 | test [options],OPTS_AUTOINDENT |
|
- | 297 | jnz @f |
|
- | 298 | and byte[mm.Options+4],0xFD |
|
- | 299 | @@: or byte[mm.Options+6],0x02 |
|
- | 300 | test [options],OPTS_OPTIMSAVE |
|
- | 301 | jnz @f |
|
- | 302 | and byte[mm.Options+6],0xFD |
|
- | 303 | @@: or byte[mm.Options+8],0x02 |
|
- | 304 | test [options],OPTS_LINENUMS |
|
- | 305 | jnz @f |
|
- | 306 | and byte[mm.Options+8],0xFD |
|
- | 307 | @@: ret |
|
317 | 308 | ||
318 | pi_sel dd ? |
309 | pi_sel dd ? |
319 | pi_cur dd ? |
310 | pi_cur dd ? |
320 | p_pos dd ? |
311 | p_pos dd ? |
321 | popup_active db 0 |
312 | popup_active db 0 |