Subversion Repositories Kolibri OS

Rev

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

Rev Author Line No. Line
824 mikedld 1
diff16 'tp-dialog.asm',0,$
2
 
258 mikedld 3
;-----------------------------------------------------------------------------
617 mikedld 4
proc define_3d_button ;///////////////////////////////////////////////////////
258 mikedld 5
;-----------------------------------------------------------------------------
6
; ebx = 
7
; ecx = 
8
; esp+4*3 = id
9
; esp+4*2 = text
10
; esp+4*1 = text length
11
;-----------------------------------------------------------------------------
12
	pushad
13
	mov	edx,[esp+4*8+4+4*2]
14
	or	edx,0x40000000
15
	mcall	8
16
	mov	eax,[esp+4*8+4*1]
17
	add	eax,2
18
	imul	eax,6
19
	pushad
20
	shr	ebx,16
21
	shr	ecx,16
22
	push	ebx ecx eax 15
23
	call	draw_3d_panel
24
	popad
25
	shr	ecx,16
26
	mov	bx,cx
27
	add	ebx,7*65536+4
28
	mcall	4,,[sc.work_text],[esp+4*8+4*2],[esp+4*8+4*1]
29
	popad
30
	ret	4*3
617 mikedld 31
endp
1624 mario79 32
;-----------------------------------------------------------------------------
258 mikedld 33
finddlg_handler:
34
	cmp	al,1
35
	je	.draw
36
	cmp	al,2
37
	je	.key
38
	cmp	al,3
39
	je	botdlg.button
40
	ret
41
 
42
  .draw:
43
	mov	ebx,[bot_ofs]
44
	add	ebx,(1+3)*65536+6
45
	mcall	4,,[sc.work_text],s_2find,s_2find.size+1
46
	mov	ecx,[bot_ofs]
47
	shl	ecx,16
48
	add	ecx,(3+17)*65536+15
49
 
50
	push	ecx
629 mikedld 51
	cmp	[bot_mode2],0
258 mikedld 52
	je	@f
53
	add	ebx,18
54
	mcall	4,,[sc.work_text],s_2replace,s_2replace.size+1
55
	mov	ecx,[esp]
56
	add	ecx,18*65536
57
    @@:
58
 
59
	mov	ebx,[p_info.client_box.width]
60
	shl	ebx,16
61
 
62
	push	20003
629 mikedld 63
	cmp	[bot_mode2],0
258 mikedld 64
	jne	.draw.lp1
65
	add	ebx,-(2+6*(s_2find.size+2))*65536+6*(s_2find.size+2)
66
	push	s_2find s_2find.size
67
	jmp	@f
68
 
69
  .draw.lp1:
70
	add	ebx,-(2+6*(s_2replace.size+2))*65536+6*(s_2replace.size+2)
71
	push	s_2replace s_2replace.size
72
 
73
    @@: call	define_3d_button
74
	sub	ebx,(6*(s_2cancel.size+2)+3)*65536
75
	mov	bx,6*(s_2cancel.size+2)
76
	push	20001 s_2cancel s_2cancel.size
77
	call	define_3d_button
78
 
79
	mov	ecx,[esp]
80
 
81
	mov	ebp,tb_find
82
	mov	eax,[p_info.client_box.width]
83
	sub	eax,6*(s_2find.size+2)+1
84
	add	eax,6*(s_2find.size+2)*65536
297 mikedld 85
	mov	dword[tbox.width],eax
258 mikedld 86
	add	ecx,-18*65536+1
297 mikedld 87
	mov	dword[tbox.height],ecx
258 mikedld 88
	call	textbox.draw
89
 
90
	pop	ecx
91
 
629 mikedld 92
	cmp	[bot_mode2],0
258 mikedld 93
	je	@f
94
	mov	ebp,tb_replace
95
	mov	eax,[p_info.client_box.width]
96
	sub	eax,6*(s_2replace.size+2)+1
97
	add	eax,6*(s_2replace.size+2)*65536
297 mikedld 98
	mov	dword[tbox.width],eax
258 mikedld 99
	inc	ecx
297 mikedld 100
	mov	dword[tbox.height],ecx
258 mikedld 101
	call	textbox.draw
102
    @@:
103
 
104
	ret
105
 
106
  .key:
107
	cmp	ebx,KEY_ESCAPE
108
	je	btn.bot.cancel
109
	cmp	ebx,KEY_RETURN
110
	je	btn.bot.find
111
	cmp	ebx,KEY_NUMRETURN
112
	je	btn.bot.find
113
	cmp	ebx,KEY_TAB
114
	je	..tab
115
	call	textbox.key
116
	ret
117
 
118
  ..tab:
629 mikedld 119
	cmp	[bot_mode2],0
258 mikedld 120
	je	@f
121
	mov	eax,tb_replace
122
	cmp	eax,[focused_tb]
123
	jne	.key.lp1
124
	mov	eax,tb_find
125
  .key.lp1:
126
	mov	[focused_tb],eax
127
	call	.draw
128
    @@: ret
1624 mario79 129
;-----------------------------------------------------------------------------
258 mikedld 130
osdlg_handler:
1624 mario79 131
	mov	[open_dialog],1
258 mikedld 132
	ret
133
 
1624 mario79 134
;	cmp	al,1
135
;	je	.draw
136
;	cmp	al,2
137
;	je	.key
138
;	cmp	al,3
139
;	je	botdlg.button
140
;	ret
258 mikedld 141
 
1624 mario79 142
;  .draw:
143
;	mov	ebx,[bot_ofs]
144
;	add	ebx,(1+3)*65536+6
145
;	mcall	4,,[sc.work_text],s_2filename,s_2filename.size
146
;	mov	ebx,[p_info.client_box.width]
147
;	shl	ebx,16
148
;	mov	ecx,[bot_ofs]
149
;	shl	ecx,16
150
;	add	ecx,(2+18)*65536+15
151
;
152
;	push	20002
153
;	cmp	[bot_mode2],0
154
;	jne	.draw.lp1
155
;	add	ebx,-(2+6*(s_2open.size+2))*65536+6*(s_2open.size+2)
156
;	push	s_2open s_2open.size
157
;	jmp	@f
158
;  .draw.lp1:
159
;	add	ebx,-(2+6*(s_2save.size+2))*65536+6*(s_2save.size+2)
160
;	push	s_2save s_2save.size
258 mikedld 161
 
1624 mario79 162
;    @@: call	define_3d_button
163
;	sub	ebx,(6*(s_2cancel.size+2)+3)*65536
164
;	mov	bx,6*(s_2cancel.size+2)
165
;	push	20001 s_2cancel s_2cancel.size
166
;	call	define_3d_button
258 mikedld 167
 
1624 mario79 168
;	cmp	[bot_mode2], 2	    ; exit-save dialog
169
;	jne	@f
595 Rus 170
 
1624 mario79 171
;	sub	ebx,(6*(s_2save_no.size+2)+3)*65536
172
;	mov	bx,6*(s_2save_no.size+2)
173
;	push	20007 s_2save_no s_2save_no.size
174
;	call	define_3d_button
595 Rus 175
 
1624 mario79 176
;    @@: mov	ebp,tb_opensave
177
;	mov	eax,[p_info.client_box.width]
178
;	sub	eax,6*(s_2filename.size+1)+1
179
;	add	eax,6*(s_2filename.size+1)*65536
180
;	mov	dword[tbox.width],eax
181
;	add	ecx,-18*65536+1
182
;	mov	dword[tbox.height],ecx
183
;	call	textbox.draw
258 mikedld 184
 
1624 mario79 185
;	ret
258 mikedld 186
 
1624 mario79 187
;  .key:
188
;	cmp	ebx,KEY_ESCAPE
189
;	je	btn.bot.cancel
190
;	cmp	ebx,KEY_RETURN
191
;	je	btn.bot.opensave
192
;	cmp	ebx,KEY_NUMRETURN
193
;	je	btn.bot.opensave
194
;	call	textbox.key
195
;	ret
196
;-----------------------------------------------------------------------------
258 mikedld 197
gotodlg_handler:
198
	cmp	al,1
199
	je	.draw
200
	cmp	al,2
201
	je	.key
202
	cmp	al,3
203
	je	botdlg.button
204
	ret
205
 
206
  .draw:
207
	mov	ebx,[bot_ofs]
208
	add	ebx,(1+3)*65536+6
209
	mcall	4,,[sc.work_text],s_2filename,s_2filename.size
210
	mov	ebx,[p_info.box.width]
211
	shl	ebx,16
212
	mov	ecx,[bot_ofs]
213
	shl	ecx,16
214
	add	ecx,(2+18)*65536+15
215
 
216
	push	20002
629 mikedld 217
	cmp	[bot_mode2],0
258 mikedld 218
	jne	.draw.lp1
219
	add	ebx,-(2+6*(s_2open.size+2))*65536+6*(s_2open.size+2)
220
	push	s_2open s_2open.size
221
	jmp	@f
222
  .draw.lp1:
223
	add	ebx,-(2+6*(s_2save.size+2))*65536+6*(s_2save.size+2)
224
	push	s_2save s_2save.size
225
 
226
    @@: call	define_3d_button
227
	sub	ebx,(6*(s_2cancel.size+2)+3)*65536
228
	mov	bx,6*(s_2cancel.size+2)
229
	push	20001 s_2cancel s_2cancel.size
230
	call	define_3d_button
231
 
232
	mov	ebp,tb_opensave
233
	mov	eax,[p_info.box.width]
234
	sub	eax,6*(s_2filename.size+3)
235
	add	eax,6*(s_2filename.size+2)*65536
297 mikedld 236
	mov	dword[tbox.width],eax
258 mikedld 237
	add	ecx,-18*65536+1
297 mikedld 238
	mov	dword[tbox.height],ecx
258 mikedld 239
	call	textbox.draw
240
 
297 mikedld 241
	sub	ebx,(6*(s_2cancel.size+2)+3)*65536
242
	mov	bx,6*(s_2cancel.size+2)
243
	push	20010 s_2cancel s_2cancel.size
244
	call	define_3d_button
245
 
258 mikedld 246
	ret
247
 
248
  .key:
249
	cmp	ebx,KEY_ESCAPE
250
	je	btn.bot.cancel
251
	cmp	ebx,KEY_RETURN
252
	je	btn.bot.opensave
253
	cmp	ebx,KEY_NUMRETURN
254
	je	btn.bot.opensave
255
	call	textbox.key
256
	ret
1624 mario79 257
;-----------------------------------------------------------------------------
297 mikedld 258
cur_part   dd ?
259
cur_color  dd ?
260
cur_colors rd 10
1624 mario79 261
;-----------------------------------------------------------------------------
297 mikedld 262
optsdlg_handler:
263
	cmp	al,1
264
	je	.draw
265
	cmp	al,2
266
	je	.key
267
	cmp	al,3
268
	je	botdlg.button
269
	cmp	al,4
270
	je	.mouse
271
	ret
272
 
273
  .xchg_colors:
274
	mov	ecx,10
275
	mov	esi,color_tbl
276
	mov	edi,cur_colors
277
    @@: lodsd
278
	xchg	eax,[edi]
279
	mov	[esi-4],eax
280
	add	edi,4
281
	loop	@b
282
	ret
283
 
284
  .draw:
285
	call	.draw_editor
286
 
287
	mov	ecx,[bot_ofs-2]
288
	mov	cx,word[bot_ofs]
289
	push	ecx
290
	add	ecx,128
291
	mcall	38,<2+3+165,2+3+165>,,[cl_3d_inset]
292
	mov	bx,word[p_info.client_box.width]
293
	pop	ecx
294
	add	ecx,35*65536+35
295
	mcall
296
	add	ecx,0x00240024
297
	mcall
298
 
299
	shr	ecx,16
300
	mov	bx,cx
301
	add	ebx,38*65536-21
302
	mcall	4,,[sc.work_text],s_tabpos,s_tabpos.size
303
 
304
	call	.draw_tabpos
305
 
306
	mov	ebx,[bot_ofs]
307
	add	ebx,(2+6+165+35)*65536+5+16
308
	mcall	4,,[sc.work_text],s_color,s_color.size
309
 
310
	mov	dword[tb_color.width],(2+6+6*s_color.size+165+35)*65536+(6*6+8)
311
	mov	eax,ebx
312
	add	ax,-3
313
	shl	eax,16
314
	mov	ax,14
315
	mov	dword[tb_color.height],eax
316
 
317
	call	.draw_color
318
 
319
	mov	ebx,[p_info.client_box.width]
320
	shl	ebx,16
321
	mov	ecx,[p_info.client_box.height]
322
	shl	ecx,16
323
	add	ecx,(-34)*65536+15
324
 
325
	add	ebx,-(2+6*(s_2save.size+2))*65536+6*(s_2save.size+2)
326
	push	20004 s_2save s_2save.size
327
	call	define_3d_button
328
	sub	ebx,(6*(s_2cancel.size+2)+3)*65536
329
	mov	bx,6*(s_2cancel.size+2)
330
	push	20001 s_2cancel s_2cancel.size
331
	call	define_3d_button
332
 
333
	ret
334
 
335
  .get_color:
336
	movzx	ecx,[tb_color.length]
337
	mov	esi,tb_color.text
338
	xor	eax,eax
339
	xor	ebx,ebx
340
	jecxz	.lp2
341
  .lp1: lodsb
342
	cmp	al,'9'
343
	mov	dl,-'0'
344
	jbe	@f
345
	mov	dl,-'A'+10
346
    @@: add	al,dl
347
	shl	ebx,4
348
	add	bl,al
349
	loop	.lp1
350
  .lp2: mov	eax,[cur_part]
351
	mov	[cur_colors+eax*4],ebx
352
	mov	[cur_color],ebx
353
	jmp	.draw_color.2
354
 
355
  .draw_editor:
987 mikedld 356
	;push    dword[options] [tab_bar.Current.Ptr]
357
	push	[tab_bar.Current.Ptr]
358
	;mov     [options],0
297 mikedld 359
	mov	ebp,optsdlg_editor
360
	call	set_cur_tab
361
 
362
	call	.xchg_colors
363
	mov	[cur_editor.Bounds.Left],2
364
	mov	[cur_editor.Bounds.Right],2+165
365
	mov	eax,[p_info.client_box.height]
366
	add	eax,-125-STATH
367
	mov	[cur_editor.Bounds.Top],eax
368
	add	eax,122
369
	mov	[cur_editor.Bounds.Bottom],eax
370
	call	draw_editor
371
	call	.xchg_colors
372
 
987 mikedld 373
	;pop     ebp eax
374
	pop	ebp
375
	;mov     [options],al
297 mikedld 376
	call	set_cur_tab
377
	ret
378
 
379
  .draw_tabpos:
380
	mov	ecx,[bot_ofs-2]
381
	xor	cx,cx
382
	mov	ebx,(2+3+165+3)*65536+31
383
	add	ecx,38*65536+31
384
	mov	edx,[cl_3d_inset]
385
	mov	esi,[sc.work]
386
	call	draw_fillrect
387
	dec	ebx
388
	dec	ecx
389
	mcall	8,,,0x40000000+21001
390
	mov	esi,[cl_3d_normal]
987 mikedld 391
	mov	al,[tabs_pos]
297 mikedld 392
 
393
TPOSH = 6
394
TPOSW = 10
395
 
396
	dec	al
397
	jnz	@f
398
	;// top
399
	inc	ebx
400
	mov	cx,TPOSH
401
	call	draw_fillrect
402
	add	ecx,2*65536-2
403
	jmp	.lp3
404
    @@: dec	al
405
	jnz	@f
406
	;// bottom
407
	inc	ebx
408
	mov	cx,TPOSH
409
	add	ecx,(31-TPOSH)*65536
410
	call	draw_fillrect
411
	add	ecx,-2
412
	jmp	.lp3
413
    @@: dec	al
414
	jnz	@f
415
	;// left
416
	inc	ecx
417
	mov	bx,TPOSW
418
	call	draw_fillrect
419
	add	ebx,2*65536-2
420
	jmp	.lp4
421
    @@: dec	al
422
	jnz	@f
423
	;// right
424
	inc	ecx
425
	mov	bx,TPOSW
426
	add	ebx,(31-TPOSW)*65536
427
	call	draw_fillrect
428
	add	ebx,-2
429
	jmp	.lp4
430
 
431
  .lp3:
432
	add	ebx,(2+TPOSW-2+1)*65536-31+TPOSW-2
433
	call	draw_fillrect
434
	add	ebx,-(TPOSW-2+1)*65536
435
	mov	esi,[sc.work]
436
	call	draw_fillrect
437
	ret
438
  .lp4:
439
	add	ecx,7*65536-31+4
440
	call	draw_fillrect
441
	add	ecx,-5*65536
442
	mov	esi,[sc.work]
443
	call	draw_fillrect
444
	ret
445
 
446
  .draw_color:
447
	mov	ecx,[cur_part]
448
	mov	edx,s_appearance+1
449
    @@: dec	ecx
450
	js	@f
451
	movzx	eax,byte[edx-1]
452
	lea	edx,[edx+eax+1]
453
	jmp	@b
454
    @@:
455
	movzx	esi,byte[edx-1]
456
	mov	ebx,[bot_ofs]
457
	add	ebx,(2+6+165+35)*65536+8
458
	push	ebx ecx edx
459
	mov	ecx,ebx
460
	shl	ecx,16
461
	mov	bx,s_appearance.maxl*6
462
	mov	cx,10
463
	mcall	13,,,[cl_3d_normal]
464
	pop	edx ecx ebx
465
	mcall	4,,[sc.work_text]
466
 
467
	mov	eax,[cur_color]
468
	mov	edi,tb_color.text
469
	mov	ebx,6
470
	mov	ecx,16
471
	call	uint2strz
472
	mov	[tb_color.length],6
473
	mov	[tb_color.sel.x],0
474
	mov	[tb_color.pos.x],6
475
 
476
	mov	ebp,tb_color
477
	call	textbox.draw
478
 
479
  .draw_color.2:
480
	mov	ecx,[p_info.client_box.height]
481
	sub	ecx,[bot_dlg_height]
482
	add	ecx,-STATH
483
	shl	ecx,16
484
	add	ecx,3*65536+31
485
	mov	ebx,(2+6+165)*65536+31
486
	mov	edx,[cl_3d_inset]
487
	mov	esi,[cur_color]
488
	call	draw_fillrect
489
 
490
	ret
491
 
492
  .key:
493
	cmp	ebx,KEY_ESCAPE
494
	je	btn.bot.cancel
495
	cmp	ebx,KEY_RETURN
496
	je	btn.bot.appearance
497
	cmp	ebx,KEY_NUMRETURN
498
	je	btn.bot.appearance
499
 
500
	cmp	ebx,KEY_BACKSPACE
501
	je	.key.tb.2
502
	cmp	ebx,KEY_TAB
503
	je	.key.tb.2
504
	cmp	bx,0x00FF
505
	ja	.key.tb.2
506
	;cmp     ebx,KEY_LSHIFT
507
	;je      .key.tb.2
508
	;cmp     ebx,KEY_RSHIFT
509
	;je      .key.tb.2
510
	;cmp     ebx,0x00000147
511
	;jb      .key.exit
512
	;cmp     ebx,0x00000153
513
	;jbe     .key.tb.2
514
 
826 mikedld 515
	test	[chr],KM_CTRLALT
297 mikedld 516
	jnz	.key.exit
826 mikedld 517
	movzx	eax,byte[chr]
297 mikedld 518
	movzx	eax,[eax+key0]
519
	or	al,al
520
	jz	.key.exit
521
	movzx	eax,[eax+key1]
522
 
523
	cmp	al,'0'
524
	jb	@f
525
	cmp	al,'9'
526
	jbe	.key.tb
527
    @@: cmp	al,'A'
528
	jb	@f
529
	cmp	al,'F'
530
	jbe	.key.tb
531
    @@: cmp	al,'a'
532
	jb	@f
533
	cmp	al,'f'
534
	jbe	.key.tb
535
    @@: ret
536
  .key.tb:
537
	cmp	[tb_color.length],6
538
	jb	@f
539
	mov	al,[tb_color.sel.x]
540
	cmp	al,[tb_color.pos.x]
541
	jne	@f
542
	ret
543
  .key.tb.2:
544
    @@: call	textbox.key
545
	call	.get_color
546
	call	.draw_editor
547
  .key.exit:
548
	ret
549
 
550
  .mouse:
551
	cmp	ah,MEV_LDOWN
552
	jne	.mouse.exit
553
	mcall	37,1
554
	movsx	ebx,ax
555
	sar	eax,16
556
	cmp	eax,[optsdlg_editor+EDITOR.Bounds.Right]
557
	jg	.mouse.exit
558
	cmp	ebx,[optsdlg_editor+EDITOR.Bounds.Bottom]
559
	jg	.mouse.exit
560
	sub	eax,[optsdlg_editor+EDITOR.Bounds.Left]
561
	js	.mouse.exit
562
	sub	ebx,[optsdlg_editor+EDITOR.Bounds.Top]
563
	js	.mouse.exit
564
	mov	esi,optsdlg_editor_parts-5
565
    @@: add	esi,5
566
	cmp	byte[esi+0],-1
567
	je	.mouse.exit
568
	cmp	al,byte[esi+1]
569
	jb	@b
570
	cmp	bl,byte[esi+2]
571
	jb	@b
572
	cmp	al,byte[esi+3]
573
	ja	@b
574
	cmp	bl,byte[esi+4]
575
	ja	@b
576
	movzx	ebp,byte[esi+0]
577
	mov	[cur_part],ebp
578
	m2m	[cur_color],[cur_colors+ebp*4]
579
	;mcall   13,<200,30>,<250,30>,[color_tbl+ebp*4]
580
	;call    .draw_color
581
	call	.draw
582
 
583
  .mouse.exit:
584
	ret
1624 mario79 585
;-----------------------------------------------------------------------------
258 mikedld 586
botdlg.button:
587
	mov	esi,accel_table2_botdlg
588
  .acc: cmp	ebx,[esi]
589
	jne	@f
590
	call	dword[esi+4]
591
	ret
592
    @@: add	esi,8
593
	cmp	byte[esi],0
594
	jne	.acc
595
	ret
1624 mario79 596
;-----------------------------------------------------------------------------
258 mikedld 597
  btn.bot.cancel:
598
	xor	eax,eax
599
	mov	[bot_mode],al
629 mikedld 600
	mov	[main_closing],al
258 mikedld 601
	mov	[bot_dlg_height],eax
602
	mov	[s_status],eax
603
	call	drawwindow
604
	ret
1624 mario79 605
;-----------------------------------------------------------------------------
258 mikedld 606
  btn.bot.opensave:
629 mikedld 607
	cmp	[bot_mode2],0
258 mikedld 608
	je	.lp1
609
	call	save_file
610
	jnc	@f
611
	jmp	.lp2
297 mikedld 612
  .lp1: call	load_file
258 mikedld 613
	jnc	@f
614
  .lp2:
615
	ret
259 mikedld 616
    @@: ;call    update_caption
258 mikedld 617
	xor	eax,eax
618
	mov	[bot_mode],al
619
	mov	[bot_dlg_height],eax
620
	call	drawwindow
621
	ret
1624 mario79 622
;-----------------------------------------------------------------------------
595 Rus 623
  btn.bot.no:
624
	xor	eax,eax
625
	mov	[bot_mode],al
626
	mov	[bot_dlg_height],eax
627
	mov	[s_status],eax
628
	call	drawwindow
629 mikedld 629
	cmp	[main_closing],0
630
	je	@f
631
	add	[exit_tab_item],sizeof.TABITEM
632
	jmp	key.alt_x.direct
595 Rus 633
	ret
629 mikedld 634
    @@: call	key.ctrl_f4.close
635
	ret
1624 mario79 636
;-----------------------------------------------------------------------------
258 mikedld 637
  btn.bot.find:
638
	movzx	ecx,[tb_find.length]
639
	mov	[s_search.size],ecx
640
	mov	esi,tb_find.text
641
	mov	edi,s_search
642
	cld
643
	rep	movsb
644
 
629 mikedld 645
	cmp	[bot_mode2],0
258 mikedld 646
	je	@f
647
	call	search
648
	jnc	.found
297 mikedld 649
	call	editor_check_for_changes
258 mikedld 650
	ret
651
 
652
  .found:
259 mikedld 653
	push	[copy_size] [copy_count] [copy_buf]
258 mikedld 654
 
655
	movzx	eax,[tb_replace.length]
259 mikedld 656
	add	eax,10
629 mikedld 657
	stdcall mem.Alloc,eax
259 mikedld 658
	mov	[copy_buf],eax
659
 
660
	movzx	eax,[tb_replace.length]
258 mikedld 661
	mov	esi,tb_replace.text
297 mikedld 662
	mov	edi,[copy_buf]
258 mikedld 663
	stosd
664
	mov	ecx,eax
665
	jecxz	.lp1
666
	rep	movsb
667
  .lp1: add	eax,4
668
	mov	[copy_size],eax
669
	mov	[copy_count],1
670
 
297 mikedld 671
	push	[cur_editor.SelStart.X]
672
	mov	ebp,cur_editor
258 mikedld 673
	call	init_sel_vars
674
	call	key.ctrl_v
297 mikedld 675
	pop	[cur_editor.SelStart.X]
258 mikedld 676
 
629 mikedld 677
	stdcall mem.Free,[copy_buf]
258 mikedld 678
 
259 mikedld 679
	pop	[copy_buf] [copy_count] [copy_size]
258 mikedld 680
 
297 mikedld 681
	call	editor_check_for_changes
258 mikedld 682
	ret
683
    @@: xor	eax,eax
684
	mov	[bot_mode],al
685
	mov	[bot_dlg_height],eax
297 mikedld 686
	call	key.f3
258 mikedld 687
	call	drawwindow
688
	ret
1624 mario79 689
;-----------------------------------------------------------------------------
297 mikedld 690
  btn.bot.appearance:
691
    @@: xor	eax,eax
692
	mov	[bot_mode],al
693
	mov	[bot_dlg_height],eax
694
	call	optsdlg_handler.xchg_colors
987 mikedld 695
	mov	al,[tabs_pos]
297 mikedld 696
	mov	[tab_bar.Style],al
987 mikedld 697
 
698
	stdcall save_settings
297 mikedld 699
	call	drawwindow
700
	ret
1624 mario79 701
;-----------------------------------------------------------------------------
297 mikedld 702
tabpos_round db 4,3,1,2
1624 mario79 703
;-----------------------------------------------------------------------------
297 mikedld 704
  btn.bot.tabpos:
987 mikedld 705
	movzx	eax,[tabs_pos]
297 mikedld 706
	mov	al,[tabpos_round+eax-1]
987 mikedld 707
	mov	[tabs_pos],al
297 mikedld 708
    @@: call	optsdlg_handler.draw_tabpos
709
	ret
1624 mario79 710
;-----------------------------------------------------------------------------