run kcminit when mouse connects
Hi *, there are known bugs, that for a mouse, that is unplugged and plugged in again, settings are not always properly set as configured. Running /usr/bin/kcminit /usr/lib64/qt5/plugins/plasma/kcminit/kcm_mouse_init.so solves this problem. Does anyone know, where/how this would happen automatically without those known bugs? Is there any other way to run the command mentioned above as soon as a mouse conntects? For the moment I have created a shortcut, but this is annoying in case of a KVM switch. TIA. Bye. Michael.
On Freitag, 30. Juni 2023 21:13:13 CEST mh@mike.franken.de wrote:
Hi *,
there are known bugs, that for a mouse, that is unplugged and plugged in again, settings are not always properly set as configured. Running /usr/bin/kcminit /usr/lib64/qt5/plugins/plasma/kcminit/kcm_mouse_init.so solves this problem.
Does anyone know, where/how this would happen automatically without those known bugs? Is there any other way to run the command mentioned above as soon as a mouse conntects? For the moment I have created a shortcut, but this is annoying in case of a KVM switch.
As an ugly workaround I wrote a small autostart script: #!/bin/bash set -x w=5 while true do # [ $w -lt 300 ] && w=$(( w + 1 )) xinput list | grep -q mouse 2>&1 if [ $? -ne 0 ] then while true do xinput list | grep -q mouse 2>&1 if [ $? -ne 0 ] then sleep $w continue fi /usr/bin/kcminit /usr/lib64/qt5/plugins/plasma/kcminit/kcm_mouse_init.so break done fi sleep $w done
TIA.
Bye. Michael.
participants (1)
-
mh@mike.franken.de