3 # $FreeBSD: head/etc/rc.d/moused 240336 2012-09-11 05:04:59Z obrien $
13 command="/usr/sbin/${name}"
14 start_cmd
="moused_start"
15 pidprefix
="/var/run/moused"
16 pidfile
="${pidprefix}.pid"
20 # Set the pid file and variable name. The second argument, if it exists, is
21 # expected to be the mouse device.
24 eval moused_
$2_enable=\
${moused_$2_enable-${moused_nondefault_enable}}
25 rcvar
="moused_${2}_enable"
26 pidfile
="${pidprefix}.$2.pid"
32 # Set the mouse device and get any related variables. If
33 # a moused device has been specified on the commandline, then
34 # rc.conf(5) variables defined for that device take precedence
35 # over the generic moused_* variables. The only exception is
36 # the moused_port variable, which if not defined sets it to the
37 # passed in device name.
41 eval myflags
=\
${moused_${ms}_flags-$moused_flags}
42 eval myport
=\
${moused_${ms}_port-/dev/$ms}
43 eval mytype
=\
${moused_${ms}_type-$moused_type}
46 myflags
="$moused_flags"
51 check_startmsgs
&& echo -n "Starting ${ms} moused"
52 /usr
/sbin
/moused
${myflags} -p ${myport} -t ${mytype} ${pidarg}
53 check_startmsgs
&& echo '.'
56 case ${mousechar_start} in
60 mousechar_arg
="-M ${mousechar_start}"
64 for ttyv
in /dev
/ttyv
* ; do
65 vidcontrol
< ${ttyv} ${mousechar_arg} -m on