# # rc-addon-script for plugin remote # check_device() { local handlers="${1}" local name="${2}" local eventdev="" [[ "${handlers}" == "" ]] && return for handler in ${handlers}; do case ${handler} in event*) eventdev=${handler} ;; esac done if [[ "${eventdev}" == "" ]]; then [[ "${evdev_warning_showed}" != "1" ]] \ && echo "you need to load module evdev for autodetect input-devices to work" evdev_warning_showed=1 return fi if [[ (${name/dvb/} != ${name}) || (${name/DVB/} == ${name}) ]]; then return fi einfo_level1 "Autodetect Input Device ${eventdev} (Name: ${name})" REMOTE_PLUGIN_INPUT_DEVICE="${REMOTE_PLUGIN_INPUT_DEVICE} /dev/input/${eventdev}" return } autodetect_input_devices() { [[ -e /proc/bus/input/devices ]] || return exec 3