[Splashy-devel] Commit UNIX sockets
Vincenzo Ampolo
vincenzo.ampolo at gmail.com
Thu Aug 17 15:17:34 UTC 2006
On Thu, 2006-08-17 at 17:08 +0200, Tim Dijkstra wrote:
> Does usplash has a progress bar? If they do we can see how they
> calculate the
> progress bar steps.
The way that usplash uses to do its job is the worst that i've seen.
Usplash is designed for ubuntu, so they changed /etc/init.d/rc
and /etc/init.d/rc and added this simple function:
#
# Stub to do progress bar ticks (currently just for usplash) on startup
#
startup_progress() {
$@
step=$(($step + $step_change))
progress=$(($step * $progress_size / $num_steps + $first_step))
if type usplash_write >/dev/null 2>&1; then
usplash_write "PROGRESS $progress" || true
fi
}
Than it's called by the startup function
#
# Start script or program.
#
startup() {
action=$1
shift
scripts="$@"
case "$CONCURRENCY" in
none)
for script in $scripts ; do
case "$script" in
*.sh)
startup_progress $debug sh "$script" $action
;;
*)
startup_progress $debug "$script" $action
;;
esac
done
;;
startpar)
# startpar is not working as it should yet [pere 2005-09-10]
startup_progress $debug startpar -a $action $scripts
;;
shell)
for script in $scripts ; do
startup_progress $debug $script $action &
done
wait
;;
esac
}
Splashy has a better design :D
--
Vincenzo Ampolo
http://www.nanofreesoft.org
http://vincenzoampolo.nanofreesoft.org
http://idp.nanofreesoft.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 191 bytes
Desc: This is a digitally signed message part
Url : http://lists.alioth.debian.org/pipermail/splashy-devel/attachments/20060817/371a8335/attachment.pgp
More information about the Splashy-devel
mailing list