-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathcallbacks.c
More file actions
1726 lines (1468 loc) · 41.5 KB
/
callbacks.c
File metadata and controls
1726 lines (1468 loc) · 41.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
//callbacks.c...
// Callback routines for the GUI elements.
//
// Not strictly callbacks actually. It didn't seem worthwhile to split
// out some of the library functions the callbacks use.
#include "support.h"
#include "speakjet.h"
#include "serial.h"
#include "handles.h"
#include "dictionary.h"
#include <stdlib.h>
#include <ctype.h>
#include <string.h>
#include <sys/time.h>
#include <unistd.h>
#include <gtk/gtk.h>
void HandleCode(unsigned char code);
void HandleCodeWithValue(unsigned char code, char *valueholder);
void SetPitch(unsigned char pitch);
int SingleOrDouble(unsigned char code);
void InsertText(char *texttoinsert);
int FetchValue(unsigned char code);
long int GetTimeinMs(void);
char *GetNextCommand(char *haystack,char *result);
void ViewData(char *outputstring, char *format);
extern void xlate_word(char *word, unsigned char *wordcodes);
#define DOUBLECLICK 2
#define SINGLECLICK 1
unsigned char lastcode=0;
unsigned char lastpitch=0;
long lastcode_time;
void on_button_settings_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
gtk_entry_set_text(GTK_ENTRY(entry_serialdev),portdevice);
//combobox_baudrate
gtk_dialog_run(dialog_settings);
}
void on_button_settingsok_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
const char *newportdevice;
newportdevice=gtk_entry_get_text(GTK_ENTRY(entry_serialdev));
if(newportdevice==NULL)
return;
if(portdevice!=NULL)
free(portdevice);
portdevice=malloc(strlen(newportdevice)+1);
strcpy(portdevice,newportdevice);
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON (radiobutton_19200)))
baudrate=19200;
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON (radiobutton_9600)))
baudrate=9600;
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON (radiobutton_4800)))
baudrate=4800;
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON (radiobutton_2400)))
baudrate=2400;
reopen_port();
gtk_widget_hide(GTK_WIDGET(dialog_settings));
}
void on_button_settingstest_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
char *saveserialdev;
int savebaud;
const char *newportdevice;
newportdevice=gtk_entry_get_text(GTK_ENTRY(entry_serialdev));
savebaud=baudrate;
saveserialdev=portdevice;
if(newportdevice==NULL)
return;
portdevice=malloc(strlen(newportdevice)+1);
strcpy(portdevice,newportdevice);
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON (radiobutton_19200)))
baudrate=19200;
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON (radiobutton_9600)))
baudrate=9600;
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON (radiobutton_4800)))
baudrate=4800;
if(gtk_toggle_button_get_active(GTK_TOGGLE_BUTTON (radiobutton_2400)))
baudrate=2400;
reopen_port();
char testvox[6] = { 31, 192, 131, 8, 187, 191 };
int t;
for(t=0;testvox[t]!=0;t++)
{
write(serialfd,testvox+t,1);
usleep(500); //speakjet freaks out without a 500us delay between chars
}
// restore the old settings, in case the user cancels the dialog...
free(portdevice);
portdevice=saveserialdev;
baudrate=savebaud;
reopen_port();
}
void on_button_settingscancel_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
gtk_widget_hide(GTK_WIDGET(dialog_settings));
}
void on_dialog_settings_close()
{
gtk_widget_hide(GTK_WIDGET(dialog_settings));
}
void on_button_about_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
gtk_dialog_run(dialog_about);
}
void on_button_aboutclose_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
gtk_widget_hide(GTK_WIDGET(dialog_about));
}
void on_dialog_about_close()
{
gtk_widget_hide(GTK_WIDGET(dialog_about));
}
void on_button_P0_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(P0_code);
}
void on_button_P1_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(P1_code);
}
void on_button_P2_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(P2_code);
}
void on_button_P3_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(P3_code);
}
void on_button_P5_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(P5_code);
}
void on_button_P4_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(P4_code);
}
void on_button_P6_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(P6_code);
}
void on_button_delay_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler for buttons with companion values
HandleCodeWithValue(delay_code,"entry_delay");
}
void on_button_O1C_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1C_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2C_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2C_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3C_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3C_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1Cs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1Cs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2Cs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2Cs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3Cs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3Cs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1D_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1D_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2D_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2D_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3D_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3D_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1Ds_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1Ds_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2Ds_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2Ds_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3Ds_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3Ds_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1E_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1E_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2E_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2E_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3E_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3E_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1F_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1F_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2F_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2F_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3F_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3F_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1Fs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1Fs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2Fs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2Fs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3Fs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3Fs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1G_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1G_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2G_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2G_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3G_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3G_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1Gs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1Gs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2Gs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2Gs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3Gs_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3Gs_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1A_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1A_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2A_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2A_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3A_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3A_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1As_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1As_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2As_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2As_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3As_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3As_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O2B_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O2B_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O3B_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O3B_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_O1B_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//change the pitch to match this note
SetPitch(O1B_pitch);
HandleCodeWithValue(pitch_code,"entry_pitch");
}
void on_button_IY_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(IY_code);
}
void on_button_UW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(UW_code);
}
void on_button_IH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(IH_code);
}
void on_button_UH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(UH_code);
}
void on_button_EY_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(EY_code);
}
void on_button_AX_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(AX_code);
}
void on_button_OW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OW_code);
}
void on_button_EH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(EH_code);
}
void on_button_OH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OH_code);
}
void on_button_AY_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(AY_code);
}
void on_button_UX_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(UX_code);
}
void on_button_AW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(AW_code);
}
void on_button_OWIY_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OWIY_code);
}
void on_button_EHLE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(EHLE_code);
}
void on_button_IHWW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(IHWW_code);
}
void on_button_OHIY_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OHIY_code);
}
void on_button_OHIH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OHIH_code);
}
void on_button_AXUW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(AXUW_code);
}
void on_button_OWWW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OWWW_code);
}
void on_button_EYIY_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(EYIY_code);
}
void on_button_IYEH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(IYEH_code);
}
void on_button_IYUW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(IYUW_code);
}
void on_button_AYWW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(AYWW_code);
}
void on_button_WW_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(WW_code);
}
void on_button_MM_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(MM_code);
}
void on_button_NGO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(NGO_code);
}
void on_button_NO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(NO_code);
}
void on_button_LO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(LO_code);
}
void on_button_LE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(LE_code);
}
void on_button_NE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(NE_code);
}
void on_button_NGE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(NGE_code);
}
void on_button_RR_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(RR_code);
}
void on_button_OWRR_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OWRR_code);
}
void on_button_EYRR_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(EYRR_code);
}
void on_button_AWRR_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(AWRR_code);
}
void on_button_IYRR_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(IYRR_code);
}
void on_button_AXRR_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(AXRR_code);
}
void on_button_JH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(JH_code);
}
void on_button_VV_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(VV_code);
}
void on_button_DH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(DH_code);
}
void on_button_ZH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(ZH_code);
}
void on_button_ZZ_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(ZZ_code);
}
void on_button_BE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(BE_code);
}
void on_button_DO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(DO_code);
}
void on_button_EG_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(EG_code);
}
void on_button_BO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(BO_code);
}
void on_button_EB_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(EB_code);
}
void on_button_OB_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OB_code);
}
void on_button_DE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(DE_code);
}
void on_button_ED_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(ED_code);
}
void on_button_OD_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OD_code);
}
void on_button_GE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(GE_code);
}
void on_button_GO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(GO_code);
}
void on_button_OG_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OG_code);
}
void on_button_WH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(WH_code);
}
void on_button_HO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(HO_code);
}
void on_button_HE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(HE_code);
}
void on_button_SO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(SO_code);
}
void on_button_TH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(TH_code);
}
void on_button_FF_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(FF_code);
}
void on_button_SE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(SE_code);
}
void on_button_SH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(SH_code);
}
void on_button_CH_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(CH_code);
}
void on_button_OK_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(OK_code);
}
void on_button_TS_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(TS_code);
}
void on_button_PO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(PO_code);
}
void on_button_PE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(PE_code);
}
void on_button_TT_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(TT_code);
}
void on_button_TU_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(TU_code);
}
void on_button_KE_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(KE_code);
}
void on_button_KO_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(KO_code);
}
void on_button_EK_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(EK_code);
}
void on_button_M0_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(M0_code);
}
void on_button_M1_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(M1_code);
}
void on_button_M2_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(M2_code);
}
void on_button_D11_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D11_code);
}
void on_button_D10_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D10_code);
}
void on_button_D9_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D9_code);
}
void on_button_D8_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D8_code);
}
void on_button_D7_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D7_code);
}
void on_button_D6_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D6_code);
}
void on_button_D5_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D5_code);
}
void on_button_D4_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D4_code);
}
void on_button_D3_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D3_code);
}
void on_button_D2_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D2_code);
}
void on_button_D1_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D1_code);
}
void on_button_D0_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(D0_code);
}
void on_button_C9_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(C9_code);
}
void on_button_C8_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(C8_code);
}
void on_button_C7_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(C7_code);
}
void on_button_C6_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(C6_code);
}
void on_button_C5_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(C5_code);
}
void on_button_C4_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(C4_code);
}
void on_button_C3_clicked(GtkToggleButton *togglebutton, gpointer user_data)
{
//call the double/single click handler
HandleCode(C3_code);
}
void on_button_C2_clicked(GtkToggleButton *togglebutton, gpointer user_data)