onkelDead / tascam-gtk

GTK+ based application to control Tascam US-16x08 DSP mixer
MIT License
56 stars 12 forks source link

Fix typos in EQ name fields; matches linux 5.10 #20

Closed brulzki closed 3 years ago

brulzki commented 3 years ago

Spelling mistake "Frequence" -> "Frequency"

Kernel commit: 716a0c2881938d222bde67d7edf630ea0648b8f7

brulzki commented 3 years ago

I was getting errors from tascamgtk such as these: Control name='EQ High Frequence',index=0 element not found
Control name='EQ MidHigh Frequence',index=0 element not found Control name='EQ MidLow Frequence',index=0 element not found Control name='EQ Low Frequence',index=0 element not found

Looked into it and found that the 5.10 kernel had changed the name of those elements, so this bring it in line with that change.

onkelDead commented 3 years ago

This change wont work on former kernel versions. I suggest to add a kernel version check to alter the control name

#if LINUX_VERSION_CODE >= KERNEL_VERSION(5,10,0)
#define CTL_NAME_EQ_LOW_FREQ                "name='EQ Low Frequency'"
#else
#define CTL_NAME_EQ_LOW_FREQ                "name='EQ Low Frequence'"
#endif
brulzki commented 3 years ago

I've done that now for each of the frequency controls. Also fixed up OMainWnd.cpp where it maps the alsa controls to widgets.