source: buchla-68k/ram/scselbx.c@ 0c834c5

Last change on this file since 0c834c5 was 0c834c5, checked in by Thomas Lopatic <thomas@…>, 4 years ago

Prototypes for global function pointers. Consistent global types.

  • Property mode set to 100644
File size: 35.2 KB
Line 
1/*
2 =============================================================================
3 scselbx.c -- MIDAS-VII -- score editor box selection functions
4 Version 87 -- 1989-11-15 -- D.N. Lynx Crowe
5 =============================================================================
6*/
7
8#include "stddefs.h"
9#include "hwdefs.h"
10#include "fields.h"
11#include "vsdd.h"
12#include "vsddvars.h"
13#include "glcfns.h"
14#include "glcdefs.h"
15#include "graphdef.h"
16#include "lcdline.h"
17#include "panel.h"
18#include "score.h"
19#include "scfns.h"
20#include "sclock.h"
21#include "slice.h"
22#include "secops.h"
23#include "secdefs.h"
24#include "macros.h"
25
26#include "midas.h"
27#include "asgdsp.h"
28#include "scdsp.h"
29
30/* functions defined elsewhere */
31
32extern void enterit(void);
33extern void advscur(void);
34extern short oktode(struct s_entry *ep);
35extern short nokey(void);
36
37/*
38
39*/
40
41/* variables defined elsewhere */
42
43extern void (*itxput)(short row, short col, char *txt, short tag);
44extern void (*point)(short x, short y, short pen);
45
46extern short ancmsw;
47extern short angroup;
48extern short asmode;
49extern short clkrun;
50extern short clkctl;
51extern short clksrc;
52extern short ctrsw;
53extern short cxval;
54extern short cyval;
55extern short dubsw;
56extern short gomode;
57extern short grptran;
58extern short gtmsel;
59extern short hitbox;
60extern short hitcx;
61extern short hitcy;
62extern short insmode;
63extern short ismode;
64extern short lastam;
65extern short midiclk;
66extern short noteop;
67extern short notesel;
68extern short oldpk;
69extern short oldsl;
70extern short pchsw;
71extern short pkctrl;
72extern short pulsclk;
73extern short recsw;
74extern short scmctl;
75extern short sdmcol;
76extern short sdmctl;
77extern short sdmrow;
78extern short secop;
79extern short sgoflag;
80extern short sliders;
81extern short stccol;
82extern short stcrow;
83extern short stepclk;
84extern short stepenb;
85extern short submenu;
86extern short velflag;
87extern short vtccol;
88extern short vtcrow;
89
90/*
91
92*/
93
94extern short grptmap[];
95
96extern short sctctab[][64];
97
98extern struct asgent asgtab[];
99
100extern struct selbox *csbp;
101extern struct selbox *curboxp;
102
103extern struct s_time stimes[N_SCORES][N_SECTS]; /* section times */
104
105extern unsigned *obj8, *obj11;
106
107extern PFS (*swpt)[];
108extern PFS (*oldsw)[];
109extern PFS t_ngrp[];
110
111extern char bfs[];
112extern char tunname[][32];
113
114extern struct gdsel *gdstbc[];
115
116/* forward references */
117
118void sdboxfn(short n);
119void bspscur(void);
120void svtdsp(unsigned *obj, unsigned fg, unsigned bg, short row, short col, char *buf);
121void svtstop(void);
122
123/*
124
125*/
126
127char *sdmenus[][3] = { /* score display menus */
128
129 /* 0 - typewriter */
130
131 {" ABCDEFGHIJKLMNOPQRSTUVWXYZ | ",
132 " abcdefghijklmnopqrstuvwxyz -*- ",
133 " 0123456789+-/*().,:;!?&<> | "},
134
135 /* 1 - note edit */
136
137 {" Begin Acc Move Note Escape ",
138 " Begin Nat Move Begin ",
139 " End Note Move End "},
140
141 /* 2 - clock source */
142
143 {" Local PLS24 Step ",
144 " MIDI PLS48 ",
145 " SMPTE PLS96 "},
146
147 /* 3 - clock control */
148
149 {" Local ",
150 " MIDI ",
151 " SMPTE "},
152
153 /* 4 - Section menu */
154
155 {" GoTo Move SMPTE ",
156 " Begin Copy Del Gr ",
157 " End Merge Del Ev "}
158};
159
160char sdmln3[] =
161 " ReGrp Remove Trn S ";
162
163char sdmln4[] =
164 "Escape D ";
165
166/*
167
168*/
169
170short sdmht[][3] = { /* score section menu highlight table */
171
172 /* row, lcol, rcol */
173
174 { 6, 0, 0}, /* 0 - SOP_NUL */
175 { 3, 1, 4}, /* 1 - SOP_GO */
176 { 4, 1, 5}, /* 2 - SOP_BGN */
177 { 5, 1, 3}, /* 3 - SOP_END */
178 { 3, 8, 11}, /* 4 - SOP_MOV */
179 { 4, 8, 11}, /* 5 - SOP_CPY */
180 { 5, 8, 12}, /* 6 - SOP_MRG */
181 { 3, 15, 19}, /* 7 - SOP_STC */
182 { 4, 15, 23}, /* 8 - SOP_DGR */
183 { 5, 15, 23}, /* 9 - SOP_DEV */
184 { 6, 15, 20}, /* 10 - SOP_RMV */
185 { 6, 8, 12} /* 11 - SOP_GRP */
186};
187
188short sdmlim[][4] = { /* score display menu cursor limits */
189
190 /* top, left, bottom, right */
191
192 { 19, 1, 21, 30 }, /* 0 - typewriter */
193 { 19, 1, 21, 30 }, /* 1 - note edit */
194 { 19, 1, 21, 20 }, /* 2 - clock source */
195 { 19, 1, 21, 19 }, /* 3 - clock control */
196 { 19, 1, 23, 62 } /* 4 - section menu */
197};
198
199/*
200
201*/
202
203char *nedlbl[] = { /* note edit function labels */
204
205 "Note Edit", /* 0 - NOP_NUL */
206 "Begin Acc", /* 1 - NOP_ACC */
207 "Begin Nat", /* 2 - NOP_NAT */
208 "End Note ", /* 3 - NOP_END */
209 "Move Note", /* 4 - NOP_MVN */
210 "Move Beg ", /* 5 - NOP_MVB */
211 "Move End " /* 6 - NOP_MVE */
212};
213
214/*
215
216*/
217
218struct selbox sdboxes[] = {
219
220 { 0, 0, 175, 13, 0, sdboxfn}, /* 0 - Sec, Beat, Frame */
221 {176, 0, 231, 13, 1, sdboxfn}, /* 1 - Insert */
222 {232, 0, 439, 13, 2, sdboxfn}, /* 2 - Clock */
223 {440, 0, 511, 13, 3, sdboxfn}, /* 3 - Note Edit */
224
225 { 0, 238, 111, 251, 4, sdboxfn}, /* 4 - Assignment */
226 {112, 238, 167, 251, 5, sdboxfn}, /* 5 - Tune */
227 {168, 238, 247, 251, 6, enterit}, /* 6 - Tempo */
228 {248, 238, 319, 251, 7, enterit}, /* 7 - Interpolate */
229 {320, 238, 398, 251, 8, sdboxfn}, /* 8 - Stop/Next */
230 {400, 238, 455, 251, 9, sdboxfn}, /* 9 - In/Out */
231 {456, 238, 511, 251, 10, sdboxfn}, /* 10 - Output */
232
233 { 0, 252, 511, 307, 11, sdboxfn}, /* 11 - Grp, Trns, Dyn, Vel */
234
235 { 0, 308, 511, 335, 12, sdboxfn}, /* 12 - Ansrc, Anval */
236
237 { 0, 336, 215, 349, 13, sdboxfn}, /* 13 - Score Title */
238 {216, 336, 455, 349, 14, sdboxfn}, /* 14 - Rec Mode */
239 {456, 336, 511, 349, 15, sdboxfn}, /* 15 - Memory */
240
241 { 0, 14, 511, 237, 16, sdboxfn}, /* 16 - Note Display */
242
243 { 0, 0, 0, 0, 0, FN_NULL} /* end of table */
244};
245
246/*
247
248*/
249
250/*
251 =============================================================================
252 insect() -- return section number pointed to in section menu, or -1
253 =============================================================================
254*/
255
256short insect(void)
257{
258 register short col;
259
260 col = vtccol - 24;
261
262 if (col < 0)
263 return(-1);
264
265 sgoflag = col & 3;
266
267 if ((vtcrow < 19) OR (vtcrow > 20))
268 return(-1);
269
270 return((col >> 2) + (10 * (vtcrow - 19)));
271}
272
273/*
274 =============================================================================
275 svtdsp() -- display data for the virtual typewriter
276 =============================================================================
277*/
278
279void svtdsp(unsigned *obj, unsigned fg, unsigned bg, short row, short col, char *buf)
280{
281 if (v_regs[5] & 0x0180)
282 vbank(0);
283
284 vputs(obj, row - 16, col, buf, SDW13ATR);
285}
286
287/*
288
289*/
290
291/*
292 =============================================================================
293 svtstop() -- end vitrual typewriter data entry
294 =============================================================================
295*/
296
297void svtstop(void)
298{
299 sdmenu(-1);
300}
301
302/*
303 =============================================================================
304 bspscur() -- backspace the score display text cursor
305 =============================================================================
306*/
307
308void bspscur(void)
309{
310 register short newcol;
311
312 if (infield(stcrow, stccol, curfet))
313 cfetp = infetp;
314 else
315 return;
316
317 newcol = stccol - 1;
318
319 if (newcol GE cfetp->flcol)
320 stcpos(stcrow, newcol);
321
322 cxval = CTOX(stccol);
323 cyval = RTOY(stcrow);
324}
325
326/*
327
328*/
329
330/*
331 =============================================================================
332 dsects() -- display list of section numbers
333 Highlight active sections and indicate SMPTE time-coded sections.
334 =============================================================================
335*/
336
337void dsects(void)
338{
339 register short atr, row, col, i, j;
340 char buf[8];
341 char cl, cr, csl, csr;
342 short begun;
343
344 register struct s_entry *sp;
345
346 if (v_regs[5] & 0x0180)
347 vbank(0);
348
349 row = 3;
350
351 for (i = 0; i < N_SECTS; i += 10) {
352
353 col = 24;
354
355 for (j = 0; j < 10; j++) {
356
357 if (stimes[curscor][i + j].sflags) { /* SMPTE time */
358
359 csl = '[';
360 csr = ']';
361
362 } else { /* no SMPTE time */
363
364 csl = '{';
365 csr = '}';
366 }
367
368 cl = ' ';
369 cr = ' ';
370
371 if (E_NULL NE seclist[curscor][i + j]) {
372
373 begun = TRUE;
374 atr = (SDBGMM | (SD_CHNG << 4));
375 cl = csl;
376
377 } else {
378
379 begun = FALSE;
380 atr = SDMENUBG;
381 }
382
383 sp = hplist[curscor][EH_SEND];
384
385 while (sp) {
386
387 if (sp->e_data1 EQ (i + j)) {
388
389 cr = begun ? csr : '}';
390 break;
391 }
392
393 sp = sp->e_up;
394 }
395
396 sprintf(buf, "%c%02d%c", cl, 1 + (i + j), cr);
397
398 vputs(obj8, row, col, buf, atr);
399 col += 4;
400 }
401
402 ++row;
403 }
404}
405
406/*
407
408*/
409
410/*
411 =============================================================================
412 dsgtmn() -- display group map source group number
413 =============================================================================
414*/
415
416void dsgtmn(short n, short f)
417{
418 char buf[4];
419 short atr, col;
420
421 sprintf(buf, "%02d", n + 1);
422
423 col = (3 * n) + 28;
424 atr = f ? (SDBGMM | (SD_CHNG <<4)) : SDMENUBG;
425
426 if (v_regs[5] & 0x0180)
427 vbank(0);
428
429 vputs(obj8, 6, col, buf, atr);
430}
431
432/*
433 =============================================================================
434 dsgtme() -- display group map destination group number
435 =============================================================================
436*/
437
438void dsgtme(short n)
439{
440 char buf[4];
441 short col;
442
443 if (grptmap[n] EQ -1)
444 strcpy(buf, " ");
445 else
446 sprintf(buf, "%02d", grptmap[n] + 1);
447
448 col = (3 * n) + 28;
449
450 if (v_regs[5] & 0x0180)
451 vbank(0);
452
453 vputs(obj8, 7, col, buf, SDMENUBG);
454}
455
456/*
457
458*/
459
460/*
461 =============================================================================
462 dsgtmap() -- display group map and transposition value
463 =============================================================================
464*/
465
466void dsgtmap(void)
467{
468 char buf[6];
469 register short i;
470
471 if (v_regs[5] & 0x0180)
472 vbank(0);
473
474 sprintf(buf, "%c%02d", grptran < 0 ? '-' : '+', abs(grptran));
475
476 vputs(obj8, 7, 22, buf, SDMENUBG);
477
478 for (i = 0; i < 12; i++) {
479
480 dsgtmn(i, gtmsel EQ i);
481 dsgtme(i);
482 }
483}
484
485/*
486 =============================================================================
487 ingroup() -- return group number selected
488 =============================================================================
489*/
490
491short ingroup(void)
492{
493 register short col;
494
495 col = vtccol - 28;
496
497 if (col < 0)
498 return(-1);
499
500 if (2 EQ (col % 3))
501 return(-1);
502
503 return(col / 3);
504}
505
506/*
507
508*/
509
510/*
511 =============================================================================
512 sdmtxt() -- output text to the score area submenu
513 =============================================================================
514*/
515
516void sdmtxt(short row, short col, char *txt, short tag)
517{
518 if ((v_regs[5] & 0x0180) NE 0x0100)
519 vbank(1);
520
521 vcputsv(obj11, 64, SD_TEXT, SDBG16, row, col, txt, 14);
522}
523
524/*
525
526*/
527
528/*
529 =============================================================================
530 showam() -- show menu of assignments
531 =============================================================================
532*/
533
534void showam(short asg)
535{
536 register short col, na, row;
537
538 if (asg EQ 1)
539 na = 48;
540 else
541 na = NASGS;
542
543 for (col = 2; col < 60; col += 15) {
544
545 if (asg GE na)
546 return;
547
548 (*itxput)(0, col, "No Assignment", 0);
549
550 for (row = 1; row < 15; row++) {
551
552 if (asg GE na)
553 return;
554
555 sprintf(bfs, "%02d %-10.10s", asg, asgtab[asg].a_name);
556 (*itxput)(row, col, bfs, 1);
557 ++asg;
558 }
559 }
560}
561
562/*
563
564*/
565
566/*
567 =============================================================================
568 showtm() -- show menu of tunings
569 =============================================================================
570*/
571
572void showtm(void)
573{
574 register short row, tun;
575
576 tun = 0;
577
578 (*itxput)(0, 0, "N Name", 0);
579
580 for (row = 1; row < 11; row++) {
581
582 sprintf(bfs, "%d %-32.32s", tun, tunname[tun]);
583 (*itxput)(row, 0, bfs, 1);
584 ++tun;
585 }
586}
587
588/*
589
590*/
591
592/*
593 =============================================================================
594 showsm() -- show menu of scores
595 =============================================================================
596*/
597
598void showsm(void)
599{
600 register short col, row, scr;
601
602 scr = 1;
603
604 for (col = 1; col < 46; col+= 22) {
605
606 if (scr > N_SCORES)
607 return;
608
609 (*itxput)(0, col, "No Score", 0);
610
611 for (row = 1; row < 15; row++) {
612
613 if (scr > N_SCORES)
614 return;
615
616 sprintf(bfs, "%02d %-16.16s", scr, scname[scr - 1]);
617 (*itxput)(row, col, bfs, 1);
618 ++scr;
619 }
620 }
621}
622
623/*
624
625*/
626
627/*
628 =============================================================================
629 scmenu() -- display a submenu in area 1 (score area)
630 =============================================================================
631*/
632
633void scmenu(short n)
634{
635 register short i;
636 register struct octent *op;
637
638 if (n GE 0) { /* put up a submenu */
639
640 itxput = sdmtxt; /* setup output function */
641
642 vbank(0);
643
644 v_odtab[0][0] |= V_BLA; /* turn off line objcect */
645 objclr(0);
646
647 v_odtab[1][0] |= V_BLA; /* turn off score object */
648 objclr(1);
649
650 v_odtab[2][0] |= V_BLA; /* turn off keyboard object */
651 objclr(2);
652
653 vbank(1); /* clear the window */
654 vbfill4(obj11, 128, 0, 0, 511, 223, exp_c(SDBG16));
655
656 vbank(0); /* turn on window object */
657 SetPri(11, 4);
658
659 switch (n) { /* fill the window */
660
661 case 0: /* instruments */
662
663 showim(); /* show the instruments */
664 break;
665
666 case 1: /* assignments */
667
668 showam(lastam); /* show the assignments */
669 stcpos(17, 11); /* position the cursor */
670
671 cxval = CTOX(11);
672 cyval = RTOY(17);
673
674 if (infield(stcrow, stccol, curfet))
675 cfetp = infetp;
676
677 break;
678
679 case 2: /* tunings */
680
681 showtm(); /* show the tunings */
682 stcpos(17, 19); /* position the cursor */
683
684 cxval = CTOX(19);
685 cyval = RTOY(17);
686
687 if (infield(stcrow, stccol, curfet))
688 cfetp = infetp;
689
690 break;
691
692 case 3: /* scores */
693
694 showsm(); /* show the scores */
695 stcpos(24, 7); /* position the cursor */
696
697 cxval = CTOX(7);
698 cyval = RTOY(24);
699
700 if (infield(stcrow, stccol, curfet))
701 cfetp = infetp;
702
703 break;
704
705 default: /* eh ? */
706
707 break;
708 }
709
710 } else { /* take down the submenu */
711
712 vbank(0);
713
714 v_odtab[4][0] |= V_BLA; /* turn off window object */
715 objclr(4);
716
717 op = &v_obtab[13]; /* turn on keyboard object */
718 objon(2, op->objy, op->ysize);
719 v_odtab[2][0] &= ~V_BLA;
720
721 op = &v_obtab[14]; /* turn on score object */
722 objon(1, op->objy, op->ysize);
723 v_odtab[1][0] &= ~V_BLA;
724
725 op = &v_obtab[15]; /* turn on line object */
726 objon(0, op->objy, op->ysize);
727 v_odtab[0][0] &= ~V_BLA;
728 }
729
730 scmctl = n; /* set new menu type */
731}
732/*
733
734*/
735
736/*
737 =============================================================================
738 sdmenu() -- display a submenu in area 2 (text areas)
739 =============================================================================
740*/
741
742void sdmenu(short n)
743{
744 register short i, wasup;
745
746 wasup = sdmctl; /* save previous menu type */
747 sdmctl = n; /* set new menu type */
748
749 if (n GE 0) { /* put up a menu */
750
751 submenu = TRUE; /* indicate there's a menu up */
752
753 sdmrow = stcrow; /* save underline cursor position */
754 sdmcol = stccol; /* ... */
755
756 memsetw(&sctctab[3][0], exp_c(SDBGMM), 64); /* recolor */
757 memsetw(&sctctab[4][0], exp_c(SDBGMM), 64);
758 memsetw(&sctctab[5][0], exp_c(SDBGMM), 64);
759
760 if (n EQ 4) { /* extra 2 lines for section menu */
761
762 memsetw(&sctctab[6][0], exp_c(SDBGMM), 64);
763 memsetw(&sctctab[7][0], exp_c(SDBGMM), 64);
764 }
765
766 stcclr(); /* re-color the cursor background */
767 stcpos(sdmrow, sdmcol); /* turn underline cursor back on */
768
769 if (infield(stcrow, stccol, curfet))
770 cfetp = infetp;
771
772 if (v_regs[5] & 0x0180)
773 vbank(0);
774
775 for (i = 0; i < 3; i++) /* top 3 lines of menu */
776 vputs(obj8, 3 + i, 0, sdmenus[n][i], SDMENUBG);
777/*
778
779*/
780 if (n EQ 4) { /* extra 2 lines for section menu */
781
782 vputs(obj8, 6, 0, sdmln3, SDMENUBG);
783 vputs(obj8, 7, 0, sdmln4, SDMENUBG);
784
785 secop = SOP_NUL; /* clear section operation code */
786
787 grptran = 0; /* reset transpose value */
788 gtmsel = -1; /* de-select source group */
789
790 for (i = 0; i < 12; i++) /* reset the map */
791 grptmap[i] = i;
792
793 dsects(); /* display list of sections */
794 dsgtmap(); /* display group map and transpose */
795
796 point = GLCplot; /* setup to plot on LCD */
797 GLCcurs(G_ON);
798
799 if (ismode NE IS_NULL) { /* cancel inst. mode */
800
801 ismode = IS_NULL;
802 pkctrl = oldpk;
803 sliders = oldsl;
804 swpt = oldsw;
805 lcdlbls();
806 }
807
808 if (gomode NE GO_NULL) { /* cancel goto mode */
809
810 gomode = GO_NULL;
811 pkctrl = oldpk;
812 lseg(GOTO_XL, GOTO_Y, GOTO_XR, GOTO_Y, 0);
813 }
814
815 if (asmode) { /* cancel assign mode */
816
817 asmode = 0;
818 pkctrl = oldpk;
819 swpt = oldsw;
820 lseg(ASGN_XL, ASGN_Y, ASGN_XR, ASGN_Y, 0);
821 }
822
823 if ((pkctrl EQ PK_PFRM) OR (pkctrl EQ PK_NOTE))
824 oldpk = pkctrl;
825
826 if (sliders NE LS_LIBR)
827 oldsl = sliders;
828
829 oldsw = swpt; /* put panel in group mode */
830 swpt = t_ngrp;
831 pkctrl = PK_NGRP;
832 sliders = LS_NGRP;
833
834 lcdlbls();
835 setleds();
836 }
837
838 SetPri(TTCURS, TTCPRI); /* turn on menu cursor */
839 ttcpos(sdmlim[n][0], sdmlim[n][1]); /* position menu cursor */
840/*
841
842*/
843 } else { /* take down the menu */
844
845 submenu = FALSE; /* indicate menu has gone bye bye */
846
847 if (v_regs[5] & 0x0180)
848 vbank(0);
849
850 objclr(TTCPRI); /* turn off the menu cursor */
851 stcset(); /* restore underline cursor */
852 stcclr(); /* ... */
853 sdwin(11); /* redisplay window 11 data */
854
855 if (wasup EQ 4) {
856
857 sdwin(12); /* redisplay window 12 data */
858
859 stcpos(sdmrow, sdmcol); /* display underline cursor */
860
861 cxval = CTOX(sdmcol);
862 cyval = RTOY(sdmrow);
863
864 if (infield(stcrow, stccol, curfet))
865 cfetp = infetp;
866
867 pkctrl = oldpk; /* restore panel state */
868 sliders = oldsl;
869 swpt = oldsw;
870
871 lcdlbls(); /* refresh LCD */
872 setleds(); /* refresh LEDs */
873
874 } else {
875
876 stcpos(sdmrow, sdmcol); /* display underline cursor */
877
878 cxval = CTOX(sdmcol);
879 cyval = RTOY(sdmrow);
880
881 if (infield(stcrow, stccol, curfet))
882 cfetp = infetp;
883 }
884 }
885}
886
887/*
888
889*/
890
891/*
892 =============================================================================
893 hilitnt() -- setup for a note operation
894 =============================================================================
895*/
896
897void hilitnt(short nop)
898{
899 noteop = nop; /* set note operation */
900 notesel = FALSE; /* indicate no note selected */
901 sdmenu(-1); /* take down the menu */
902 dnedmod(); /* update the note edit window */
903}
904
905/*
906
907*/
908
909/*
910 =============================================================================
911 hilitop() -- highlight a section operation and set secop
912 =============================================================================
913*/
914
915void hilitop(short n)
916{
917 register short row, lc, rc, col;
918
919 if (clkrun) /* don't do anything if clock is running */
920 return;
921
922 if (v_regs[5] & 0x0180)
923 vbank(0);
924
925 if (secop NE SOP_NUL) {
926
927 row = sdmht[secop][0];
928 lc = sdmht[secop][1];
929 rc = sdmht[secop][2];
930
931 for (col = lc; col LE rc; col++)
932 vputa(obj8, row, col, SDMENUBG);
933 }
934
935 secop = n;
936
937 row = sdmht[n][0];
938 lc = sdmht[n][1];
939 rc = sdmht[n][2];
940
941 for (col = lc; col LE rc; col++)
942 vputa(obj8, row, col, (SDBGMM | (SD_ENTR << 4)));
943}
944
945/*
946
947*/
948
949/*
950 =============================================================================
951 dosecop() -- do the current section operation
952 =============================================================================
953*/
954
955void dosecop(void)
956{
957 register short sect;
958 register struct s_entry *ep;
959
960 if (clkrun OR (-1 EQ (sect = insect()))) {
961
962 secop = SOP_NUL;
963 return;
964 }
965
966 if (insmode) {
967
968 icancel();
969 dsimode();
970 }
971
972 switch (secop) {
973
974 case SOP_GO: /* GoTo */
975
976 if (sgoflag EQ 3) { /* GoTo End Section */
977
978 ep = hplist[curscor][EH_SEND];
979
980 while (ep) {
981
982 if (ep->e_data1 EQ sect) {
983
984 sc_goto(fc_val = ep->e_time);
985 break;
986 }
987
988 ep = ep->e_up;
989 }
990
991 } else { /* GoTo Begin Section */
992
993 if (E_NULL NE (ep = seclist[curscor][sect]))
994 sc_goto(fc_val = ep->e_time);
995 }
996
997 break;
998/*
999
1000*/
1001 case SOP_BGN: /* Begin */
1002
1003 if (NOT recsw) /* only in record mode */
1004 break;
1005
1006 if (v_regs[5] & 0x0180)
1007 vbank(0);
1008
1009 if (E_NULL NE (ep = seclist[curscor][sect])) {
1010
1011 eh_rmv(ep, EH_SBGN);
1012 e_rmv(ep);
1013 ep->e_time = t_cur;
1014 p_cur = e_ins(ep, ep_adj(p_cur, 1, t_cur)->e_bak)->e_fwd;
1015 eh_ins(ep, EH_SBGN);
1016 se_exec(ep, D_FWD);
1017
1018 } else if (E_NULL NE (ep = e_alc(E_SIZE2))) {
1019
1020 ep->e_time = t_cur;
1021 ep->e_type = EV_SBGN;
1022 ep->e_data1 = sect;
1023 p_cur = e_ins(ep, ep_adj(p_cur, 1, t_cur)->e_bak)->e_fwd;
1024 eh_ins(ep, EH_SBGN);
1025 seclist[curscor][sect] = ep;
1026 se_exec(ep, D_FWD);
1027 }
1028
1029 sc_refr(fc_val); /* refresh the screen */
1030 break;
1031/*
1032
1033*/
1034 case SOP_END: /* End */
1035
1036 if (NOT recsw) /* only in record mode */
1037 break;
1038
1039 if (v_regs[5] & 0x0180)
1040 vbank(0);
1041
1042 if (E_NULL NE (ep = ehfind(EH_SEND, -1L, sect, -1))) {
1043
1044 eh_rmv(ep, EH_SEND);
1045 e_rmv(ep);
1046 ep->e_time = t_cur;
1047 p_cur = e_ins(ep, ep_adj(p_cur, 0, t_cur))->e_fwd;
1048 eh_ins(ep, EH_SEND);
1049 se_exec(ep, D_FWD);
1050
1051 } else if (E_NULL NE (ep = e_alc(E_SIZE2))) {
1052
1053 ep->e_time = t_cur;
1054 ep->e_type = EV_SEND;
1055 ep->e_data1 = sect;
1056 p_cur = e_ins(ep, ep_adj(p_cur, 0, t_cur))->e_fwd;
1057 eh_ins(ep, EH_SEND);
1058 se_exec(ep, D_FWD);
1059 }
1060
1061 sc_refr(fc_val); /* refresh the screen */
1062 break;
1063/*
1064
1065*/
1066 case SOP_MOV: /* Move */
1067
1068 if (NOT recsw) /* only in record mode */
1069 break;
1070
1071 if (sec_mov(sect)) /* move the section */
1072 break;
1073
1074 sc_refr(fc_val); /* refresh screen if successful */
1075 break;
1076
1077 case SOP_CPY: /* Copy */
1078
1079 if (NOT recsw) /* only in record mode */
1080 break;
1081
1082 if (sec_cpy(sect)) /* copy the section */
1083 break;
1084
1085 sc_refr(fc_val); /* refresh screen if successful */
1086 break;
1087
1088 case SOP_MRG: /* Merge */
1089
1090 if (NOT recsw) /* only in record mode */
1091 break;
1092
1093 if (sec_mrg(sect)) /* merge the section */
1094 break;
1095
1096 sc_refr(fc_val); /* refresh screen if successful */
1097 break;
1098
1099 case SOP_GRP: /* ReGrp */
1100
1101 if (NOT recsw) /* only in record mode */
1102 break;
1103
1104 if (sec_grp(sect)) /* regroup the section */
1105 break;
1106
1107 sc_refr(fc_val); /* refresh screen if successful */
1108 break;
1109
1110/*
1111
1112*/
1113 case SOP_STC: /* SMPTE */
1114
1115 if (NOT recsw) /* only in record mode */
1116 break;
1117
1118 break;
1119
1120 case SOP_DGR: /* Delete Gr */
1121
1122 if (NOT recsw) /* only in record mode */
1123 break;
1124
1125 if (sec_dgr(sect)) /* delete note events */
1126 break;
1127
1128 sc_refr(fc_val); /* refresh display if successful */
1129 break;
1130
1131 case SOP_DEV: /* Delete Ev */
1132
1133 if (NOT recsw) /* only in record mode */
1134 break;
1135
1136 if (sec_dev(sect)) /* delete non-note events */
1137 break;
1138
1139 sc_refr(fc_val); /* refresh display if successful */
1140 break;
1141
1142 case SOP_RMV: /* Remove */
1143
1144 if (NOT recsw) /* only in record mode */
1145 break;
1146
1147 if (sec_rmv(sect)) /* remove section */
1148 break;
1149
1150 sc_refr(fc_val); /* refresh display if successful */
1151 break;
1152 }
1153
1154 secop = SOP_NUL;
1155}
1156
1157/*
1158
1159*/
1160
1161/*
1162 =============================================================================
1163 clkset() -- set the clock state
1164 =============================================================================
1165*/
1166
1167void clkset(short st)
1168{
1169 clkrun = st;
1170
1171 switch (clksrc) {
1172
1173 case CK_LOCAL: /* Local */
1174 case CK_SMPTE: /* SMPTE */
1175
1176 midiclk = FALSE;
1177 pulsclk = FALSE;
1178
1179 if (st)
1180 fc_sw = 1;
1181 else
1182 fc_sw = 0;
1183
1184 return;
1185
1186 case CK_MIDI: /* MIDI */
1187
1188 fc_sw = 0;
1189 pulsclk = FALSE;
1190
1191 if (st)
1192 midiclk = TRUE;
1193 else
1194 midiclk = FALSE;
1195
1196 return;
1197/*
1198
1199*/
1200 case CK_PLS24: /* PLS24 */
1201 case CK_PLS48: /* PLS48 */
1202 case CK_PLS96: /* PLS96 */
1203
1204 fc_sw = 0;
1205 midiclk = FALSE;
1206
1207 if (st)
1208 pulsclk = TRUE;
1209 else
1210 pulsclk = FALSE;
1211
1212 return;
1213
1214 case CK_STEP: /* Step */
1215
1216 fc_sw = 0;
1217 midiclk = FALSE;
1218 pulsclk = FALSE;
1219
1220 return;
1221 }
1222}
1223
1224/*
1225
1226*/
1227
1228/*
1229 =============================================================================
1230 sdboxfn() -- process score display box hits
1231 =============================================================================
1232*/
1233
1234void sdboxfn(short n)
1235{
1236 register short row, col, grp, what, i;
1237 register struct s_entry *ep;
1238 short atr, modewas;
1239
1240 row = hitcy / 14;
1241 col = hitcx >> 3;
1242
1243 switch (hitbox) {
1244
1245 case 0: /* signature, section, beat, frame */
1246
1247 if (col EQ 0) { /* signature */
1248
1249 if (clkrun) /* clock can't be running */
1250 return;
1251
1252 if (ac_code EQ N_SHARP)
1253 ac_code = N_FLAT;
1254 else
1255 ac_code = N_SHARP;
1256
1257 sc_refr(fc_val);
1258 return;
1259
1260 } else if ((col GE 2) AND (col LE 4)) { /* section menu */
1261
1262 if (clkrun) /* clock can't be running */
1263 return;
1264
1265 if (sdmctl EQ -1) { /* menu not up yet */
1266
1267 sdmenu(4); /* put up the menu */
1268 return;
1269/*
1270
1271*/
1272 } else { /* menu up */
1273
1274 if (vtcrow EQ 19) {
1275
1276 if ((vtccol GE 1) AND
1277 (vtccol LE 4)) { /* GoTo */
1278
1279 hilitop(SOP_GO);
1280 return;
1281
1282 } else if ((vtccol GE 8) AND
1283 (vtccol LE 11)) { /* Move */
1284
1285 hilitop(SOP_MOV);
1286 return;
1287
1288 } else if ((vtccol GE 15) AND
1289 (vtccol LE 19)) { /* SMPTE */
1290
1291 hilitop(SOP_STC);
1292 return;
1293
1294 } else if ((vtccol GE 24) AND
1295 (vtccol LE 62)) { /* number */
1296
1297 if (-1 NE insect()) {
1298
1299 sdmenu(-1);
1300 dosecop();
1301 }
1302
1303 return;
1304 }
1305/*
1306
1307*/
1308 } else if (vtcrow EQ 20) {
1309
1310 if ((vtccol GE 1) AND
1311 (vtccol LE 5)) { /* Begin */
1312
1313 hilitop(SOP_BGN);
1314 return;
1315
1316 } else if ((vtccol GE 8) AND
1317 (vtccol LE 11)) { /* Copy */
1318
1319 hilitop(SOP_CPY);
1320 return;
1321
1322 } else if ((vtccol GE 15) AND
1323 (vtccol LE 20)) { /* Del Gr */
1324
1325 hilitop(SOP_DGR);
1326 return;
1327
1328 } else if ((vtccol GE 24) AND
1329 (vtccol LE 62)) { /* number */
1330
1331 if (-1 NE insect()) {
1332
1333 sdmenu(-1);
1334 dosecop();
1335 }
1336
1337 return;
1338 }
1339/*
1340
1341*/
1342 } else if (vtcrow EQ 21) {
1343
1344 if ((vtccol GE 1) AND
1345 (vtccol LE 3)) { /* End */
1346
1347 hilitop(SOP_END);
1348 return;
1349
1350 } else if ((vtccol GE 8) AND
1351 (vtccol LE 12)) { /* Merge */
1352
1353 hilitop(SOP_MRG);
1354 return;
1355
1356 } else if ((vtccol GE 15) AND
1357 (vtccol LE 20)) { /* Del Ev */
1358
1359 hilitop(SOP_DEV);
1360 return;
1361 }
1362
1363/*
1364
1365*/
1366 } else if (vtcrow EQ 22) {
1367
1368 if ((vtccol GE 8) AND
1369 (vtccol LE 12)) { /* ReGrp */
1370
1371 hilitop(SOP_GRP);
1372 return;
1373
1374 } else if ((vtccol GE 15) AND
1375 (vtccol LE 20)) { /* Remove */
1376
1377 hilitop(SOP_RMV);
1378 return;
1379
1380 } else if ((vtccol GE 28) AND
1381 (vtccol LE 62)) { /* number */
1382
1383 if (gtmsel GE 0)
1384 dsgtmn(gtmsel, FALSE);
1385
1386 if (-1 NE (gtmsel = ingroup()))
1387 dsgtmn(gtmsel, TRUE);
1388
1389 return;
1390 }
1391
1392 } else if (vtcrow EQ 23) {
1393
1394 if ((vtccol GE 1) AND
1395 (vtccol LE 6)) { /* Escape */
1396
1397 secop = SOP_NUL;
1398 sdmenu(-1);
1399 return;
1400
1401 } else if ((vtccol GE 22) AND
1402 (vtccol LE 24)) { /* Transpose */
1403
1404 enterit();
1405 return;
1406 }
1407 }
1408 }
1409
1410 return;
1411
1412 } else {
1413 enterit();
1414 return;
1415 }
1416
1417/*
1418
1419*/
1420 case 1: /* insert */
1421
1422 modewas = insmode; /* save old insert state */
1423
1424 if (insmode) /* toggle ... */
1425 icancel(); /* ... insert on -> off */
1426 else
1427 istart(); /* ... insert of -> on */
1428
1429 if (modewas NE insmode) /* only refresh if changed */
1430 sc_refr(fc_val);
1431
1432 dsimode(); /* update insert mode display */
1433 return;
1434
1435 case 2: /* clock control, source */
1436
1437 if (col LE 33) { /* clock */
1438
1439 clkset(NOT clkrun);
1440 dsclk();
1441 return;
1442
1443/*
1444
1445*/
1446 } else if ((col GE 35) AND (col LE 43)) { /* control */
1447
1448 if (sdmctl EQ -1) { /* menu not yet up */
1449
1450 sdmenu(3);
1451 return;
1452
1453 } else { /* menu up */
1454
1455 if (vtcrow EQ 19) {
1456
1457 if ((vtccol GE 1) AND
1458 (vtccol LE 5)) {
1459
1460 clkctl = CK_LOCAL;
1461 sdmenu(-1);
1462 sdwin(2);
1463 return;
1464 }
1465
1466 } else if (vtcrow EQ 20) {
1467
1468 if ((vtccol GE 1) AND
1469 (vtccol LE 5)) {
1470
1471 clkctl = CK_MIDI;
1472 sdmenu(-1);
1473 sdwin(2);
1474 return;
1475 }
1476
1477 } else if (vtcrow EQ 21) {
1478
1479 if ((vtccol GE 1) AND
1480 (vtccol LE 5)) {
1481
1482 clkctl = CK_SMPTE;
1483 sdmenu(-1);
1484 sdwin(2);
1485 return;
1486 }
1487 }
1488 }
1489
1490 return;
1491/*
1492
1493*/
1494 } else if (col GE 45) { /* source */
1495
1496 if (sdmctl EQ -1) { /* menu not yet up */
1497
1498 sdmenu(2);
1499 setleds();
1500 return;
1501
1502 } else { /* menu up */
1503
1504 if (vtcrow EQ 19) {
1505
1506 if ((vtccol GE 1) AND
1507 (vtccol LE 5)) {
1508
1509 clksrc = CK_LOCAL;
1510 pkctrl = PK_PFRM;
1511 setleds();
1512 sdmenu(-1);
1513 sdwin(2);
1514 return;
1515
1516 } else if ((vtccol GE 9) AND
1517 (vtccol LE 13)) {
1518
1519 clksrc = CK_PLS24;
1520 pkctrl = PK_PFRM;
1521 setleds();
1522 sdmenu(-1);
1523 sdwin(2);
1524 return;
1525
1526 } else if ((vtccol GE 17) AND
1527 (vtccol LE 20)) {
1528
1529 clksrc = CK_STEP;
1530 pkctrl = PK_NOTE;
1531 stepenb = TRUE;
1532 setleds();
1533 sdmenu(-1);
1534 sdwin(2);
1535 return;
1536 }
1537
1538/*
1539
1540*/
1541 } else if (vtcrow EQ 20) {
1542
1543 if ((vtccol GE 1) AND
1544 (vtccol LE 5)) {
1545
1546 clksrc = CK_MIDI;
1547 pkctrl = PK_PFRM;
1548 setleds();
1549 sdmenu(-1);
1550 sdwin(2);
1551 return;
1552
1553 } else if ((vtccol GE 9) AND
1554 (vtccol LE 13)) {
1555
1556 clksrc = CK_PLS48;
1557 pkctrl = PK_PFRM;
1558 setleds();
1559 sdmenu(-1);
1560 sdwin(2);
1561 return;
1562 }
1563/*
1564
1565*/
1566 } else if (vtcrow EQ 21) {
1567
1568 if ((vtccol GE 1) AND
1569 (vtccol LE 5)) {
1570
1571 clksrc = CK_SMPTE;
1572 pkctrl = PK_PFRM;
1573 setleds();
1574 sdmenu(-1);
1575 sdwin(2);
1576 return;
1577
1578 } else if ((vtccol GE 9) AND
1579 (vtccol LE 13)) {
1580
1581 clksrc = CK_PLS96;
1582 pkctrl = PK_PFRM;
1583 setleds();
1584 sdmenu(-1);
1585 sdwin(2);
1586 return;
1587 }
1588 }
1589 }
1590 }
1591
1592 return;
1593
1594/*
1595
1596*/
1597 case 3: /* note edit */
1598
1599 if (clkrun) /* clock can't be running */
1600 return;
1601
1602 if (scmctl NE -1)
1603 scmenu(-1);
1604
1605 if (sdmctl EQ -1) { /* menu not up */
1606
1607 sdmenu(1);
1608 noteop = NOP_NUL;
1609 return;
1610
1611 } else { /* menu up - select operation */
1612
1613 if (vtcrow EQ 19) {
1614
1615 if ((vtccol GE 1) AND
1616 (vtccol LE 9)) { /* Begin Acc */
1617
1618 hilitnt(NOP_ACC);
1619 return;
1620
1621 } else if ((vtccol GE 13) AND
1622 (vtccol LE 21)) { /* Move Note */
1623
1624 hilitnt(NOP_MVN);
1625 return;
1626
1627 } else if ((vtccol GE 25) AND
1628 (vtccol LE 30)) { /* Escape */
1629
1630 hilitnt(NOP_NUL);
1631 return;
1632
1633 }
1634
1635 return;
1636/*
1637
1638*/
1639 } else if (vtcrow EQ 20) {
1640
1641 if ((vtccol GE 1) AND
1642 (vtccol LE 9)) { /* Begin Nat */
1643
1644 hilitnt(NOP_NAT);
1645 return;
1646
1647 } else if ((vtccol GE 13) AND
1648 (vtccol LE 22)) { /* Move Begin */
1649
1650 hilitnt(NOP_MVB);
1651 return;
1652 }
1653
1654 return;
1655
1656 } else if (vtcrow EQ 21) {
1657
1658 if ((vtccol GE 1) AND
1659 (vtccol LE 8)) { /* End Note */
1660
1661 hilitnt(NOP_END);
1662 return;
1663
1664 } else if ((vtccol GE 13) AND
1665 (vtccol LE 20)) { /* Move End */
1666
1667 hilitnt(NOP_MVE);
1668 return;
1669 }
1670
1671 return;
1672
1673 } else
1674 return;
1675 }
1676
1677 return;
1678
1679/*
1680
1681*/
1682 case 4: /* assignments */
1683
1684 if (col LE 9) {
1685
1686 if (scmctl NE 1) { /* not up yet -- show page 1 */
1687
1688 lastam = 0;
1689 scmenu(1);
1690
1691 } else { /* up - switch pages */
1692
1693 if (lastam EQ 0) { /* show page 2 */
1694
1695 lastam = 60;
1696 scmenu(1);
1697
1698 } else { /* take down menu */
1699
1700 lastam = 0;
1701 scmenu(-1);
1702 }
1703 }
1704
1705 return;
1706
1707 } else {
1708
1709 enterit(); /* data entry */
1710 return;
1711 }
1712
1713 case 5: /* tunings */
1714
1715 if ((col GE 14) AND (col LE 17)) {
1716
1717 if (scmctl NE 2)
1718 scmenu(2); /* put up menu */
1719 else
1720 scmenu(-1); /* take down menu */
1721
1722 return;
1723
1724 } else {
1725
1726 enterit(); /* data entry */
1727 return;
1728 }
1729/*
1730
1731*/
1732 case 8: /* stop/next */
1733
1734 if ((col GE 40) AND (col LE 43)) { /* stop */
1735
1736 if (recsw) {
1737
1738 if (v_regs[5] & 0x0180)
1739 vbank(0);
1740
1741 if (E_NULL NE (ep = findev(p_cur, t_cur, EV_STOP, -1, -1))) {
1742
1743 se_exec(ep, D_FWD);
1744
1745 } else if (E_NULL NE (ep = e_alc(E_SIZE1))) {
1746
1747 ep->e_time = t_cur;
1748 ep->e_type = EV_STOP;
1749 p_cur= e_ins(ep, ep_adj(p_cur, 0, t_cur))->e_fwd;
1750 se_exec(ep, D_FWD);
1751 ctrsw = TRUE;
1752 se_disp(ep, D_FWD, gdstbc, 1);
1753 scupd();
1754 }
1755 }
1756
1757 } else if ((col GE 45) AND (col LE 48)) { /* next */
1758
1759 if (recsw) {
1760
1761 if (v_regs[5] & 0x0180)
1762 vbank(0);
1763
1764 if (E_NULL NE (ep = findev(p_cur, t_cur, EV_NEXT, -1, -1))) {
1765
1766 se_exec(ep, D_FWD);
1767
1768 } else if (E_NULL NE (ep = e_alc(E_SIZE1))) {
1769
1770 ep->e_time = t_cur;
1771 ep->e_type = EV_NEXT;
1772 p_cur= e_ins(ep, ep_adj(p_cur, 0, t_cur))->e_fwd;
1773 se_exec(ep, D_FWD);
1774 ctrsw = TRUE;
1775 se_disp(ep, D_FWD, gdstbc, 1);
1776 scupd();
1777 }
1778 }
1779
1780 }
1781
1782 return;
1783
1784/*
1785
1786*/
1787 case 9: /* punch in/out */
1788
1789 if ((col GE 50) AND (col LE 51)) { /* punch in */
1790
1791 if (recsw) {
1792
1793 if (v_regs[5] & 0x0180)
1794 vbank(0);
1795
1796 if (E_NULL NE (ep = findev(p_cur, t_cur, EV_STOP, 1, -1))) {
1797
1798 se_exec(ep, D_FWD);
1799
1800 } else if (E_NULL NE (ep = e_alc(E_SIZE1))) {
1801
1802 ep->e_time = t_cur;
1803 ep->e_type = EV_PNCH;
1804 ep->e_data1 = 1;
1805 p_cur= e_ins(ep, ep_adj(p_cur, 0, t_cur))->e_fwd;
1806 se_exec(ep, D_FWD);
1807 ctrsw = TRUE;
1808 se_disp(ep, D_FWD, gdstbc, 1);
1809 scupd();
1810 }
1811 }
1812
1813 } else if ((col GE 53) AND (col LE 55)) { /* punch out */
1814
1815 if (recsw) {
1816
1817 if (v_regs[5] & 0x0180)
1818 vbank(0);
1819
1820 if (E_NULL NE (ep = findev(p_cur, t_cur, EV_PNCH, 0, -1))) {
1821
1822 se_exec(ep, D_FWD);
1823
1824 } else if (E_NULL NE (ep = e_alc(E_SIZE1))) {
1825
1826 ep->e_time = t_cur;
1827 ep->e_type = EV_PNCH;
1828 ep->e_data1 = 0;
1829 p_cur= e_ins(ep, ep_adj(p_cur, 0, t_cur))->e_fwd;
1830 se_exec(ep, D_FWD);
1831 ctrsw = TRUE;
1832 se_disp(ep, D_FWD, gdstbc, 1);
1833 scupd();
1834 }
1835 }
1836
1837 }
1838
1839 return;
1840/*
1841
1842*/
1843 case 10: /* Output */
1844
1845 return;
1846
1847 case 11: /* group/ins, trans, dyn/loc, velocity */
1848
1849 if ((row EQ 18) AND (col LE 3)) { /* inst. menu */
1850
1851 if (scmctl NE 0)
1852 scmenu(0); /* put up the menu */
1853 else
1854 scmenu(-1); /* take down the menu */
1855
1856 return;
1857
1858 } else if ((row EQ 21) AND (col LE 3)) { /* velocity flag */
1859
1860 velflag = NOT velflag;
1861 ds_vmod();
1862 return;
1863
1864 } else {
1865 enterit(); /* inst. number */
1866 return;
1867 }
1868
1869/*
1870
1871*/
1872 case 12: /* analog source, value */
1873
1874 if ((row EQ 23) AND (col LE 4)) { /* display enable */
1875
1876 angroup = -angroup;
1877
1878 if (angroup < 0)
1879 atr = SDW12ATR;
1880 else
1881 atr = (SD_CHNG << 4) | SDBG12;
1882
1883 if (v_regs[5] & 0x0180)
1884 vbank(0);
1885
1886 for (i = 0; i < 4; i++)
1887 vputa(obj8, 7, i, atr);
1888
1889 return;
1890
1891 } else if ((row EQ 22) AND (col LE 4)) { /* r/p source */
1892
1893 ancmsw = NOT ancmsw;
1894
1895 if (ancmsw)
1896 atr = (SD_CHNG << 4) | SDBG12;
1897 else
1898 atr = SDW12ATR;
1899
1900 if (v_regs[5] & 0x0180)
1901 vbank(0);
1902
1903 for (i = 0; i < 4; i++)
1904 vputa(obj8, 6, i, atr);
1905
1906 return;
1907
1908 } else {
1909
1910 enterit();
1911 return;
1912 }
1913/*
1914
1915*/
1916 case 13: /* score number and title */
1917
1918 if (col LE 4) { /* score menu */
1919
1920 if (scmctl NE 3)
1921 scmenu(3); /* put up menu */
1922 else
1923 scmenu(-1); /* take down menu */
1924
1925 return;
1926
1927 } else if ((col GE 10) AND (col LE 25)) { /* score name */
1928
1929 if (sdmctl NE 0) {
1930
1931 sdmenu(0);
1932
1933 vtsetup(obj8, svtdsp, 10, scname[curscor], 19, 1,
1934 advscur, bspscur, nokey, nokey, svtstop,
1935 SDW13DEA, SDBG13);
1936
1937 } else {
1938
1939 vtyper();
1940 }
1941
1942 return;
1943
1944 } else {
1945 enterit();
1946 return;
1947 }
1948/*
1949
1950*/
1951 case 14: /* rec mode */
1952
1953 if ((col GE 31) AND (col LE 34)) { /* Play */
1954
1955 recsw = FALSE;
1956 dsrpmod();
1957 return;
1958
1959 } else if ((col GE 36) AND (col LE 40)) { /* Recrd */
1960
1961 recsw = TRUE;
1962 dsrpmod();
1963 return;
1964
1965 } else if ((col GE 42) AND (col LE 47)) { /* OvrDub */
1966
1967 dubsw = NOT dubsw;
1968 dsrpmod();
1969 return;
1970
1971 } else if ((col GE 49) AND (col LE 55)) { /* PunchIn */
1972
1973 pchsw = NOT pchsw;
1974 dsrpmod();
1975 return;
1976
1977 }
1978
1979 return;
1980
1981 case 16: /* note display */
1982
1983 if (NOP_NUL NE noteop)
1984 donote();
1985
1986 return;
1987 }
1988}
1989
Note: See TracBrowser for help on using the repository browser.