summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.am2
-rw-r--r--Makefile.in19
-rw-r--r--aclocal.m4122
-rwxr-xr-xcompile347
-rwxr-xr-xconfigure122
-rw-r--r--configure.ac2
-rw-r--r--doc/Changelog4
-rw-r--r--doc/Makefile.am4
-rw-r--r--doc/Makefile.in7
-rw-r--r--doc/TODO1
-rw-r--r--doc/daisy-player.html4
-rw-r--r--m4/Makefile.in2
-rw-r--r--man/Makefile.in2
-rw-r--r--man/daisy-player.12
-rwxr-xr-xmissing414
-rw-r--r--po/af.gmobin6061 -> 5504 bytes
-rw-r--r--po/af.po196
-rw-r--r--po/daisy-player.pot153
-rw-r--r--po/de.gmobin4971 -> 4971 bytes
-rw-r--r--po/de.po155
-rw-r--r--po/en@boldquot.gmobin5906 -> 5318 bytes
-rw-r--r--po/en@boldquot.po165
-rw-r--r--po/en@quot.gmobin5854 -> 5298 bytes
-rw-r--r--po/en@quot.po165
-rw-r--r--po/es.gmobin6109 -> 5558 bytes
-rw-r--r--po/es.po192
-rw-r--r--po/fr.gmobin4973 -> 4973 bytes
-rw-r--r--po/fr.po155
-rw-r--r--po/hu.gmobin6224 -> 5613 bytes
-rw-r--r--po/hu.po192
-rw-r--r--po/nb.gmobin5996 -> 5455 bytes
-rw-r--r--po/nb.po192
-rw-r--r--po/nl.gmobin6022 -> 5443 bytes
-rw-r--r--po/nl.po194
-rw-r--r--po/pl.gmobin5948 -> 5395 bytes
-rw-r--r--po/pl.po192
-rw-r--r--src/Makefile.in6
-rw-r--r--src/audiocd.c108
-rw-r--r--src/daisy-player.c2031
-rw-r--r--src/daisy.h40
-rw-r--r--src/daisy3.c695
-rw-r--r--src/gettext.h343
-rw-r--r--src/paranoia.c58
43 files changed, 3200 insertions, 3086 deletions
diff --git a/Makefile.am b/Makefile.am
index 7b89267..c320451 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,5 +1,5 @@
AUTOMAKE_OPTIONS = foreign
-SUBDIRS = man doc src po
+SUBDIRS = man doc po src
ACLOCAL_AMFLAGS = -I m4
diff --git a/Makefile.in b/Makefile.in
index 465cf13..a9fa586 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.13.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2013 Free Software Foundation, Inc.
@@ -80,7 +80,7 @@ host_triplet = @host@
subdir = .
DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
$(top_srcdir)/configure $(am__configure_deps) \
- $(srcdir)/config.h.in ChangeLog INSTALL config.guess \
+ $(srcdir)/config.h.in ChangeLog INSTALL compile config.guess \
config.rpath config.sub depcomp install-sh missing ltmain.sh
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/gettext.m4 \
@@ -331,7 +331,7 @@ top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
AUTOMAKE_OPTIONS = foreign
-SUBDIRS = man doc src po
+SUBDIRS = man doc po src
ACLOCAL_AMFLAGS = -I m4
EXTRA_DIST = config.rpath m4/Makefile.in src/gettext.h doc/COMPILE \
doc/Changelog doc/License doc/Readme doc/daisy-player.* \
@@ -379,8 +379,8 @@ $(ACLOCAL_M4): $(am__aclocal_m4_deps)
$(am__aclocal_m4_deps):
config.h: stamp-h1
- @if test ! -f $@; then rm -f stamp-h1; else :; fi
- @if test ! -f $@; then $(MAKE) $(AM_MAKEFLAGS) stamp-h1; else :; fi
+ @test -f $@ || rm -f stamp-h1
+ @test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1
stamp-h1: $(srcdir)/config.h.in $(top_builddir)/config.status
@rm -f stamp-h1
@@ -580,10 +580,16 @@ dist-xz: distdir
$(am__post_remove_distdir)
dist-tarZ: distdir
+ @echo WARNING: "Support for shar distribution archives is" \
+ "deprecated." >&2
+ @echo WARNING: "It will be removed altogether in Automake 2.0" >&2
tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
$(am__post_remove_distdir)
dist-shar: distdir
+ @echo WARNING: "Support for distribution archives compressed with" \
+ "legacy program 'compress' is deprecated." >&2
+ @echo WARNING: "It will be removed altogether in Automake 2.0" >&2
shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
$(am__post_remove_distdir)
@@ -625,9 +631,10 @@ distcheck: dist
&& dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
&& am__cwd=`pwd` \
&& $(am__cd) $(distdir)/_build \
- && ../configure --srcdir=.. --prefix="$$dc_install_base" \
+ && ../configure \
$(AM_DISTCHECK_CONFIGURE_FLAGS) \
$(DISTCHECK_CONFIGURE_FLAGS) \
+ --srcdir=.. --prefix="$$dc_install_base" \
&& $(MAKE) $(AM_MAKEFLAGS) \
&& $(MAKE) $(AM_MAKEFLAGS) dvi \
&& $(MAKE) $(AM_MAKEFLAGS) check \
diff --git a/aclocal.m4 b/aclocal.m4
index 8ebfced..9ae9e86 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,4 +1,4 @@
-# generated automatically by aclocal 1.13.3 -*- Autoconf -*-
+# generated automatically by aclocal 1.14.1 -*- Autoconf -*-
# Copyright (C) 1996-2013 Free Software Foundation, Inc.
@@ -32,10 +32,10 @@ To do so, use the procedure documented by the package, typically 'autoreconf'.])
# generated from the m4 files accompanying Automake X.Y.
# (This private macro should not be called outside this file.)
AC_DEFUN([AM_AUTOMAKE_VERSION],
-[am__api_version='1.13'
+[am__api_version='1.14'
dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
dnl require some minimum version. Point them to the right macro.
-m4_if([$1], [1.13.3], [],
+m4_if([$1], [1.14.1], [],
[AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
])
@@ -51,7 +51,7 @@ m4_define([_AM_AUTOCONF_VERSION], [])
# Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
# This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.13.3])dnl
+[AM_AUTOMAKE_VERSION([1.14.1])dnl
m4_ifndef([AC_AUTOCONF_VERSION],
[m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
_AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
@@ -457,6 +457,12 @@ _AM_IF_OPTION([no-dependencies],, [_AM_DEPENDENCIES(GCJ)])
# This macro actually does too much. Some checks are only needed if
# your package does certain things. But this isn't really a big deal.
+dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
+m4_define([AC_PROG_CC],
+m4_defn([AC_PROG_CC])
+[_AM_PROG_CC_C_O
+])
+
# AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
# AM_INIT_AUTOMAKE([OPTIONS])
# -----------------------------------------------
@@ -565,7 +571,48 @@ dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
AC_CONFIG_COMMANDS_PRE(dnl
[m4_provide_if([_AM_COMPILER_EXEEXT],
[AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
-])
+
+# POSIX will say in a future version that running "rm -f" with no argument
+# is OK; and we want to be able to make that assumption in our Makefile
+# recipes. So use an aggressive probe to check that the usage we want is
+# actually supported "in the wild" to an acceptable degree.
+# See automake bug#10828.
+# To make any issue more visible, cause the running configure to be aborted
+# by default if the 'rm' program in use doesn't match our expectations; the
+# user can still override this though.
+if rm -f && rm -fr && rm -rf; then : OK; else
+ cat >&2 <<'END'
+Oops!
+
+Your 'rm' program seems unable to run without file operands specified
+on the command line, even when the '-f' option is present. This is contrary
+to the behaviour of most rm programs out there, and not conforming with
+the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
+
+Please tell bug-automake@gnu.org about your system, including the value
+of your $PATH and any error possibly output before this message. This
+can help us improve future automake versions.
+
+END
+ if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
+ echo 'Configuration will proceed anyway, since you have set the' >&2
+ echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
+ echo >&2
+ else
+ cat >&2 <<'END'
+Aborting the configuration process, to ensure you take notice of the issue.
+
+You can download and install GNU coreutils to get an 'rm' implementation
+that behaves properly: <http://www.gnu.org/software/coreutils/>.
+
+If you want to complete the configuration process using your problematic
+'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
+to "yes", and re-run configure.
+
+END
+ AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
+ fi
+fi])
dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion. Do not
dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
@@ -573,7 +620,6 @@ dnl mangled by Autoconf and run in a shell conditional statement.
m4_define([_AC_COMPILER_EXEEXT],
m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
-
# When config.status generates a header, we must update the stamp-h file.
# This file resides in the same directory as the config header
# that is generated. The stamp files are numbered to have different names.
@@ -755,6 +801,70 @@ AC_DEFUN([_AM_SET_OPTIONS],
AC_DEFUN([_AM_IF_OPTION],
[m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
+# Copyright (C) 1999-2013 Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# _AM_PROG_CC_C_O
+# ---------------
+# Like AC_PROG_CC_C_O, but changed for automake. We rewrite AC_PROG_CC
+# to automatically call this.
+AC_DEFUN([_AM_PROG_CC_C_O],
+[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
+AC_REQUIRE_AUX_FILE([compile])dnl
+AC_LANG_PUSH([C])dnl
+AC_CACHE_CHECK(
+ [whether $CC understands -c and -o together],
+ [am_cv_prog_cc_c_o],
+ [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
+ # Make sure it works both with $CC and with simple cc.
+ # Following AC_PROG_CC_C_O, we do the test twice because some
+ # compilers refuse to overwrite an existing .o file with -o,
+ # though they will create one.
+ am_cv_prog_cc_c_o=yes
+ for am_i in 1 2; do
+ if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
+ && test -f conftest2.$ac_objext; then
+ : OK
+ else
+ am_cv_prog_cc_c_o=no
+ break
+ fi
+ done
+ rm -f core conftest*
+ unset am_i])
+if test "$am_cv_prog_cc_c_o" != yes; then
+ # Losing compiler, so override with the script.
+ # FIXME: It is wrong to rewrite CC.
+ # But if we don't then we get into trouble of one sort or another.
+ # A longer-term fix would be to have automake use am__CC in this case,
+ # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
+ CC="$am_aux_dir/compile $CC"
+fi
+AC_LANG_POP([C])])
+
+# For backward compatibility.
+AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
+
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# AM_RUN_LOG(COMMAND)
+# -------------------
+# Run COMMAND, save the exit status in ac_status, and log it.
+# (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
+AC_DEFUN([AM_RUN_LOG],
+[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
+ ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
+ (exit $ac_status); }])
+
# Check to make sure that the build environment is sane. -*- Autoconf -*-
# Copyright (C) 1996-2013 Free Software Foundation, Inc.
diff --git a/compile b/compile
new file mode 100755
index 0000000..531136b
--- /dev/null
+++ b/compile
@@ -0,0 +1,347 @@
+#! /bin/sh
+# Wrapper for compilers which do not understand '-c -o'.
+
+scriptversion=2012-10-14.11; # UTC
+
+# Copyright (C) 1999-2013 Free Software Foundation, Inc.
+# Written by Tom Tromey <tromey@cygnus.com>.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
+# This file is maintained in Automake, please report
+# bugs to <bug-automake@gnu.org> or send patches to
+# <automake-patches@gnu.org>.
+
+nl='
+'
+
+# We need space, tab and new line, in precisely that order. Quoting is
+# there to prevent tools from complaining about whitespace usage.
+IFS=" "" $nl"
+
+file_conv=
+
+# func_file_conv build_file lazy
+# Convert a $build file to $host form and store it in $file
+# Currently only supports Windows hosts. If the determined conversion
+# type is listed in (the comma separated) LAZY, no conversion will
+# take place.
+func_file_conv ()
+{
+ file=$1
+ case $file in
+ / | /[!/]*) # absolute file, and not a UNC file
+ if test -z "$file_conv"; then
+ # lazily determine how to convert abs files
+ case `uname -s` in
+ MINGW*)
+ file_conv=mingw
+ ;;
+ CYGWIN*)
+ file_conv=cygwin
+ ;;
+ *)
+ file_conv=wine
+ ;;
+ esac
+ fi
+ case $file_conv/,$2, in
+ *,$file_conv,*)
+ ;;
+ mingw/*)
+ file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
+ ;;
+ cygwin/*)
+ file=`cygpath -m "$file" || echo "$file"`
+ ;;
+ wine/*)
+ file=`winepath -w "$file" || echo "$file"`
+ ;;
+ esac
+ ;;
+ esac
+}
+
+# func_cl_dashL linkdir
+# Make cl look for libraries in LINKDIR
+func_cl_dashL ()
+{
+ func_file_conv "$1"
+ if test -z "$lib_path"; then
+ lib_path=$file
+ else
+ lib_path="$lib_path;$file"
+ fi
+ linker_opts="$linker_opts -LIBPATH:$file"
+}
+
+# func_cl_dashl library
+# Do a library search-path lookup for cl
+func_cl_dashl ()
+{
+ lib=$1
+ found=no
+ save_IFS=$IFS
+ IFS=';'
+ for dir in $lib_path $LIB
+ do
+ IFS=$save_IFS
+ if $shared && test -f "$dir/$lib.dll.lib"; then
+ found=yes
+ lib=$dir/$lib.dll.lib
+ break
+ fi
+ if test -f "$dir/$lib.lib"; then
+ found=yes
+ lib=$dir/$lib.lib
+ break
+ fi
+ if test -f "$dir/lib$lib.a"; then
+ found=yes
+ lib=$dir/lib$lib.a
+ break
+ fi
+ done
+ IFS=$save_IFS
+
+ if test "$found" != yes; then
+ lib=$lib.lib
+ fi
+}
+
+# func_cl_wrapper cl arg...
+# Adjust compile command to suit cl
+func_cl_wrapper ()
+{
+ # Assume a capable shell
+ lib_path=
+ shared=:
+ linker_opts=
+ for arg
+ do
+ if test -n "$eat"; then
+ eat=
+ else
+ case $1 in
+ -o)
+ # configure might choose to run compile as 'compile cc -o foo foo.c'.
+ eat=1
+ case $2 in
+ *.o | *.[oO][bB][jJ])
+ func_file_conv "$2"
+ set x "$@" -Fo"$file"
+ shift
+ ;;
+ *)
+ func_file_conv "$2"
+ set x "$@" -Fe"$file"
+ shift
+ ;;
+ esac
+ ;;
+ -I)
+ eat=1
+ func_file_conv "$2" mingw
+ set x "$@" -I"$file"
+ shift
+ ;;
+ -I*)
+ func_file_conv "${1#-I}" mingw
+ set x "$@" -I"$file"
+ shift
+ ;;
+ -l)
+ eat=1
+ func_cl_dashl "$2"
+ set x "$@" "$lib"
+ shift
+ ;;
+ -l*)
+ func_cl_dashl "${1#-l}"
+ set x "$@" "$lib"
+ shift
+ ;;
+ -L)
+ eat=1
+ func_cl_dashL "$2"
+ ;;
+ -L*)
+ func_cl_dashL "${1#-L}"
+ ;;
+ -static)
+ shared=false
+ ;;
+ -Wl,*)
+ arg=${1#-Wl,}
+ save_ifs="$IFS"; IFS=','
+ for flag in $arg; do
+ IFS="$save_ifs"
+ linker_opts="$linker_opts $flag"
+ done
+ IFS="$save_ifs"
+ ;;
+ -Xlinker)
+ eat=1
+ linker_opts="$linker_opts $2"
+ ;;
+ -*)
+ set x "$@" "$1"
+ shift
+ ;;
+ *.cc | *.CC | *.cxx | *.CXX | *.[cC]++)
+ func_file_conv "$1"
+ set x "$@" -Tp"$file"
+ shift
+ ;;
+ *.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO])
+ func_file_conv "$1" mingw
+ set x "$@" "$file"
+ shift
+ ;;
+ *)
+ set x "$@" "$1"
+ shift
+ ;;
+ esac
+ fi
+ shift
+ done
+ if test -n "$linker_opts"; then
+ linker_opts="-link$linker_opts"
+ fi
+ exec "$@" $linker_opts
+ exit 1
+}
+
+eat=
+
+case $1 in
+ '')
+ echo "$0: No command. Try '$0 --help' for more information." 1>&2
+ exit 1;
+ ;;
+ -h | --h*)
+ cat <<\EOF
+Usage: compile [--help] [--version] PROGRAM [ARGS]
+
+Wrapper for compilers which do not understand '-c -o'.
+Remove '-o dest.o' from ARGS, run PROGRAM with the remaining
+arguments, and rename the output as expected.
+
+If you are trying to build a whole package this is not the
+right script to run: please start by reading the file 'INSTALL'.
+
+Report bugs to <bug-automake@gnu.org>.
+EOF
+ exit $?
+ ;;
+ -v | --v*)
+ echo "compile $scriptversion"
+ exit $?
+ ;;
+ cl | *[/\\]cl | cl.exe | *[/\\]cl.exe )
+ func_cl_wrapper "$@" # Doesn't return...
+ ;;
+esac
+
+ofile=
+cfile=
+
+for arg
+do
+ if test -n "$eat"; then
+ eat=
+ else
+ case $1 in
+ -o)
+ # configure might choose to run compile as 'compile cc -o foo foo.c'.
+ # So we strip '-o arg' only if arg is an object.
+ eat=1
+ case $2 in
+ *.o | *.obj)
+ ofile=$2
+ ;;
+ *)
+ set x "$@" -o "$2"
+ shift
+ ;;
+ esac
+ ;;
+ *.c)
+ cfile=$1
+ set x "$@" "$1"
+ shift
+ ;;
+ *)
+ set x "$@" "$1"
+ shift
+ ;;
+ esac
+ fi
+ shift
+done
+
+if test -z "$ofile" || test -z "$cfile"; then
+ # If no '-o' option was seen then we might have been invoked from a
+ # pattern rule where we don't need one. That is ok -- this is a
+ # normal compilation that the losing compiler can handle. If no
+ # '.c' file was seen then we are probably linking. That is also
+ # ok.
+ exec "$@"
+fi
+
+# Name of file we expect compiler to create.
+cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'`
+
+# Create the lock directory.
+# Note: use '[/\\:.-]' here to ensure that we don't use the same name
+# that we are using for the .o file. Also, base the name on the expected
+# object file name, since that is what matters with a parallel build.
+lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d
+while true; do
+ if mkdir "$lockdir" >/dev/null 2>&1; then
+ break
+ fi
+ sleep 1
+done
+# FIXME: race condition here if user kills between mkdir and trap.
+trap "rmdir '$lockdir'; exit 1" 1 2 15
+
+# Run the compile.
+"$@"
+ret=$?
+
+if test -f "$cofile"; then
+ test "$cofile" = "$ofile" || mv "$cofile" "$ofile"
+elif test -f "${cofile}bj"; then
+ test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile"
+fi
+
+rmdir "$lockdir"
+exit $ret
+
+# Local Variables:
+# mode: shell-script
+# sh-indentation: 2
+# eval: (add-hook 'write-file-hooks 'time-stamp)
+# time-stamp-start: "scriptversion="
+# time-stamp-format: "%:y-%02m-%02d.%02H"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "; # UTC"
+# End:
diff --git a/configure b/configure
index 5db7690..a36a833 100755
--- a/configure
+++ b/configure
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for daisy-player 8.6.
+# Generated by GNU Autoconf 2.69 for daisy-player 8.6.1.
#
# Report bugs to <jos@jlemmens.nl>.
#
@@ -580,8 +580,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='daisy-player'
PACKAGE_TARNAME='daisy-player'
-PACKAGE_VERSION='8.6'
-PACKAGE_STRING='daisy-player 8.6'
+PACKAGE_VERSION='8.6.1'
+PACKAGE_STRING='daisy-player 8.6.1'
PACKAGE_BUGREPORT='jos@jlemmens.nl'
PACKAGE_URL='www.jlemmens.nl'
@@ -1338,7 +1338,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
-\`configure' configures daisy-player 8.6 to adapt to many kinds of systems.
+\`configure' configures daisy-player 8.6.1 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
@@ -1408,7 +1408,7 @@ fi
if test -n "$ac_init_help"; then
case $ac_init_help in
- short | recursive ) echo "Configuration of daisy-player 8.6:";;
+ short | recursive ) echo "Configuration of daisy-player 8.6.1:";;
esac
cat <<\_ACEOF
@@ -1519,7 +1519,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
-daisy-player configure 8.6
+daisy-player configure 8.6.1
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2132,7 +2132,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
-It was created by daisy-player $as_me 8.6, which was
+It was created by daisy-player $as_me 8.6.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
@@ -2481,7 +2481,7 @@ ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $
ac_compiler_gnu=$ac_cv_c_compiler_gnu
-am__api_version='1.13'
+am__api_version='1.14'
ac_aux_dir=
for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
@@ -2996,7 +2996,7 @@ fi
# Define the identity of the package.
PACKAGE='daisy-player'
- VERSION='8.6'
+ VERSION='8.6.1'
cat >>confdefs.h <<_ACEOF
@@ -3047,6 +3047,47 @@ am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
+# POSIX will say in a future version that running "rm -f" with no argument
+# is OK; and we want to be able to make that assumption in our Makefile
+# recipes. So use an aggressive probe to check that the usage we want is
+# actually supported "in the wild" to an acceptable degree.
+# See automake bug#10828.
+# To make any issue more visible, cause the running configure to be aborted
+# by default if the 'rm' program in use doesn't match our expectations; the
+# user can still override this though.
+if rm -f && rm -fr && rm -rf; then : OK; else
+ cat >&2 <<'END'
+Oops!
+
+Your 'rm' program seems unable to run without file operands specified
+on the command line, even when the '-f' option is present. This is contrary
+to the behaviour of most rm programs out there, and not conforming with
+the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
+
+Please tell bug-automake@gnu.org about your system, including the value
+of your $PATH and any error possibly output before this message. This
+can help us improve future automake versions.
+
+END
+ if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
+ echo 'Configuration will proceed anyway, since you have set the' >&2
+ echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
+ echo >&2
+ else
+ cat >&2 <<'END'
+Aborting the configuration process, to ensure you take notice of the issue.
+
+You can download and install GNU coreutils to get an 'rm' implementation
+that behaves properly: <http://www.gnu.org/software/coreutils/>.
+
+If you want to complete the configuration process using your problematic
+'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
+to "yes", and re-run configure.
+
+END
+ as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
+ fi
+fi
ac_config_headers="$ac_config_headers config.h"
@@ -3882,6 +3923,65 @@ ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
+$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
+if ${am_cv_prog_cc_c_o+:} false; then :
+ $as_echo_n "(cached) " >&6
+else
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+
+int
+main ()
+{
+
+ ;
+ return 0;
+}
+_ACEOF
+ # Make sure it works both with $CC and with simple cc.
+ # Following AC_PROG_CC_C_O, we do the test twice because some
+ # compilers refuse to overwrite an existing .o file with -o,
+ # though they will create one.
+ am_cv_prog_cc_c_o=yes
+ for am_i in 1 2; do
+ if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
+ ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } \
+ && test -f conftest2.$ac_objext; then
+ : OK
+ else
+ am_cv_prog_cc_c_o=no
+ break
+ fi
+ done
+ rm -f core conftest*
+ unset am_i
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
+$as_echo "$am_cv_prog_cc_c_o" >&6; }
+if test "$am_cv_prog_cc_c_o" != yes; then
+ # Losing compiler, so override with the script.
+ # FIXME: It is wrong to rewrite CC.
+ # But if we don't then we get into trouble of one sort or another.
+ # A longer-term fix would be to have automake use am__CC in this case,
+ # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
+ CC="$am_aux_dir/compile $CC"
+fi
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
DEPDIR="${am__leading_dot}deps"
ac_config_commands="$ac_config_commands depfiles"
@@ -9594,7 +9694,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
-This file was extended by daisy-player $as_me 8.6, which was
+This file was extended by daisy-player $as_me 8.6.1, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
@@ -9661,7 +9761,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
-daisy-player config.status 8.6
+daisy-player config.status 8.6.1
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
diff --git a/configure.ac b/configure.ac
index b29cedb..5559356 100644
--- a/configure.ac
+++ b/configure.ac
@@ -2,7 +2,7 @@
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.69])
-AC_INIT([daisy-player], [8.6], [jos@jlemmens.nl], [], [www.jlemmens.nl])
+AC_INIT([daisy-player], [8.6.1], [jos@jlemmens.nl], [], [www.jlemmens.nl])
AM_INIT_AUTOMAKE([foreign])
AC_CONFIG_SRCDIR([config.h.in])
AC_CONFIG_HEADERS([config.h])
diff --git a/doc/Changelog b/doc/Changelog
index 2235d1b..82ef73e 100644
--- a/doc/Changelog
+++ b/doc/Changelog
@@ -174,3 +174,7 @@ Samuel Thibault <sthibault@debian.org>
8.6 Time viewing depends on the playing speed.
How faster the playing speed, shorter times are shown. And vv.
The udisks package has been dropped in favor of the udisks2 package.
+8.6.1 All global variables deleted.
+ daisy-player now only uses loacal variables
+ The daisy_t struct array now only gets the number of needed
+ elements. Older versions got staticly 2000 elements.
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 65b858f..1569abc 100644
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
@@ -1,3 +1,5 @@
docdir = $(datadir)/doc/@PACKAGE@
-doc_DATA = ABOUT-NLS COMPILE COPYING Changelog License Readme TODO daisy-player.desktop daisy-player.menu daisy-player.png daisy-player.txt
+doc_DATA = ABOUT-NLS COMPILE COPYING Changelog License Readme TODO \
+ daisy-player.desktop daisy-player.menu daisy-player.png \
+ daisy-player.txt
dist_html_DATA = daisy-player.html
diff --git a/doc/Makefile.in b/doc/Makefile.in
index 9762700..cfd7aa5 100644
--- a/doc/Makefile.in
+++ b/doc/Makefile.in
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.13.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2013 Free Software Foundation, Inc.
@@ -278,7 +278,10 @@ target_alias = @target_alias@
top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
-doc_DATA = ABOUT-NLS COMPILE COPYING Changelog License Readme TODO daisy-player.desktop daisy-player.menu daisy-player.png daisy-player.txt
+doc_DATA = ABOUT-NLS COMPILE COPYING Changelog License Readme TODO \
+ daisy-player.desktop daisy-player.menu daisy-player.png \
+ daisy-player.txt
+
dist_html_DATA = daisy-player.html
all: all-am
diff --git a/doc/TODO b/doc/TODO
index e69de29..cae29a6 100644
--- a/doc/TODO
+++ b/doc/TODO
@@ -0,0 +1 @@
+- 'd' command writes the pllaying item to disk, not the item with the cursor.
diff --git a/doc/daisy-player.html b/doc/daisy-player.html
index 53e38d0..ad14f0a 100644
--- a/doc/daisy-player.html
+++ b/doc/daisy-player.html
@@ -2,7 +2,7 @@
<HTML><HEAD><TITLE>Man page of daisy-player</TITLE>
</HEAD><BODY>
<H1>daisy-player</H1>
-Section: Linux Reference Manual (1)<BR>Updated: 06 April 2014<BR><A HREF="#index">Index</A>
+Section: Linux Reference Manual (1)<BR>Updated: 19 June 2014<BR><A HREF="#index">Index</A>
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
<A NAME="lbAB">&nbsp;</A>
@@ -239,6 +239,6 @@ This program is free software; you can redistribute it and/or modify it under th
This document was created by
<A HREF="/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR>
-Time: 12:26:01 GMT, April 06, 2014
+Time: 16:33:37 GMT, June 19, 2014
</BODY>
</HTML>
diff --git a/m4/Makefile.in b/m4/Makefile.in
index a3a6322..2fa8813 100644
--- a/m4/Makefile.in
+++ b/m4/Makefile.in
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.13.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2013 Free Software Foundation, Inc.
diff --git a/man/Makefile.in b/man/Makefile.in
index 7e83105..710eadb 100644
--- a/man/Makefile.in
+++ b/man/Makefile.in
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.13.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2013 Free Software Foundation, Inc.
diff --git a/man/daisy-player.1 b/man/daisy-player.1
index 89a0aa4..6c47ed4 100644
--- a/man/daisy-player.1
+++ b/man/daisy-player.1
@@ -1,5 +1,5 @@
.\"Text automatically generated by txt2man
-.TH daisy-player 1 "06 April 2014" "man" "Linux Reference Manual"
+.TH daisy-player 1 "19 June 2014" "daisy-player-8.6.1" "Linux Reference Manual"
.SH NAME
\fBdaisy-player \fP- player for DAISY Digital Talking Books or Audio-CD's
\fB
diff --git a/missing b/missing
index cdea514..86a8fc3 100755
--- a/missing
+++ b/missing
@@ -1,10 +1,11 @@
#! /bin/sh
-# Common wrapper for a few potentially missing GNU programs.
+# Common stub for a few missing GNU programs while installing.
-scriptversion=2012-06-26.16; # UTC
+scriptversion=2012-01-06.13; # UTC
-# Copyright (C) 1996-2013 Free Software Foundation, Inc.
-# Originally written by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
+# Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006,
+# 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc.
+# Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -25,40 +26,68 @@ scriptversion=2012-06-26.16; # UTC
# the same distribution terms that you use for the rest of that program.
if test $# -eq 0; then
- echo 1>&2 "Try '$0 --help' for more information"
+ echo 1>&2 "Try \`$0 --help' for more information"
exit 1
fi
-case $1 in
+run=:
+sed_output='s/.* --output[ =]\([^ ]*\).*/\1/p'
+sed_minuso='s/.* -o \([^ ]*\).*/\1/p'
- --is-lightweight)
- # Used by our autoconf macros to check whether the available missing
- # script is modern enough.
- exit 0
- ;;
+# In the cases where this matters, `missing' is being run in the
+# srcdir already.
+if test -f configure.ac; then
+ configure_ac=configure.ac
+else
+ configure_ac=configure.in
+fi
- --run)
- # Back-compat with the calling convention used by older automake.
- shift
- ;;
+msg="missing on your system"
+
+case $1 in
+--run)
+ # Try to run requested program, and just exit if it succeeds.
+ run=
+ shift
+ "$@" && exit 0
+ # Exit code 63 means version mismatch. This often happens
+ # when the user try to use an ancient version of a tool on
+ # a file that requires a minimum version. In this case we
+ # we should proceed has if the program had been absent, or
+ # if --run hadn't been passed.
+ if test $? = 63; then
+ run=:
+ msg="probably too old"
+ fi
+ ;;
-h|--h|--he|--hel|--help)
echo "\
$0 [OPTION]... PROGRAM [ARGUMENT]...
-Run 'PROGRAM [ARGUMENT]...', returning a proper advice when this fails due
-to PROGRAM being missing or too old.
+Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an
+error status if there is no known handling for PROGRAM.
Options:
-h, --help display this help and exit
-v, --version output version information and exit
+ --run try to run the given command, and emulate it if it fails
Supported PROGRAM values:
- aclocal autoconf autoheader autom4te automake makeinfo
- bison yacc flex lex help2man
+ aclocal touch file \`aclocal.m4'
+ autoconf touch file \`configure'
+ autoheader touch file \`config.h.in'
+ autom4te touch the output file, or create a stub one
+ automake touch all \`Makefile.in' files
+ bison create \`y.tab.[ch]', if possible, from existing .[ch]
+ flex create \`lex.yy.c', if possible, from existing .c
+ help2man touch the output file
+ lex create \`lex.yy.c', if possible, from existing .c
+ makeinfo touch the output file
+ yacc create \`y.tab.[ch]', if possible, from existing .[ch]
-Version suffixes to PROGRAM as well as the prefixes 'gnu-', 'gnu', and
-'g' are ignored when checking the name.
+Version suffixes to PROGRAM as well as the prefixes \`gnu-', \`gnu', and
+\`g' are ignored when checking the name.
Send bug reports to <bug-automake@gnu.org>."
exit $?
@@ -70,141 +99,228 @@ Send bug reports to <bug-automake@gnu.org>."
;;
-*)
- echo 1>&2 "$0: unknown '$1' option"
- echo 1>&2 "Try '$0 --help' for more information"
+ echo 1>&2 "$0: Unknown \`$1' option"
+ echo 1>&2 "Try \`$0 --help' for more information"
exit 1
;;
esac
-# Run the given program, remember its exit status.
-"$@"; st=$?
-
-# If it succeeded, we are done.
-test $st -eq 0 && exit 0
-
-# Also exit now if we it failed (or wasn't found), and '--version' was
-# passed; such an option is passed most likely to detect whether the
-# program is present and works.
-case $2 in --version|--help) exit $st;; esac
-
-# Exit code 63 means version mismatch. This often happens when the user
-# tries to use an ancient version of a tool on a file that requires a
-# minimum version.
-if test $st -eq 63; then
- msg="probably too old"
-elif test $st -eq 127; then
- # Program was missing.
- msg="missing on your system"
-else
- # Program was found and executed, but failed. Give up.
- exit $st
-fi
+# normalize program name to check for.
+program=`echo "$1" | sed '
+ s/^gnu-//; t
+ s/^gnu//; t
+ s/^g//; t'`
+
+# Now exit if we have it, but it failed. Also exit now if we
+# don't have it and --version was passed (most likely to detect
+# the program). This is about non-GNU programs, so use $1 not
+# $program.
+case $1 in
+ lex*|yacc*)
+ # Not GNU programs, they don't have --version.
+ ;;
+
+ *)
+ if test -z "$run" && ($1 --version) > /dev/null 2>&1; then
+ # We have it, but it failed.
+ exit 1
+ elif test "x$2" = "x--version" || test "x$2" = "x--help"; then
+ # Could not run --version or --help. This is probably someone
+ # running `$TOOL --version' or `$TOOL --help' to check whether
+ # $TOOL exists and not knowing $TOOL uses missing.
+ exit 1
+ fi
+ ;;
+esac
+
+# If it does not exist, or fails to run (possibly an outdated version),
+# try to emulate it.
+case $program in
+ aclocal*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified \`acinclude.m4' or \`${configure_ac}'. You might want
+ to install the \`Automake' and \`Perl' packages. Grab them from
+ any GNU archive site."
+ touch aclocal.m4
+ ;;
+
+ autoconf*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified \`${configure_ac}'. You might want to install the
+ \`Autoconf' and \`GNU m4' packages. Grab them from any GNU
+ archive site."
+ touch configure
+ ;;
-perl_URL=http://www.perl.org/
-flex_URL=http://flex.sourceforge.net/
-gnu_software_URL=http://www.gnu.org/software
-
-program_details ()
-{
- case $1 in
- aclocal|automake)
- echo "The '$1' program is part of the GNU Automake package:"
- echo "<$gnu_software_URL/automake>"
- echo "It also requires GNU Autoconf, GNU m4 and Perl in order to run:"
- echo "<$gnu_software_URL/autoconf>"
- echo "<$gnu_software_URL/m4/>"
- echo "<$perl_URL>"
- ;;
- autoconf|autom4te|autoheader)
- echo "The '$1' program is part of the GNU Autoconf package:"
- echo "<$gnu_software_URL/autoconf/>"
- echo "It also requires GNU m4 and Perl in order to run:"
- echo "<$gnu_software_URL/m4/>"
- echo "<$perl_URL>"
- ;;
- esac
-}
-
-give_advice ()
-{
- # Normalize program name to check for.
- normalized_program=`echo "$1" | sed '
- s/^gnu-//; t
- s/^gnu//; t
- s/^g//; t'`
-
- printf '%s\n' "'$1' is $msg."
-
- configure_deps="'configure.ac' or m4 files included by 'configure.ac'"
- case $normalized_program in
- autoconf*)
- echo "You should only need it if you modified 'configure.ac',"
- echo "or m4 files included by it."
- program_details 'autoconf'
- ;;
- autoheader*)
- echo "You should only need it if you modified 'acconfig.h' or"
- echo "$configure_deps."
- program_details 'autoheader'
- ;;
- automake*)
- echo "You should only need it if you modified 'Makefile.am' or"
- echo "$configure_deps."
- program_details 'automake'
- ;;
- aclocal*)
- echo "You should only need it if you modified 'acinclude.m4' or"
- echo "$configure_deps."
- program_details 'aclocal'
- ;;
- autom4te*)
- echo "You might have modified some maintainer files that require"
- echo "the 'automa4te' program to be rebuilt."
- program_details 'autom4te'
- ;;
- bison*|yacc*)
- echo "You should only need it if you modified a '.y' file."
- echo "You may want to install the GNU Bison package:"
- echo "<$gnu_software_URL/bison/>"
- ;;
- lex*|flex*)
- echo "You should only need it if you modified a '.l' file."
- echo "You may want to install the Fast Lexical Analyzer package:"
- echo "<$flex_URL>"
- ;;
- help2man*)
- echo "You should only need it if you modified a dependency" \
- "of a man page."
- echo "You may want to install the GNU Help2man package:"
- echo "<$gnu_software_URL/help2man/>"
+ autoheader*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified \`acconfig.h' or \`${configure_ac}'. You might want
+ to install the \`Autoconf' and \`GNU m4' packages. Grab them
+ from any GNU archive site."
+ files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}`
+ test -z "$files" && files="config.h"
+ touch_files=
+ for f in $files; do
+ case $f in
+ *:*) touch_files="$touch_files "`echo "$f" |
+ sed -e 's/^[^:]*://' -e 's/:.*//'`;;
+ *) touch_files="$touch_files $f.in";;
+ esac
+ done
+ touch $touch_files
;;
- makeinfo*)
- echo "You should only need it if you modified a '.texi' file, or"
- echo "any other file indirectly affecting the aspect of the manual."
- echo "You might want to install the Texinfo package:"
- echo "<$gnu_software_URL/texinfo/>"
- echo "The spurious makeinfo call might also be the consequence of"
- echo "using a buggy 'make' (AIX, DU, IRIX), in which case you might"
- echo "want to install GNU make:"
- echo "<$gnu_software_URL/make/>"
- ;;
- *)
- echo "You might have modified some files without having the proper"
- echo "tools for further handling them. Check the 'README' file, it"
- echo "often tells you about the needed prerequisites for installing"
- echo "this package. You may also peek at any GNU archive site, in"
- echo "case some other package contains this missing '$1' program."
- ;;
- esac
-}
-
-give_advice "$1" | sed -e '1s/^/WARNING: /' \
- -e '2,$s/^/ /' >&2
-
-# Propagate the correct exit status (expected to be 127 for a program
-# not found, 63 for a program that failed due to version mismatch).
-exit $st
+
+ automake*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'.
+ You might want to install the \`Automake' and \`Perl' packages.
+ Grab them from any GNU archive site."
+ find . -type f -name Makefile.am -print |
+ sed 's/\.am$/.in/' |
+ while read f; do touch "$f"; done
+ ;;
+
+ autom4te*)
+ echo 1>&2 "\
+WARNING: \`$1' is needed, but is $msg.
+ You might have modified some files without having the
+ proper tools for further handling them.
+ You can get \`$1' as part of \`Autoconf' from any GNU
+ archive site."
+
+ file=`echo "$*" | sed -n "$sed_output"`
+ test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"`
+ if test -f "$file"; then
+ touch $file
+ else
+ test -z "$file" || exec >$file
+ echo "#! /bin/sh"
+ echo "# Created by GNU Automake missing as a replacement of"
+ echo "# $ $@"
+ echo "exit 0"
+ chmod +x $file
+ exit 1
+ fi
+ ;;
+
+ bison*|yacc*)
+ echo 1>&2 "\
+WARNING: \`$1' $msg. You should only need it if
+ you modified a \`.y' file. You may need the \`Bison' package
+ in order for those modifications to take effect. You can get
+ \`Bison' from any GNU archive site."
+ rm -f y.tab.c y.tab.h
+ if test $# -ne 1; then
+ eval LASTARG=\${$#}
+ case $LASTARG in
+ *.y)
+ SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'`
+ if test -f "$SRCFILE"; then
+ cp "$SRCFILE" y.tab.c
+ fi
+ SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'`
+ if test -f "$SRCFILE"; then
+ cp "$SRCFILE" y.tab.h
+ fi
+ ;;
+ esac
+ fi
+ if test ! -f y.tab.h; then
+ echo >y.tab.h
+ fi
+ if test ! -f y.tab.c; then
+ echo 'main() { return 0; }' >y.tab.c
+ fi
+ ;;
+
+ lex*|flex*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified a \`.l' file. You may need the \`Flex' package
+ in order for those modifications to take effect. You can get
+ \`Flex' from any GNU archive site."
+ rm -f lex.yy.c
+ if test $# -ne 1; then
+ eval LASTARG=\${$#}
+ case $LASTARG in
+ *.l)
+ SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'`
+ if test -f "$SRCFILE"; then
+ cp "$SRCFILE" lex.yy.c
+ fi
+ ;;
+ esac
+ fi
+ if test ! -f lex.yy.c; then
+ echo 'main() { return 0; }' >lex.yy.c
+ fi
+ ;;
+
+ help2man*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified a dependency of a manual page. You may need the
+ \`Help2man' package in order for those modifications to take
+ effect. You can get \`Help2man' from any GNU archive site."
+
+ file=`echo "$*" | sed -n "$sed_output"`
+ test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"`
+ if test -f "$file"; then
+ touch $file
+ else
+ test -z "$file" || exec >$file
+ echo ".ab help2man is required to generate this page"
+ exit $?
+ fi
+ ;;
+
+ makeinfo*)
+ echo 1>&2 "\
+WARNING: \`$1' is $msg. You should only need it if
+ you modified a \`.texi' or \`.texinfo' file, or any other file
+ indirectly affecting the aspect of the manual. The spurious
+ call might also be the consequence of using a buggy \`make' (AIX,
+ DU, IRIX). You might want to install the \`Texinfo' package or
+ the \`GNU make' package. Grab either from any GNU archive site."
+ # The file to touch is that specified with -o ...
+ file=`echo "$*" | sed -n "$sed_output"`
+ test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"`
+ if test -z "$file"; then
+ # ... or it is the one specified with @setfilename ...
+ infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'`
+ file=`sed -n '
+ /^@setfilename/{
+ s/.* \([^ ]*\) *$/\1/
+ p
+ q
+ }' $infile`
+ # ... or it is derived from the source name (dir/f.texi becomes f.info)
+ test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info
+ fi
+ # If the file does not exist, the user really needs makeinfo;
+ # let's fail without touching anything.
+ test -f $file || exit 1
+ touch $file
+ ;;
+
+ *)
+ echo 1>&2 "\
+WARNING: \`$1' is needed, and is $msg.
+ You might have modified some files without having the
+ proper tools for further handling them. Check the \`README' file,
+ it often tells you about the needed prerequisites for installing
+ this package. You may also peek at any GNU archive site, in case
+ some other package would contain this missing \`$1' program."
+ exit 1
+ ;;
+esac
+
+exit 0
# Local variables:
# eval: (add-hook 'write-file-hooks 'time-stamp)
diff --git a/po/af.gmo b/po/af.gmo
index 431f4af..f67e320 100644
--- a/po/af.gmo
+++ b/po/af.gmo
Binary files differ
diff --git a/po/af.po b/po/af.po
index 66d305b..9ec496f 100644
--- a/po/af.po
+++ b/po/af.po
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gettext 0.11.2\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: 2013-01-29 15:06+0200\n"
"Last-Translator: Willem van der Walt <wvdwalt@csir.co.za>>\n"
"Language-Team: Willem van der Walt <wvdwalt@csir.co.za>\n"
@@ -31,12 +31,11 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
# 33
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -46,30 +45,30 @@ msgstr ""
"Kan nie %s lees nie\n"
# 5
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "'h' vir hulp -"
# 1
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d bladsye "
# 3
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " vlak: %d van %d "
# 4
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " totale lengte: %02d:%02d:%02d "
# 38
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -78,57 +77,57 @@ msgstr ""
"Hierdie bevele is beskikbaar in hierdie weergawe:\n"
# 41
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "Af peiltjie - skuif die loper na die volgende item\n"
# 44
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "op peiltjie - skuif die loper na die vorige item\n"
# 43
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "regs peiltjie - spring na die volgende frase toe\n"
# 42
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "links peiltjie - spring na die vorige frase toe\n"
# 57
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "page-down - wys die volgende bladsy\n"
# 58
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "page-up - wys die vorige bladsy\n"
# 46
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "enter - begin speel\n"
# 62
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "spasie - stop tydelik/hervat terugspeel\n"
# 50
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "home - speel teen normale spoed\n"
# 23
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Druk enige sleutel vir die volgende bladsy..."
# 32
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -137,17 +136,17 @@ msgstr ""
"/ - soek vir 'n ettiket\n"
# 45
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - stoor huidige item op skyf\n"
# 11
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - verlaag terugspeelspoed\n"
# 47
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
@@ -155,72 +154,72 @@ msgstr ""
"f - Kry die item wat nou speel en skuif die loper daarheen\n"
# 48
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - gaan na bladsynommer\n"
# 48
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr "g - gaan na tyd\n"
# 49
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h of ? - wys hierdie help-bladsy\n"
# 51
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - speel net die huidige item\n"
# 52
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - verander na die volgende vlak\n"
# 16
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L - verander na die vorige vlak\n"
# 53
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - soek vorentoe\n"
# 18
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N - soek agteruit\n"
# 55
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o - kies die volgende klankkaart\n"
# 56
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - maak 'n boekmerk\n"
# 59
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - stop daisy-player en maak 'n boekmerk\n"
# 60
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - hou op speel\n"
# 29
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U - verhoog terugspeelspoed\n"
# 37
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -229,39 +228,39 @@ msgstr ""
"Druk enige sleutel om die help-skerm te verlaat..."
# 20
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Wag asseblief... -----------------------"
# 30
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "Wat soek u? "
# 15
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Gaan na bladsynommer: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr "gaan na tyd: (mm:ss): "
# 34
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr ""
"Kan nie /proc/asound/cards lees nie.\n"
"Kan nie /proc/mounts lees nie."
# 13
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - weergawe %s\n"
# 39
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -270,13 +269,13 @@ msgstr ""
"\n"
"Gebruiksaanwysings: %s [directory met 'n Daisy-struktuur] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c cdrom_toestel] [-d ALSA_klank_toestel] [-n | -y]\n"
# 34
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -285,48 +284,15 @@ msgstr ""
"Kan nie /proc/mounts lees nie."
# 6
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr "'n program om Daisy CD's in Linux te speel\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player het die \"eject\" program nodig.\n"
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr "Installeer dit asseblief en probeer weer.\n"
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player het die \"madplay\" program nodig.\n"
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr "Besig om vir 'n DAISY CD te soek..."
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player het die \"unar\" program nodig.\n"
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
@@ -335,45 +301,36 @@ msgstr ""
"\n"
"Geen DAISY CD of audio CD is gekry nie\n"
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player het die \"udisksctl\" program nodig.\n"
+# 36
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "Daar is nie 'n daisy-cd in die CD speler nie."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
msgstr ""
"\n"
-"Audio CD gekry"
+"Audio CD gekry. "
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr "besig om tietels vanaf freedb.freedb.org te kry..."
-# 36
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "Daar is nie 'n daisy-cd in die CD speler nie."
-
# 12
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - weergawe %s - (C)2014 J. Lemmens"
# 22
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "Druk 'h' vir hulp "
# 33
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
@@ -382,6 +339,37 @@ msgstr ""
"\n"
"Kan nie type %d lees nie\n"
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"unar\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player het die \"unar\" program nodig.\n"
+
+#~ msgid "Please install it and try again.\n"
+#~ msgstr "Installeer dit asseblief en probeer weer.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"eject\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player het die \"eject\" program nodig.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"madplay\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player het die \"madplay\" program nodig.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"udisksctl\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player het die \"udisksctl\" program nodig.\n"
+
# 35
#~ msgid ""
#~ "\n"
diff --git a/po/daisy-player.pot b/po/daisy-player.pot
index 3d70fab..d220716 100644
--- a/po/daisy-player.pot
+++ b/po/daisy-player.pot
@@ -6,9 +6,9 @@
#, fuzzy
msgid ""
msgstr ""
-"Project-Id-Version: daisy-player 8.6\n"
+"Project-Id-Version: daisy-player 8.6.1\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"
@@ -17,277 +17,242 @@ msgstr ""
"Content-Type: text/plain; charset=CHARSET\n"
"Content-Transfer-Encoding: 8bit\n"
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
"Cannot read %s\n"
msgstr ""
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr ""
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr ""
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr ""
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr ""
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
msgstr ""
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr ""
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr ""
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr ""
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr ""
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr ""
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr ""
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr ""
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr ""
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr ""
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr ""
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
msgstr ""
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr ""
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr ""
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
msgstr ""
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr ""
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr ""
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr ""
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr ""
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr ""
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr ""
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr ""
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr ""
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr ""
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr ""
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr ""
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr ""
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr ""
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
msgstr ""
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr ""
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr ""
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr ""
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr ""
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr ""
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr ""
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
"Usage: %s [directory_with_a_Daisy-structure] "
msgstr ""
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr ""
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
msgstr ""
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr ""
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr ""
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr ""
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
"No DAISY-CD or Audio-cd found\n"
msgstr ""
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
msgstr ""
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
msgstr ""
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr ""
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr ""
-
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr ""
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr ""
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
diff --git a/po/de.gmo b/po/de.gmo
index 0656d17..87ddfee 100644
--- a/po/de.gmo
+++ b/po/de.gmo
Binary files differ
diff --git a/po/de.po b/po/de.po
index 9c051ba..d69572e 100644
--- a/po/de.po
+++ b/po/de.po
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gettext 0.11.2\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: 2013-01-29 15:06+0200\n"
"Last-Translator: Klaus Knopper <knopper@knopper.net>\n"
"Language-Team: Klaus Knopper <knopper@knopper.net>\n"
@@ -31,12 +31,11 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
# 33
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -46,30 +45,30 @@ msgstr ""
"Kann %s nicht lesen\n"
# 5
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "'h' hilfe ---"
# 1
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d Seiten "
# 3
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " Level: %d von %d "
# 4
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " Gesamtlänge: %02d:%02d:%02d "
# 38
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -78,58 +77,58 @@ msgstr ""
"Folgende Befehle sind in dieser Version vorhanden:\n"
# 41
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "Pfeil runter - verschiebt den Cursor auf das nächste Element\n"
# 44
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr ""
"Pfeil hoch - verschiebt den Cursor auf das vorhergehende Element\n"
# 43
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "Pfeil rechts - springe zur nächsten Phrase\n"
# 42
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "Pfeil links - springe zur vorhergehenden Phrase\n"
# 57
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "Seite runter - zur nächsten Seite\n"
# 58
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "Seite hoch - zur vorigen Seite\n"
# 46
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "Eingabetaste - abspielen\n"
# 62
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "Leertaste - Pause-/Weiter\n"
# 50
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "home - spiele mit normaler Geschwindigkeit\n"
# 23
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Taste drücken für nächste Seite..."
# 32
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -138,17 +137,17 @@ msgstr ""
"/ - suche nach einem Begriff\n"
# 45
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - Aktuelles Element speichern\n"
# 11
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - verringere Abspielgeschwindigkeit\n"
# 47
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
@@ -157,72 +156,72 @@ msgstr ""
"platzieren\n"
# 48
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - zur Seitenzahl gehen (falls vorhanden)\n"
# 48
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr ""
# 49
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h oder ? - diese Hilfe anzeigen\n"
# 51
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - nur das aktuelle Element abspielen\n"
# 52
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - zum nächsten Level wechseln\n"
# 16
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L - zum vorigen Level wechseln\n"
# 53
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - Suche vorwärts\n"
# 18
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N - Suche rückwärts\n"
# 55
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o - nächstes sound device für Ausgabe wählen\n"
# 56
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - Lesezeichen setzen\n"
# 59
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - Daisy-Player verlassen und Lesezeichen setzen\n"
# 60
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - Abspielen stoppen\n"
# 29
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U - erhöhe Abspielgeschwindigkeit\n"
# 37
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -231,37 +230,37 @@ msgstr ""
"Taste drücken, um die Hilfe zu verlassen..."
# 20
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Bitte warten... ------------------------"
# 30
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "Suchen nach...? "
# 15
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Gehe zur Seitenzahl: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr ""
# 34
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "Kann /proc/mounts nicht lesen"
# 13
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - Version %s\n"
# 39
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -270,13 +269,13 @@ msgstr ""
"\n"
"Aufruf: %s [Verzeichnis mit einer Daisy-Struktur] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c cdrom_device] [-d ALSA Soundkarte] [-n | -y]\n"
# 34
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -285,83 +284,49 @@ msgstr ""
"Kann /proc/mounts nicht lesen."
# 6
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr "Ein Programm, um Daisy CDs unter Linux abzuspielen\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr ""
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr ""
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
"No DAISY-CD or Audio-cd found\n"
msgstr ""
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
+# 36
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "Keine Daisy-CD im Laufwerk."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
msgstr ""
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr ""
-# 36
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "Keine Daisy-CD im Laufwerk."
-
# 12
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - Version %s - (C)2014 J. Lemmens"
# 22
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "'h' für Hilfe drücken"
# 33
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
diff --git a/po/en@boldquot.gmo b/po/en@boldquot.gmo
index eb9dab2..b750e27 100644
--- a/po/en@boldquot.gmo
+++ b/po/en@boldquot.gmo
Binary files differ
diff --git a/po/en@boldquot.po b/po/en@boldquot.po
index fa79a2b..150b8be 100644
--- a/po/en@boldquot.po
+++ b/po/en@boldquot.po
@@ -30,10 +30,10 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: daisy-player 8.6\n"
+"Project-Id-Version: daisy-player 8.6.1\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
-"PO-Revision-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
+"PO-Revision-Date: 2014-06-19 15:50+0200\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Language: en@boldquot\n"
@@ -42,12 +42,11 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -56,26 +55,26 @@ msgstr ""
"\n"
"Cannot read %s\n"
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "‘h’ for help -"
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d pages "
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " level: %d of %d "
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " total length: %02d:%02d:%02d "
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -83,47 +82,47 @@ msgstr ""
"\n"
"These commands are available in this version:\n"
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "cursor down - move cursor to the next item\n"
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "cursor up - move cursor to the previous item\n"
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "cursor right - skip to next phrase\n"
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "cursor left - skip to previous phrase\n"
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "page-down - view next page\n"
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "page-up - view previous page\n"
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "enter - start playing\n"
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "space - pause/resume playing\n"
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "home - play on normal speed\n"
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Press any key for next page..."
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -131,15 +130,15 @@ msgstr ""
"\n"
"/ - search for a label\n"
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - store current item to disk\n"
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - decrease playing speed\n"
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
@@ -147,59 +146,59 @@ msgstr ""
"f - find the currently playing item and place the cursor "
"there\n"
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - go to page number (if any)\n"
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr "g - go to time in this song (MM:SS)\n"
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h or ? - give this help\n"
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - just play current item\n"
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - switch to next level\n"
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L - switch to previous level\n"
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - search forwards\n"
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N - search backwards\n"
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o - select next output sound device\n"
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - place a bookmark\n"
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - quit daisy-player and place a bookmark\n"
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - stop playing\n"
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U - increase playing speed\n"
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -207,32 +206,32 @@ msgstr ""
"\n"
"Press any key to leave help..."
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Please wait... -------------------------"
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "What do you search? "
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Go to page number: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr "Go to time (MM:SS): "
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "Cannot read /proc/asound/cards"
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - Version %s\n"
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -241,12 +240,12 @@ msgstr ""
"\n"
"Usage: %s [directory_with_a_Daisy-structure] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -254,48 +253,15 @@ msgstr ""
"\n"
"Cannot read /proc/mounts."
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr "A parser to play Daisy CD's with Linux\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player needs the “eject” programme.\n"
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr "Please install it and try again.\n"
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player needs the “madplay” programme.\n"
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr "Scanning for a Daisy CD..."
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player needs the “unar” programme.\n"
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
@@ -304,16 +270,11 @@ msgstr ""
"\n"
"No DAISY-CD or Audio-cd found\n"
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player needs the “udisksctl” programme.\n"
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "No Daisy CD in drive."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
@@ -321,24 +282,20 @@ msgstr ""
"\n"
"Found an Audio-CD. "
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr "Get titles from freedb.freedb.org..."
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "No Daisy CD in drive."
-
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - Version %s - (C)2014 J. Lemmens"
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "Press ‘h’ for help "
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
diff --git a/po/en@quot.gmo b/po/en@quot.gmo
index 55df809..e5f7f9e 100644
--- a/po/en@quot.gmo
+++ b/po/en@quot.gmo
Binary files differ
diff --git a/po/en@quot.po b/po/en@quot.po
index c973b1a..c68bf36 100644
--- a/po/en@quot.po
+++ b/po/en@quot.po
@@ -27,10 +27,10 @@
#
msgid ""
msgstr ""
-"Project-Id-Version: daisy-player 8.6\n"
+"Project-Id-Version: daisy-player 8.6.1\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
-"PO-Revision-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
+"PO-Revision-Date: 2014-06-19 15:50+0200\n"
"Last-Translator: Automatically generated\n"
"Language-Team: none\n"
"Language: en@quot\n"
@@ -39,12 +39,11 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -53,26 +52,26 @@ msgstr ""
"\n"
"Cannot read %s\n"
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "‘h’ for help -"
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d pages "
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " level: %d of %d "
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " total length: %02d:%02d:%02d "
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -80,47 +79,47 @@ msgstr ""
"\n"
"These commands are available in this version:\n"
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "cursor down - move cursor to the next item\n"
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "cursor up - move cursor to the previous item\n"
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "cursor right - skip to next phrase\n"
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "cursor left - skip to previous phrase\n"
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "page-down - view next page\n"
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "page-up - view previous page\n"
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "enter - start playing\n"
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "space - pause/resume playing\n"
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "home - play on normal speed\n"
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Press any key for next page..."
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -128,15 +127,15 @@ msgstr ""
"\n"
"/ - search for a label\n"
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - store current item to disk\n"
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - decrease playing speed\n"
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
@@ -144,59 +143,59 @@ msgstr ""
"f - find the currently playing item and place the cursor "
"there\n"
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - go to page number (if any)\n"
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr "g - go to time in this song (MM:SS)\n"
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h or ? - give this help\n"
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - just play current item\n"
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - switch to next level\n"
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L - switch to previous level\n"
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - search forwards\n"
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N - search backwards\n"
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o - select next output sound device\n"
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - place a bookmark\n"
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - quit daisy-player and place a bookmark\n"
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - stop playing\n"
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U - increase playing speed\n"
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -204,32 +203,32 @@ msgstr ""
"\n"
"Press any key to leave help..."
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Please wait... -------------------------"
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "What do you search? "
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Go to page number: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr "Go to time (MM:SS): "
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "Cannot read /proc/asound/cards"
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - Version %s\n"
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -238,12 +237,12 @@ msgstr ""
"\n"
"Usage: %s [directory_with_a_Daisy-structure] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -251,48 +250,15 @@ msgstr ""
"\n"
"Cannot read /proc/mounts."
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr "A parser to play Daisy CD's with Linux\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player needs the “eject” programme.\n"
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr "Please install it and try again.\n"
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player needs the “madplay” programme.\n"
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr "Scanning for a Daisy CD..."
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player needs the “unar” programme.\n"
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
@@ -301,16 +267,11 @@ msgstr ""
"\n"
"No DAISY-CD or Audio-cd found\n"
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player needs the “udisksctl” programme.\n"
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "No Daisy CD in drive."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
@@ -318,24 +279,20 @@ msgstr ""
"\n"
"Found an Audio-CD. "
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr "Get titles from freedb.freedb.org..."
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "No Daisy CD in drive."
-
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - Version %s - (C)2014 J. Lemmens"
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "Press ‘h’ for help "
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
diff --git a/po/es.gmo b/po/es.gmo
index c8ff838..6db34ba 100644
--- a/po/es.gmo
+++ b/po/es.gmo
Binary files differ
diff --git a/po/es.po b/po/es.po
index e7627de..62fb48b 100644
--- a/po/es.po
+++ b/po/es.po
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gettext 0.11.2\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: 2013-01-29 15:06+0200\n"
"Last-Translator: Hanna Tulleken <hannatulleken@gmail.com>\n"
"Language-Team: Hanna Tulleken <hannatulleken@gmail.com>\n"
@@ -30,12 +30,11 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -44,26 +43,26 @@ msgstr ""
"\n"
"No poder leer %s\n"
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "'h' para ayudar-"
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d páginas"
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " nivel: %d of %d "
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " total longitud: %02d:%02d:%02d "
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -71,47 +70,47 @@ msgstr ""
"\n"
"Estas orden estan disponibles en esta versión:\n"
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "cursor abajo - desplazar el cursor hasta el tema próximo\n"
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "cursor arriba - desplazar el cursor para el tema anterior\n"
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "cursor derecho - saltar para la frase próxima\n"
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "cursor izquierdo - saltar para la frase anterior\n"
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "página - abaja - ver página proxima\n"
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "página-ariba - ver página anterior\n"
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "entrar - empezar escuchar\n"
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "espacio - pausa/reanudar escuchar\n"
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "inicio - escuchar a velocidad normal\n"
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Hacer clic cada tecla por la página proxima..."
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -119,75 +118,75 @@ msgstr ""
"\n"
"/ - buscar por una etiqueta\n"
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - almacenar el tema actual en disk\n"
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - disminuir velocidad de escuchar\n"
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
msgstr ""
"f - encontrar el item escuchando y poner el cursor allí\n"
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - ir para página número (cuando hay)\n"
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr "g - ir para tiempo en este canción (MM:SS)\n"
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h o ? - dar esta ayuda\n"
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - solo escuchar el tema actual\n"
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - gambiar al nivél proxima\n"
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L - gambiar al nivél antes\n"
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - buscar adelante\n"
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N - buscar atrás\n"
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr ""
"o - seleccionar la proxima salida de dispositivo sonido\n"
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - poner una marcapágina\n"
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - dejar daisy-player y poner una marcapágina\n"
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - parar escuchar\n"
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U - acelerar velocidad de escuchar\n"
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -195,32 +194,32 @@ msgstr ""
"\n"
"Hacer click alguna tecla para salir ayudar..."
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Por favor esperar... -------------------------"
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "¿Qué buscas? "
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Ir a página número: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr "Ir para tiempo (MM:SS): "
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "No poder leer /proc/sólido/fichas"
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - Versión %s\n"
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -229,12 +228,12 @@ msgstr ""
"\n"
"Uso: %s [manual_con_una_Daisy-estructura] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c cdrom_dispositivo] [-d ALSA_sonido_dispositivo] [-n | -y] \n"
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -242,48 +241,15 @@ msgstr ""
"\n"
"No poder leer /proc/mounts."
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr "Un analizador para escuchar Daisy CD con Linux\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player necesita la \"eject\" programa.\n"
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr "Por favor instalar y probar otra vez.\n"
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player necesita la \"madplay\" programa.\n"
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr "Explorar para un Daisy CD..."
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player necesita la \"unar\" programa.\n"
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
@@ -292,16 +258,11 @@ msgstr ""
"\n"
"No encontrada DAISY-CD o Audio-cd\n"
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player necesita la \"udisksctl\" programa.\n"
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "No hay Daisy-CD en el unidad."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
@@ -309,24 +270,20 @@ msgstr ""
"\n"
"Encontrada un Audio-CD. "
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr "Coger títulos de freedb.freedb.org..."
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "No hay Daisy-CD en el unidad."
-
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - Versión %s - (C)2014 J. Lemmens"
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "Hacer clic 'h' para ayudar "
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
@@ -337,6 +294,37 @@ msgstr ""
#~ msgid ""
#~ "\n"
+#~ "Daisy-player needs the \"unar\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player necesita la \"unar\" programa.\n"
+
+#~ msgid "Please install it and try again.\n"
+#~ msgstr "Por favor instalar y probar otra vez.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"eject\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player necesita la \"eject\" programa.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"madplay\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player necesita la \"madplay\" programa.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"udisksctl\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player necesita la \"udisksctl\" programa.\n"
+
+#~ msgid ""
+#~ "\n"
#~ "Cannot use udisksctl command."
#~ msgstr ""
#~ "\n"
diff --git a/po/fr.gmo b/po/fr.gmo
index 713f5e4..625123a 100644
--- a/po/fr.gmo
+++ b/po/fr.gmo
Binary files differ
diff --git a/po/fr.po b/po/fr.po
index 5f3cb22..f1559b1 100644
--- a/po/fr.po
+++ b/po/fr.po
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gettext 0.11.2\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: 2013-01-29 15:06+0200\n"
"Last-Translator: Osvaldo La Rosa aka Aldo <aldo.nospam@scarlet.be>\n"
"Language-Team: Osvaldo La Rosa aka Aldo <aldo.nospam@scarlet.be>\n"
@@ -31,12 +31,11 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
# 33
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -46,30 +45,30 @@ msgstr ""
"Ne sait pas lire %s\n"
# 5
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "'h' pour obtenir de l'aide"
# 1
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d pages "
# 3
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " niveau: %d de %d "
# 4
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " durée totale: %02d:%02d:%02d "
# 38
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -78,57 +77,57 @@ msgstr ""
"Ces commandes sont disponibles dans cette version:\n"
# 41
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "curseur bas - déplacez le curseur vers l'élément suivant\n"
# 44
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "curseur haut - déplacez le curseur vers l'élément précédent\n"
# 43
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "curseur droit - aller à la phrase suivante\n"
# 42
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "curseur gauche - revenir à la phrase précédente\n"
# 57
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "page bas - affichez la page suivante\n"
# 58
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "page haut - affichez la page précédente\n"
# 46
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "enter - démarrer l'audition\n"
# 62
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "espace - pause/poursuivre la diffusion\n"
# 50
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "home - diffuser à la vitesse normale\n"
# 23
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Appuyez sur une touche pour aller à la page suivante..."
# 32
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -137,17 +136,17 @@ msgstr ""
"/ - cherche label\n"
# 45
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - sauvegardez l'élément courant sur disque dur\n"
# 11
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - décélérer la vitesse de diffusion\n"
# 47
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
@@ -156,72 +155,72 @@ msgstr ""
"curseur\n"
# 48
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - allez à la page numéro\n"
# 48
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr ""
# 49
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h ou ? - affichez cette page d'aide\n"
# 51
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - diffusez uniquement l'élément courant\n"
# 52
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - allez au niveau suivant\n"
# 16
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L - remonter au niveau précédent\n"
# 53
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - recherche sur la suite\n"
# 18
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N - recherche inverse\n"
# 55
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o - sélectionnez la carte son\n"
# 56
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - placez un marqueur\n"
# 59
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - quittez daisy-player et placez un marqueur\n"
# 60
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - arrêtez la diffusion\n"
# 29
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U - accélérer la vitesse de diffusion\n"
# 37
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -230,37 +229,37 @@ msgstr ""
"Appuyez sur une touche pour quitter l'aide..."
# 20
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Un instant svp... -----------------------"
# 30
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "Que recherchez-vous? "
# 15
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Aller à la page numéro : "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr ""
# 34
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "Ne sait pas lire /proc/mounts."
# 13
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - Version %s\n"
# 39
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -269,13 +268,13 @@ msgstr ""
"\n"
"Utilisation: %s [-l langue] [répertoire avec structure Daisy] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr ""
# 34
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -284,83 +283,49 @@ msgstr ""
"Ne sait pas lire /proc/mounts."
# 6
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr "Une application pour écouter des CD's Daisy sous Linux\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr ""
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr ""
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
"No DAISY-CD or Audio-cd found\n"
msgstr ""
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
+# 36
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "Pas de cd daisy dans le lecteur."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
msgstr ""
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr ""
-# 36
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "Pas de cd daisy dans le lecteur."
-
# 12
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - Version %s - (C)2014 J. Lemmens"
# 22
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "Appuyez sur 'h' pour obtenir de l'aide "
# 33
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
diff --git a/po/hu.gmo b/po/hu.gmo
index f77af58..35504d5 100644
--- a/po/hu.gmo
+++ b/po/hu.gmo
Binary files differ
diff --git a/po/hu.po b/po/hu.po
index 1842a45..87edbb2 100644
--- a/po/hu.po
+++ b/po/hu.po
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gettext 0.11.2\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: 2013-12-09 11:06+0200\n"
"Last-Translator: Hammer Attila <hammera@pickup.hu>\n"
"Language-Team: Hammer Attila <hammera@pickup.hu>\n"
@@ -30,12 +30,11 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -44,26 +43,26 @@ msgstr ""
"\n"
"A(z) %s nem olvasható\n"
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "h =segítség"
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " Oldalak száma: %d "
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " %d szint a %d szintből "
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " Összidő: %02d:%02d:%02d "
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -71,47 +70,47 @@ msgstr ""
"\n"
"A következő parancsok érhetők el ebben a verzióban:\n"
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "Le: a kurzor mozgatása a következő elemre\n"
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "Fel: a kurzor mozgatása az előző elemre\n"
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "Jobbra: a következő kifejezés kihagyása\n"
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "Balra: az előző kifejezés kihagyása\n"
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "PAGEDOWN: a következő oldal megtekintése\n"
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "PAGEUP: az előző oldal megtekintése\n"
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "ENTER: a lejátszás megkezdése\n"
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "SZÓKÖZ: a lejátszás szüneteltetése és folytatása\n"
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "HOME: lejátszás normál sebességgel\n"
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "A következő oldalra lépéshez nyomjon meg egy billentyűt..."
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -119,15 +118,15 @@ msgstr ""
"\n"
"/: egy címke keresése\n"
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d: az aktuális elem tárolása a lemezre\n"
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D: lejátszás sebességének csökkentése\n"
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
@@ -135,61 +134,61 @@ msgstr ""
"f: az aktuálisan játszott elem helyének megkeresése, és a kurzor elhelyezése "
"az elem helyére\n"
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr ""
"g: ugrás egy megadott oldalra, ha a Daisy könyv tartalmaz oldalszámokat\n"
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr "g: ugrás egy megadott időre a zeneszámon belül\n"
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h: a súgó megjelenítése\n"
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j: az aktuális elem újbóli lejátszása\n"
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l: váltás a következő szintre\n"
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L: váltás az előző szintre\n"
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n: a következő kifejezés keresése\n"
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N: az előző kifejezés keresése\n"
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o: a következő hangeszköz kiválasztása\n"
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p: könyvjelző elhelyezése\n"
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr ""
"q: kilépés a Daisy lejátszóból. A kilépéskor könyvjelző kerül elhelyezésre\n"
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s: a lejátszás leállítása\n"
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U: lejátszás sebességének növelése\n"
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -197,32 +196,32 @@ msgstr ""
"\n"
"A súgó elhagyásához nyomjon meg egy billentyűt..."
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Kérem várjon..."
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "Mit keres? "
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Ugrás a megadott oldalra: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr "Ugrás egy megadott időtartamra: "
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "A /proc/asound/cards fájl nem olvasható."
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - %s verzió\n"
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -231,12 +230,12 @@ msgstr ""
"\n"
"Használat: %s [Daisy szerkezetet tartalmazó könyvtár] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c CD-rom eszköz] [-d ALSA hangeszköz] [-n|-y]\n"
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -244,50 +243,17 @@ msgstr ""
"\n"
"A /proc csatolások nem olvashatók."
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr ""
"Egy feldolgozó program, melynek segítségével Daisy könyveket játszhat le "
"Linux alatt\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-"\n"
-"A Daisy-playernek szüksége van az eject programra.\n"
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr "Telepítse a megadott csomagot, majd próbálja meg újra.\n"
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-"\n"
-"A Daisy-playernek szüksége van a Madplay programra.\n"
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr "DAISY CD keresése..."
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-"\n"
-"A Daisy-playernek szüksége van az unar programra.\n"
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
@@ -296,16 +262,11 @@ msgstr ""
"\n"
"Nem található DAISY CD vagy audio CD a meghajtóban.\n"
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
-"\n"
-"A Daisy-playernek szüksége van az udisksctl programra.\n"
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "A meghajtóban nincs Daisy lemez."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
@@ -313,24 +274,20 @@ msgstr ""
"\n"
"Az audio CD megtalálva. "
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr "A számcímek lekérése a freedb.freedb.org kiszolgálóról..."
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "A meghajtóban nincs Daisy lemez."
-
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - %s verzió - (C)2014 J. Lemmens"
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "A segítségért nyomja meg a H billentyűt. "
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
@@ -341,6 +298,37 @@ msgstr ""
#~ msgid ""
#~ "\n"
+#~ "Daisy-player needs the \"unar\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "A Daisy-playernek szüksége van az unar programra.\n"
+
+#~ msgid "Please install it and try again.\n"
+#~ msgstr "Telepítse a megadott csomagot, majd próbálja meg újra.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"eject\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "A Daisy-playernek szüksége van az eject programra.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"madplay\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "A Daisy-playernek szüksége van a Madplay programra.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"udisksctl\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "A Daisy-playernek szüksége van az udisksctl programra.\n"
+
+#~ msgid ""
+#~ "\n"
#~ "Cannot use udisksctl command."
#~ msgstr ""
#~ "\n"
diff --git a/po/nb.gmo b/po/nb.gmo
index 2289aed..14758b9 100644
--- a/po/nb.gmo
+++ b/po/nb.gmo
Binary files differ
diff --git a/po/nb.po b/po/nb.po
index b2bbc65..0cff7e2 100644
--- a/po/nb.po
+++ b/po/nb.po
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gettext 0.11.2\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: 2013-01-29 15:06+0200\n"
"Last-Translator: Ellen <ellenrohaan@hotmail.com>\n"
"Language-Team: Ellen <ellenrohaan@hotmail.com>\n"
@@ -30,12 +30,11 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -44,26 +43,26 @@ msgstr ""
"\n"
"Kan ikke lese %s\n"
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "'h' for hjelp -"
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d sider "
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " nivå: %d of %d "
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " total lengde: %02d:%02d:%02d "
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -71,47 +70,47 @@ msgstr ""
"\n"
"Disse kommandoer er tilgjengelig i denne versjon:\n"
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "markør ned - flytt markør til neste element\n"
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "markør opp - flytt markør til forrige element\n"
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "markør til høyre - hopp over til neste settning\n"
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "markør til venstre - hopp over til forrige settning\n"
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "page-down - viser neste side\n"
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "page-up - viser forrige side\n"
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "enter - begynner å spille\n"
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "space - pauserer/gjennopptar spilling\n"
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "home - spiller på normal tempo\n"
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Trykk en tilfeldig knapp for neste side..."
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -119,74 +118,74 @@ msgstr ""
"\n"
"/ - søker en etikett\n"
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - oppbevarer gjeldende element til disk\n"
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - reduserer spille tempo\n"
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
msgstr ""
"f - finner den spillende elementen og plasserer markøren der\n"
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - går til sidenummer (hvis det finnes)\n"
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr "g - går til tidspunkt i denne sangen (MM:SS)\n"
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h or ? - viser hjelp\n"
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - spiller gjeldende element\n"
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - går til neste nivå\n"
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L - gå til forrige nivål\n"
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - søker framover\n"
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N - søker omvendt\n"
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o - selekterer neste lydkart\n"
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - lager en bokmerke\n"
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - avslutter daisy-player og lager en bokmerke\n"
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - stopper å spille\n"
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U - øker spille tempo\n"
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -194,32 +193,32 @@ msgstr ""
"\n"
"Trykk en tilfeldig knapp for å forlate hjelp..."
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Vennligst vent.. -------------------------"
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "Hva søker du? "
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Gå til side nummer: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr "Gå til tidspunktet (MM:SS): "
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "Kan ikke lese /proc/asound/cards"
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - Versjon %s\n"
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -228,12 +227,12 @@ msgstr ""
"\n"
"Forbruk: %s [mappe_med_Daisy-struktur] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c cdrom_apparat] [-d ALSA_lyd_apparat] [-n | -y]\n"
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -241,48 +240,15 @@ msgstr ""
"\n"
"Kan ikke lese /proc/mounts."
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr "Et program for å spille Daisy CD's med Linux\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player trenger \"eject\" programmet.\n"
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr "Vennligst installer og prøv igjen.\n"
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player trenger \"madplay\" programmet.\n"
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr "Søker etter en Daisy CD..."
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player trenger \"unar\" programmet.\n"
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
@@ -291,16 +257,11 @@ msgstr ""
"\n"
"Ingen DAISY-CD eller Lyd-cd funnet\n"
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player trenger \"udisksctl\" programmet.\n"
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "Ingen Daisy-cd i spillern."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
@@ -308,24 +269,20 @@ msgstr ""
"\n"
"Funnet en Lyd-CD. "
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr "Henter titler fra freedb.freedb.org..."
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "Ingen Daisy-cd i spillern."
-
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - Versjon %s - (C)2014 J. Lemmens"
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "Trykk 'h' for hjelp "
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
@@ -336,6 +293,37 @@ msgstr ""
#~ msgid ""
#~ "\n"
+#~ "Daisy-player needs the \"unar\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player trenger \"unar\" programmet.\n"
+
+#~ msgid "Please install it and try again.\n"
+#~ msgstr "Vennligst installer og prøv igjen.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"eject\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player trenger \"eject\" programmet.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"madplay\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player trenger \"madplay\" programmet.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"udisksctl\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player trenger \"udisksctl\" programmet.\n"
+
+#~ msgid ""
+#~ "\n"
#~ "Cannot use udisksctl command."
#~ msgstr ""
#~ "\n"
diff --git a/po/nl.gmo b/po/nl.gmo
index ae53051..bc00511 100644
--- a/po/nl.gmo
+++ b/po/nl.gmo
Binary files differ
diff --git a/po/nl.po b/po/nl.po
index a631ff1..61714bb 100644
--- a/po/nl.po
+++ b/po/nl.po
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gettext 0.11.2\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: 2013-01-29 15:06+0200\n"
"Last-Translator: Jos Lemmens <jos@jlemmens.nl>\n"
"Language-Team: Jos Lemmens <jos@jlemmens.nl>\n"
@@ -31,12 +31,11 @@ msgstr ""
"Content-Transfer-Encoding: 8bit\n"
# 33
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -46,30 +45,30 @@ msgstr ""
"Kan %s niet lezen\n"
# 5
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "'h' voor hulp -"
# 1
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d pagina's "
# 3
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " niveau: %d - %d "
# 4
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " totale lengte %02d:%02d:%02d "
# 38
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -78,57 +77,57 @@ msgstr ""
"Deze commando's zijn beschikbaar in deze versie\n"
# 41
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "cursor omlaag - verplaats de cursor naar het volgende item\n"
# 44
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "cursor omhoog - verplaats de cursor naar het vorige item\n"
# 43
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "cursor rechts - spring naar de volgende frase\n"
# 42
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "cursor links - spring naar de vorige frase\n"
# 57
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "page-down - toon de volgende pagina\n"
# 58
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "page-up - toon de vorige pagina\n"
# 46
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "enter - start afspelen\n"
# 62
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "spatie - pauze/vervolg het afspelen\n"
# 50
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "home - speel af op normale snelheid\n"
# 23
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Druk op een toets voor de volgende pagina..."
# 32
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -137,17 +136,17 @@ msgstr ""
"/ - zoek label\n"
# 45
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - sla huidige item op op schijf\n"
# 11
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - verlaag afspeel snelheid\n"
# 47
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
@@ -155,72 +154,72 @@ msgstr ""
"f - vindt het huidige spelende item en plaats de cursor daar\n"
# 48
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - ga naar pagina nummer\n"
# 48
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr "g - ga naar tijd in dit lied\n"
# 49
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h of ? - toon deze help-pagina\n"
# 51
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - speel alleen dit item af\n"
# 52
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - schakel naar het volgende niveau\n"
# 16
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "L - schakel naar het vorige niveau\n"
# 53
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - zoek voorwaarts\n"
# 18
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "N - zoek achteruit\n"
# 55
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o - selecteer de volgende geluidskaart\n"
# 56
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - plaats een boekenlegger\n"
# 59
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - stop daisy-player en plaats een boekenlegger\n"
# 60
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - stop het afspelen\n"
# 29
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "U - verhoog afspeel snelheid\n"
# 37
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -229,37 +228,37 @@ msgstr ""
"Druk op een toets om dit help-scherm te verlaten..."
# 20
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Even geduld a.u.b.... ------------------"
# 30
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "Wat zoekt u? "
# 15
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Ga naar pagina nummer: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr "Ga naar tijd (MM:SS): "
# 34
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "Kan /proc/asound/cards niet lezen."
# 13
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - Versie %s\n"
# 39
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -268,13 +267,13 @@ msgstr ""
"\n"
"Gebruik: %s [map met een Daisy-structuur] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c cdrom_apparaat] [-d ALSA_geluids_apparaat] [-n | -j]\n"
# 34
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -283,48 +282,15 @@ msgstr ""
"Kan /proc/mounts niet lezen."
# 6
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr "Een programma om Daisy CD's af te spelen\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player heeft het \"eject\" programma nodig.\n"
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr "Installeer het a.u.b. en probeer het opnieuw.\n"
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player heeft het \"madplay\" programma nodig.\n"
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr "Zoeken naar een Daisy CD..."
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player heeft het \"unar\" programma nodig.\n"
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
@@ -333,16 +299,12 @@ msgstr ""
"\n"
"Geen DAISY-CD of Audio-cd gevonden\n"
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player heeft het \"udisksctl\" programma nodig.\n"
+# 36
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "Geen daisy-cd in speler."
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
@@ -350,28 +312,23 @@ msgstr ""
"\n"
"Een Audio-CD gevonden. "
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr "Haal de titels op bij freedb.freedb.org..."
-# 36
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "Geen daisy-cd in speler."
-
# 12
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - Versie %s - (C)2014 J. Lemmens"
# 22
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "Druk op'h' voor hulp "
# 33
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
@@ -380,6 +337,37 @@ msgstr ""
"\n"
"Kan het type %d niet lezen\n"
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"unar\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player heeft het \"unar\" programma nodig.\n"
+
+#~ msgid "Please install it and try again.\n"
+#~ msgstr "Installeer het a.u.b. en probeer het opnieuw.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"eject\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player heeft het \"eject\" programma nodig.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"madplay\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player heeft het \"madplay\" programma nodig.\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"udisksctl\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player heeft het \"udisksctl\" programma nodig.\n"
+
# 35
#~ msgid ""
#~ "\n"
diff --git a/po/pl.gmo b/po/pl.gmo
index e8cd141..01eed5e 100644
--- a/po/pl.gmo
+++ b/po/pl.gmo
Binary files differ
diff --git a/po/pl.po b/po/pl.po
index ac5faa2..ad8e015 100644
--- a/po/pl.po
+++ b/po/pl.po
@@ -21,7 +21,7 @@ msgid ""
msgstr ""
"Project-Id-Version: gettext 0.11.2\n"
"Report-Msgid-Bugs-To: <jos@jlemmens.nl>\n"
-"POT-Creation-Date: 2014-04-06 14:33+0200\n"
+"POT-Creation-Date: 2014-06-19 15:50+0200\n"
"PO-Revision-Date: 2013-01-29 15:06+0200\n"
"Last-Translator: Patryk Doering <http://www.rekinet.pl>\n"
"Language-Team: Patryk Doering <http://www.rekinet.pl>Language: pl\n"
@@ -30,12 +30,11 @@ msgstr ""
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-#: src/daisy-player.c:253 src/daisy-player.c:279 src/daisy-player.c:347
-#: src/daisy-player.c:510 src/daisy-player.c:1242 src/daisy-player.c:1300
-#: src/daisy-player.c:1986 src/daisy-player.c:2011 src/daisy-player.c:2367
-#: src/daisy3.c:334 src/daisy3.c:385 src/daisy3.c:428 src/daisy3.c:495
-#: src/daisy3.c:535 src/daisy3.c:554 src/daisy3.c:628 src/daisy3.c:699
-#: src/daisy3.c:835
+#: src/daisy-player.c:218 src/daisy-player.c:245 src/daisy-player.c:316
+#: src/daisy-player.c:484 src/daisy-player.c:1228 src/daisy-player.c:1288
+#: src/daisy-player.c:1948 src/daisy-player.c:1975 src/daisy-player.c:2273
+#: src/daisy3.c:385 src/daisy3.c:436 src/daisy3.c:480 src/daisy3.c:548
+#: src/daisy3.c:589 src/daisy3.c:608 src/daisy3.c:683 src/daisy3.c:810
#, c-format
msgid ""
"\n"
@@ -44,26 +43,26 @@ msgstr ""
"\n"
"Nie można odczytać %s\n"
-#: src/daisy-player.c:450
+#: src/daisy-player.c:419
msgid "'h' for help -"
msgstr "'h' o pomoc - "
-#: src/daisy-player.c:452
+#: src/daisy-player.c:421
#, c-format
msgid " %d pages "
msgstr " %d strony "
-#: src/daisy-player.c:453
+#: src/daisy-player.c:422
#, c-format
msgid " level: %d of %d "
msgstr " Poziom: %d z %d "
-#: src/daisy-player.c:459
+#: src/daisy-player.c:428
#, c-format
msgid " total length: %02d:%02d:%02d "
msgstr " Długość całkowita: %02d:%02d:%02d "
-#: src/daisy-player.c:751
+#: src/daisy-player.c:727
msgid ""
"\n"
"These commands are available in this version:\n"
@@ -71,47 +70,47 @@ msgstr ""
"\n"
"Te polecenia są dostępne w tej wersji:\n"
-#: src/daisy-player.c:754
+#: src/daisy-player.c:730
msgid "cursor down - move cursor to the next item\n"
msgstr "Kursor w dół - przesuń kursor do następnego elementu\n"
-#: src/daisy-player.c:755
+#: src/daisy-player.c:731
msgid "cursor up - move cursor to the previous item\n"
msgstr "Kursor w górę - przesuń kursor do poprzedniej pozycji\n"
-#: src/daisy-player.c:756
+#: src/daisy-player.c:732
msgid "cursor right - skip to next phrase\n"
msgstr "Kursor w prawo - przejście do następnej frazy\n"
-#: src/daisy-player.c:757
+#: src/daisy-player.c:733
msgid "cursor left - skip to previous phrase\n"
msgstr "Kursor w lewo - przejście do poprzedniej frazy\n"
-#: src/daisy-player.c:758
+#: src/daisy-player.c:734
msgid "page-down - view next page\n"
msgstr "page-down - zobacz następną stronę\n"
-#: src/daisy-player.c:759
+#: src/daisy-player.c:735
msgid "page-up - view previous page\n"
msgstr "page-up - zobacz poprzednią stronę\n"
-#: src/daisy-player.c:760
+#: src/daisy-player.c:736
msgid "enter - start playing\n"
msgstr "Enter - rozpoczęcie odtwarzania \n"
-#: src/daisy-player.c:761
+#: src/daisy-player.c:737
msgid "space - pause/resume playing\n"
msgstr "Space - zatrzymanie odtwarzania \n"
-#: src/daisy-player.c:762
+#: src/daisy-player.c:738
msgid "home - play on normal speed\n"
msgstr "Home - odtwarzanie na standardowej prędkości \n"
-#: src/daisy-player.c:764
+#: src/daisy-player.c:740
msgid "Press any key for next page..."
msgstr "Naciśnij dowolny klawisz na następnej stronie..."
-#: src/daisy-player.c:769
+#: src/daisy-player.c:745
msgid ""
"\n"
"/ - search for a label\n"
@@ -119,73 +118,73 @@ msgstr ""
"\n"
"/ - sprawdź etykietę \n"
-#: src/daisy-player.c:770
+#: src/daisy-player.c:746
msgid "d - store current item to disk\n"
msgstr "d - zapisz aktualną pozycję na dysku \n"
-#: src/daisy-player.c:771
+#: src/daisy-player.c:747
msgid "D - decrease playing speed\n"
msgstr "D - zmniejszenie prędkości odtwarzania \n"
-#: src/daisy-player.c:773
+#: src/daisy-player.c:749
msgid ""
"f - find the currently playing item and place the cursor "
"there\n"
msgstr "f - znajdź element aktualnie odtwarzany i umieść tam kursor \n"
-#: src/daisy-player.c:776
+#: src/daisy-player.c:752
msgid "g - go to page number (if any)\n"
msgstr "g - przejdź do strony numer (jeśli jest) \n"
-#: src/daisy-player.c:779
+#: src/daisy-player.c:755
msgid "g - go to time in this song (MM:SS)\n"
msgstr "g - idź do czasu odtwarzania tej pozycji (mm:ss) \n"
-#: src/daisy-player.c:780
+#: src/daisy-player.c:756
msgid "h or ? - give this help\n"
msgstr "h czy ? - pomoc \n"
-#: src/daisy-player.c:781
+#: src/daisy-player.c:757
msgid "j - just play current item\n"
msgstr "j - po prostu odtwarza aktualną pozycję \n"
-#: src/daisy-player.c:783
+#: src/daisy-player.c:759
msgid "l - switch to next level\n"
msgstr "l - przejście do następnego poziomu \n"
-#: src/daisy-player.c:784
+#: src/daisy-player.c:760
msgid "L - switch to previous level\n"
msgstr "l - przejście do poprzedniego poziomu \n"
-#: src/daisy-player.c:785
+#: src/daisy-player.c:761
msgid "n - search forwards\n"
msgstr "n - wyszukiwanie w przód \n"
-#: src/daisy-player.c:786
+#: src/daisy-player.c:762
msgid "N - search backwards\n"
msgstr "n - wyszukiwanie do tyłu \n"
-#: src/daisy-player.c:787
+#: src/daisy-player.c:763
msgid "o - select next output sound device\n"
msgstr "o - wybierz wyjściowe urządzenie dźwiękowe \n"
-#: src/daisy-player.c:788
+#: src/daisy-player.c:764
msgid "p - place a bookmark\n"
msgstr "p - umieść zakładkę \n"
-#: src/daisy-player.c:789
+#: src/daisy-player.c:765
msgid "q - quit daisy-player and place a bookmark\n"
msgstr "q - wyjście z daisy-playera i umieszczenie zakładki \n"
-#: src/daisy-player.c:790
+#: src/daisy-player.c:766
msgid "s - stop playing\n"
msgstr "s - zatrzymanie odtwarzania \n"
-#: src/daisy-player.c:791
+#: src/daisy-player.c:767
msgid "U - increase playing speed\n"
msgstr "u - zwiększenie prędkości odtwarzania \n"
-#: src/daisy-player.c:792
+#: src/daisy-player.c:768
msgid ""
"\n"
"Press any key to leave help..."
@@ -193,32 +192,32 @@ msgstr ""
"\n"
"Naciśnij dowolny klawisz, aby opuścić pomoc... "
-#: src/daisy-player.c:1031
+#: src/daisy-player.c:1011
msgid "Please wait... -------------------------"
msgstr "Proszę czekać... ------------------------- "
-#: src/daisy-player.c:1129
+#: src/daisy-player.c:1110
msgid "What do you search? "
msgstr "Czego szukasz? "
-#: src/daisy-player.c:1223
+#: src/daisy-player.c:1205
msgid "Go to page number: "
msgstr "Idź do strony numer: "
-#: src/daisy-player.c:1355
+#: src/daisy-player.c:1343
msgid "Go to time (MM:SS): "
msgstr "Idź do czasu (mm:ss): "
-#: src/daisy-player.c:1381
+#: src/daisy-player.c:1376
msgid "Cannot read /proc/asound/cards"
msgstr "Nie można odczytać /proc/asound/cards "
-#: src/daisy-player.c:1934 src/daisy-player.c:2117
+#: src/daisy-player.c:1898 src/daisy-player.c:2074
#, c-format
msgid "Daisy-player - Version %s\n"
msgstr "Daisy-player - Wersja %s \n"
-#: src/daisy-player.c:1936
+#: src/daisy-player.c:1900
#, c-format
msgid ""
"\n"
@@ -227,12 +226,12 @@ msgstr ""
"\n"
"Użycie: %s [directory_with_a_Daisy-structure] "
-#: src/daisy-player.c:1938
+#: src/daisy-player.c:1902
#, c-format
msgid "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"
msgstr "[-c cdrom_device] [-d ALSA_sound_device] [-n | -y] \n"
-#: src/daisy-player.c:1953
+#: src/daisy-player.c:1914
msgid ""
"\n"
"Cannot read /proc/mounts."
@@ -240,50 +239,17 @@ msgstr ""
"\n"
"Nie można odczytać /proc/mounts. "
-#: src/daisy-player.c:2118
+#: src/daisy-player.c:2075
msgid "A parser to play Daisy CD's with Linux\n"
msgstr ""
"Parser odtwarza z Daisy CD's i Linuksem\n"
"\n"
-#: src/daisy-player.c:2123
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"eject\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player potrzebuje program \"eject\".\n"
-
-#: src/daisy-player.c:2124 src/daisy-player.c:2133 src/daisy-player.c:2195
-#: src/daisy-player.c:2299
-#, c-format
-msgid "Please install it and try again.\n"
-msgstr "Proszę zainstalować go i spróbuj ponownie. \n"
-
-#: src/daisy-player.c:2132
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"madplay\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player potrzebuje program \"madplay\" .\n"
-
-#: src/daisy-player.c:2141
+#: src/daisy-player.c:2080
msgid "Scanning for a Daisy CD..."
msgstr "Skanowanie Daisy CD... "
-#: src/daisy-player.c:2194
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"unar\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player potrzebuje program \"unar\".\n"
-
-#: src/daisy-player.c:2238 src/daisy3.c:786
+#: src/daisy-player.c:2152 src/daisy3.c:760
#, c-format
msgid ""
"\n"
@@ -292,16 +258,11 @@ msgstr ""
"\n"
"To nie jest Daisy-CD ani Audio-CD. \n"
-#: src/daisy-player.c:2299
-#, c-format
-msgid ""
-"\n"
-"Daisy-player needs the \"udisksctl\" programme.\n"
-msgstr ""
-"\n"
-"Daisy-player potrzebuje program \"udisksctl\".\n"
+#: src/daisy-player.c:2196
+msgid "No Daisy CD in drive."
+msgstr "W napędzie nie ma Daisy-CD. "
-#: src/daisy-player.c:2312
+#: src/daisy-player.c:2223
msgid ""
"\n"
"Found an Audio-CD. "
@@ -309,24 +270,20 @@ msgstr ""
"\n"
"Znaleziono Audio-CD. "
-#: src/daisy-player.c:2314
+#: src/daisy-player.c:2225
msgid "Get titles from freedb.freedb.org..."
msgstr "Pobierz tytuły z freedb.freedb.org... "
-#: src/daisy-player.c:2326
-msgid "No Daisy CD in drive."
-msgstr "W napędzie nie ma Daisy-CD. "
-
-#: src/daisy-player.c:2408
+#: src/daisy-player.c:2314
#, c-format
msgid "Daisy-player - Version %s - (C)2014 J. Lemmens"
msgstr "Daisy-player - Wersja %s - (C)2014 J. Lemmens "
-#: src/daisy-player.c:2422
+#: src/daisy-player.c:2328
msgid "Press 'h' for help "
msgstr "Naciśnij 'h' jeśli potrzebujesz pomocy "
-#: src/daisy3.c:270
+#: src/daisy3.c:320
#, c-format
msgid ""
"\n"
@@ -337,6 +294,37 @@ msgstr ""
#~ msgid ""
#~ "\n"
+#~ "Daisy-player needs the \"unar\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player potrzebuje program \"unar\".\n"
+
+#~ msgid "Please install it and try again.\n"
+#~ msgstr "Proszę zainstalować go i spróbuj ponownie. \n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"eject\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player potrzebuje program \"eject\".\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"madplay\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player potrzebuje program \"madplay\" .\n"
+
+#~ msgid ""
+#~ "\n"
+#~ "Daisy-player needs the \"udisksctl\" programme.\n"
+#~ msgstr ""
+#~ "\n"
+#~ "Daisy-player potrzebuje program \"udisksctl\".\n"
+
+#~ msgid ""
+#~ "\n"
#~ "Cannot use udisksctl command."
#~ msgstr ""
#~ "\n"
diff --git a/src/Makefile.in b/src/Makefile.in
index 6192050..46bc25b 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -1,4 +1,4 @@
-# Makefile.in generated by automake 1.13.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
# @configure_input@
# Copyright (C) 1994-2013 Free Software Foundation, Inc.
@@ -397,14 +397,14 @@ distclean-compile:
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c $<
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ $<
.c.obj:
@am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
@am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
@AMDEP_TRUE@@am__fastdepCC_FALSE@ $(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
@AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
-@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c `$(CYGPATH_W) '$<'`
+@am__fastdepCC_FALSE@ $(AM_V_CC@am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
ID: $(am__tagged_files)
$(am__define_uniq_tagged_files); mkid -fID $$unique
diff --git a/src/audiocd.c b/src/audiocd.c
index 9eb319d..0286eee 100644
--- a/src/audiocd.c
+++ b/src/audiocd.c
@@ -18,20 +18,15 @@
*/
#include "src/daisy.h"
-
-extern daisy_t daisy[];
-extern misc_t misc;
-extern int get_tag_or_label (xmlTextReaderPtr);
-
-void get_cddb_info (misc_t misc)
+void get_cddb_info (misc_t *misc, daisy_t *daisy)
{
FILE *r;
size_t len = MAX_STR;
char *str = NULL, cd[MAX_STR + 1];
int i;
- snprintf (cd, MAX_STR, "cddbget -c %s -I -d 2> /dev/null", misc.cd_dev);
+ snprintf (cd, MAX_STR, "cddbget -c %s -I -d 2> /dev/null", misc->cd_dev);
r = popen (cd, "r");
str = malloc (len + 1);
i = 0;
@@ -41,18 +36,18 @@ void get_cddb_info (misc_t misc)
break;
if (strcasestr (str, "DTITLE"))
{
- strncpy (misc.bookmark_title, strchr (str, '=') + 1, MAX_STR - 1);
- if (strchr (misc.bookmark_title, '\n'))
- *strchr (misc.bookmark_title, '\n') = 0;
- if (strchr (misc.bookmark_title, '\r'))
- *strchr (misc.bookmark_title, '\r') = 0;
- if (strchr (misc.bookmark_title, '/'))
- *strchr (misc.bookmark_title, '/') = '-';
- strncpy (misc.daisy_title, strchr (str, '=') + 1, MAX_STR - 1);
- if (strchr (misc.daisy_title, '\n'))
- *strchr (misc.daisy_title, '\n') = 0;
- if (strchr (misc.daisy_title, '\r'))
- *strchr (misc.daisy_title, '\r') = 0;
+ strncpy (misc->bookmark_title, strchr (str, '=') + 1, MAX_STR - 1);
+ if (strchr (misc->bookmark_title, '\n'))
+ *strchr (misc->bookmark_title, '\n') = 0;
+ if (strchr (misc->bookmark_title, '\r'))
+ *strchr (misc->bookmark_title, '\r') = 0;
+ if (strchr (misc->bookmark_title, '/'))
+ *strchr (misc->bookmark_title, '/') = '-';
+ strncpy (misc->daisy_title, strchr (str, '=') + 1, MAX_STR - 1);
+ if (strchr (misc->daisy_title, '\n'))
+ *strchr (misc->daisy_title, '\n') = 0;
+ if (strchr (misc->daisy_title, '\r'))
+ *strchr (misc->daisy_title, '\r') = 0;
} // if
if (strcasestr (str, "TTITLE"))
{
@@ -62,7 +57,7 @@ void get_cddb_info (misc_t misc)
// some titles are spanned over more lines
if (strstr (str, l) == NULL)
continue;
- strncpy (daisy[i].label, strchr (str, '=') + 1, max_phrase_len - 1);
+ strncpy (daisy[i].label, strchr (str, '=') + 1, MAX_PHRASE_LEN - 1);
if (strchr (daisy[i].label, '\n'))
*strchr (daisy[i].label, '\n') = 0;
if (strchr (daisy[i].label, '\r'))
@@ -74,53 +69,68 @@ void get_cddb_info (misc_t misc)
fclose (r);
} // get_cddb_info
-void get_toc_audiocd (char *dev)
+daisy_t *get_number_of_tracks (misc_t *misc)
+{
+ CdIo_t *cd;
+
+ misc->current = misc->displaying = 0;
+ if ((cd = cdio_open (misc->cd_dev, DRIVER_UNKNOWN)) == NULL)
+ {
+ endwin ();
+ beep ();
+ _exit (0);
+ } // if
+ misc->total_items = cdio_get_num_tracks (cd);
+ return (daisy_t *) malloc (misc->total_items * sizeof (daisy_t));
+} // get_number_of_tracks
+
+void get_toc_audiocd (misc_t *misc, daisy_t *daisy)
{
char *dir;
CdIo_t *cd;
track_t first_track;
- misc.current = misc.displaying = 0;
+ misc->current = misc->displaying = 0;
dir = "";
- if ((cd = cdio_open (dev, DRIVER_UNKNOWN)) == NULL)
+ if ((cd = cdio_open (misc->cd_dev, DRIVER_UNKNOWN)) == NULL)
{
endwin ();
beep ();
_exit (0);
} // if
- misc.total_items = cdio_get_num_tracks (cd);
+ misc->total_items = cdio_get_num_tracks (cd);
first_track = cdio_get_first_track_num (cd);
- for (misc.current = 0; misc.current < misc.total_items; misc.current++)
+ for (misc->current = 0; misc->current < misc->total_items; misc->current++)
{
- snprintf (daisy[misc.current].label, 15, "Track %2d", misc.current + 1);
- snprintf (daisy[misc.current].filename, MAX_STR - 1,
- "%s/Track %d.wav", dir, misc.current + 1);
- daisy[misc.current].first_lsn = cdio_get_track_lsn (cd,
- first_track + misc.current);
- if (misc.displaying == misc.max_y)
- misc.displaying = 1;
- daisy[misc.current].x = 1;
- daisy[misc.current].screen = misc.current / misc.max_y;
- daisy[misc.current].y =
- misc.current - daisy[misc.current].screen * misc.max_y;
- misc.displaying++;
+ snprintf (daisy[misc->current].label, 15, "Track %2d", misc->current + 1);
+ snprintf (daisy[misc->current].filename, MAX_STR - 1,
+ "%s/Track %d.wav", dir, misc->current + 1);
+ daisy[misc->current].first_lsn = cdio_get_track_lsn (cd,
+ first_track + misc->current);
+ if (misc->displaying == misc->max_y)
+ misc->displaying = 1;
+ daisy[misc->current].x = 1;
+ daisy[misc->current].screen = misc->current / misc->max_y;
+ daisy[misc->current].y =
+ misc->current - daisy[misc->current].screen * misc->max_y;
+ misc->displaying++;
} // for
- for (misc.current = 0; misc.current < misc.total_items; misc.current++)
+ for (misc->current = 0; misc->current < misc->total_items; misc->current++)
{
- daisy[misc.current].last_lsn = daisy[misc.current + 1].first_lsn;
- daisy[misc.current].duration =
- (daisy[misc.current].last_lsn - daisy[misc.current].first_lsn) / 75;
+ daisy[misc->current].last_lsn = daisy[misc->current + 1].first_lsn;
+ daisy[misc->current].duration =
+ (daisy[misc->current].last_lsn - daisy[misc->current].first_lsn) / 75;
} // for
- daisy[--misc.current].last_lsn = cdio_get_track_lsn (cd, CDIO_CDROM_LEADOUT_TRACK);
- daisy[misc.current].duration =
- (daisy[misc.current].last_lsn - daisy[misc.current].first_lsn) / 75;
- misc.total_time = (daisy[misc.current].last_lsn - daisy[0].first_lsn) / 75;
+ daisy[--misc->current].last_lsn = cdio_get_track_lsn (cd, CDIO_CDROM_LEADOUT_TRACK);
+ daisy[misc->current].duration =
+ (daisy[misc->current].last_lsn - daisy[misc->current].first_lsn) / 75;
+ misc->total_time = (daisy[misc->current].last_lsn - daisy[0].first_lsn) / 75;
cdio_destroy (cd);
- if (misc.cddb_flag != 'n')
- get_cddb_info (misc);
+ if (misc->cddb_flag != 'n')
+ get_cddb_info (misc, daisy);
} // get_toc_audiocd
-void set_drive_speed (int drive_speed)
+void set_drive_speed (misc_t *misc, int drive_speed)
{
- cdio_set_speed (misc.p_cdio, drive_speed);
+ cdio_set_speed (misc->p_cdio, drive_speed);
} // set_drive_speed
diff --git a/src/daisy-player.c b/src/daisy-player.c
index c025442..6de85c2 100644
--- a/src/daisy-player.c
+++ b/src/daisy-player.c
@@ -28,31 +28,8 @@
#undef VERSION
#include "config.h"
-daisy_t daisy[2000];
-misc_t misc;
-my_attribute_t my_attribute;
-
-extern void parse_smil_3 ();
-extern float read_time (char *);
-extern int get_tag_or_label (xmlTextReaderPtr);
-extern void get_clips (char *, char *);
-void save_rc ();
-void quit_daisy_player ();
-extern void get_page_number_3 ();
-void open_smil_file (char *, char *);
-extern void read_daisy_3 ();
-extern void get_toc_audiocd (char *);
-extern pid_t play_track (char *, char *, lsn_t);
-extern char *get_mcn ();
-void set_drive_speed (int);
-void init_paranoia (char *);
-void skip_left ();
-void play_now ();
-void skip_right ();
-extern void get_label (int, int);
-
-void playfile (char *in_file, char *in_type, char *out_file, char *out_type,
- char *tempo)
+void playfile (misc_t *misc, char *in_file, char *in_type,
+ char *out_file, char *out_type, char *tempo)
{
sox_format_t *sox_in, *sox_out;
sox_effects_chain_t *chain;
@@ -63,40 +40,22 @@ void playfile (char *in_file, char *in_type, char *out_file, char *out_type,
sox_globals.stdout_in_use_by = NULL;
sox_init ();
if ((sox_in = sox_open_read (in_file, NULL, NULL, in_type)) == NULL)
+ failure (in_file, errno);
+ if ((sox_out = sox_open_write (out_file, &sox_in->signal,
+ NULL, out_type, NULL, NULL)) == NULL)
{
int e;
e = errno;
- endwin ();
- printf ("sox_open_read: %s: %s\n", in_file, strerror (e));
- fflush (stdout);
- beep ();
- kill (getppid (), SIGQUIT);
- } // if
- if ((sox_out = sox_open_write (out_file, &sox_in->signal,
- NULL, out_type, NULL, NULL)) == NULL)
- {
- endwin ();
- printf ("playfile %s: %s\n", out_file, gettext (strerror (EINVAL)));
- strncpy (misc.sound_dev, "hw:0", MAX_STR - 1);
+ strncpy (misc->sound_dev, "hw:0", MAX_STR - 1);
save_rc (misc);
- beep ();
- fflush (stdout);
- kill (getppid (), SIGQUIT);
+ failure (out_file, e);
} // if
if (strcmp (in_type, "cdda") == 0)
{
sox_in->encoding.encoding = SOX_ENCODING_SIGN2;
sox_in->encoding.bits_per_sample = 16;
-
-#ifdef SOX_OPTION_NO
- /* libsox < 14.4 */
- sox_in->encoding.reverse_bytes = SOX_OPTION_NO;
-#endif
-#ifdef sox_option_no
- /* libsox >= 14.4 */
sox_in->encoding.reverse_bytes = sox_option_no;
-#endif
} // if
chain = sox_create_effects_chain (&sox_in->encoding, &sox_out->encoding);
@@ -107,8 +66,8 @@ void playfile (char *in_file, char *in_type, char *out_file, char *out_type,
/* Don't use the sox trim effect. It works nice, but is far too slow
char str2[MAX_STR];
- snprintf (str, MAX_STR - 1, "%f", misc.clip_begin);
- snprintf (str2, MAX_STR - 1, "%f", misc.clip_end - misc.clip_begin);
+ snprintf (str, MAX_STR - 1, "%f", misc->clip_begin);
+ snprintf (str2, MAX_STR - 1, "%f", misc->clip_end - misc->clip_begin);
e = sox_create_effect (sox_find_effect ("trim"));
args[0] = str;
args[1] = str2;
@@ -143,7 +102,7 @@ void playfile (char *in_file, char *in_type, char *out_file, char *out_type,
sox_quit ();
} // playfile
-void put_bookmark ()
+void put_bookmark (misc_t *misc)
{
char str[MAX_STR];
xmlTextWriterPtr writer;
@@ -153,173 +112,180 @@ void put_bookmark ()
snprintf (str, MAX_STR - 1, "%s/.daisy-player", pw->pw_dir);
mkdir (str, 0755);
snprintf (str, MAX_STR - 1, "%s/.daisy-player/%s%s",
- pw->pw_dir, misc.bookmark_title, get_mcn (misc));
+ pw->pw_dir, misc->bookmark_title, get_mcn (misc));
if (! (writer = xmlNewTextWriterFilename (str, 0)))
return;
xmlTextWriterStartDocument (writer, NULL, NULL, NULL);
xmlTextWriterStartElement (writer, BAD_CAST "bookmark");
- if (misc.playing >= 0)
+ if (misc->playing >= 0)
xmlTextWriterWriteFormatAttribute
- (writer, BAD_CAST "item", "%d", misc.playing);
+ (writer, BAD_CAST "item", "%d", misc->playing);
else
xmlTextWriterWriteFormatAttribute
- (writer, BAD_CAST "item", "%d", misc.current);
- if (misc.audiocd == 0)
+ (writer, BAD_CAST "item", "%d", misc->current);
+ if (misc->audiocd == 0)
xmlTextWriterWriteFormatAttribute
- (writer, BAD_CAST "clip-begin", "%f", misc.clip_begin);
+ (writer, BAD_CAST "clip-begin", "%f", misc->clip_begin);
else
xmlTextWriterWriteFormatAttribute
- (writer, BAD_CAST "seconds", "%d", (int) (time (NULL) - misc.seconds));
- xmlTextWriterWriteFormatAttribute (writer, BAD_CAST "level", "%d", misc.level);
+ (writer, BAD_CAST "seconds", "%d", (int) (time (NULL) - misc->seconds));
+ xmlTextWriterWriteFormatAttribute (writer, BAD_CAST "level", "%d", misc->level);
xmlTextWriterEndElement (writer);
xmlTextWriterEndDocument (writer);
xmlFreeTextWriter (writer);
} // put_bookmark
-void get_bookmark ()
+void get_bookmark (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
{
char str[MAX_STR];
float begin;
- xmlTextReaderPtr local;
- xmlDocPtr doc;
+ xmlTextReaderPtr local_reader;
+ xmlDocPtr local_doc;
struct passwd *pw;
pw = getpwuid (geteuid ());
- if (! *misc.bookmark_title)
+ if (! *misc->bookmark_title)
return;
snprintf (str, MAX_STR - 1, "%s/.daisy-player/%s%s",
- pw->pw_dir, misc.bookmark_title, get_mcn (misc));
- doc = xmlRecoverFile (str);
- if (! (local = xmlReaderWalker (doc)))
+ pw->pw_dir, misc->bookmark_title, get_mcn (misc));
+ local_doc = xmlRecoverFile (str);
+ if (! (local_reader = xmlReaderWalker (local_doc)))
{
- xmlTextReaderClose (local);
- xmlFreeDoc (doc);
+ xmlFreeDoc (local_doc);
return;
} // if
do
{
- if (! get_tag_or_label (local))
+ if (! get_tag_or_label (misc, my_attribute, local_reader))
break;
- } while (strcasecmp (misc.tag, "bookmark") != 0);
- xmlTextReaderClose (local);
- xmlFreeDoc (doc);
- if (misc.current <= 0)
- misc.current = 0;
- if (misc.current >= misc.total_items)
- misc.current = 0;
- misc.displaying = misc.playing = misc.current;
- if (misc.audiocd == 1)
- {
- misc.player_pid = play_track (misc.sound_dev, "alsa",
- daisy[misc.current].first_lsn + (misc.seconds * 75));
- misc.seconds = time (NULL) - misc.seconds;
+ } while (strcasecmp (misc->tag, "bookmark") != 0);
+ xmlTextReaderClose (local_reader);
+ xmlFreeDoc (local_doc);
+ if (misc->current <= 0)
+ misc->current = 0;
+ if (misc->current >= misc->total_items)
+ misc->current = 0;
+ misc->displaying = misc->playing = misc->current;
+ if (misc->audiocd == 1)
+ {
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
+ daisy[misc->current].first_lsn + (misc->seconds * 75));
+ misc->seconds = time (NULL) - misc->seconds;
return;
} // if
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
- begin = misc.clip_begin;
- open_smil_file (daisy[misc.current].smil_file,
- daisy[misc.current].anchor);
+ get_clips (misc, my_attribute->clip_begin, my_attribute->clip_end);
+ begin = misc->clip_begin;
+ open_smil_file (misc, my_attribute, daisy[misc->current].smil_file,
+ daisy[misc->current].anchor);
while (1)
{
- if (! get_tag_or_label (misc.reader))
- return;
- if (strcasecmp (misc.tag, "audio") == 0)
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
+ break;
+ if (strcasecmp (misc->tag, "audio") == 0)
{
- strncpy (misc.current_audio_file, my_attribute.src, MAX_STR - 1);
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
- if (misc.clip_begin == begin)
+ strncpy (misc->current_audio_file, my_attribute->src, MAX_STR - 1);
+ get_clips (misc, my_attribute->clip_begin, my_attribute->clip_end);
+ if (misc->clip_begin == begin)
break;
} // if
} // while
- if (misc.level < 1)
- misc.level = 1;
- misc.current_page_number = daisy[misc.playing].page_number;
- misc.just_this_item = -1;
- play_now (misc);
+ if (misc->level < 1)
+ misc->level = 1;
+ misc->current_page_number = daisy[misc->playing].page_number;
+ misc->just_this_item = -1;
+ skip_left (misc, my_attribute, daisy);
+ view_screen (misc, daisy);
+ return;
} // get_bookmark
-void get_page_number_2 (char *p)
+void get_page_number_2 (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char *p)
{
// function for daisy 2.02
char *anchor = 0, *id1, *id2;
xmlTextReaderPtr page;
xmlDocPtr doc;
- doc = xmlRecoverFile (daisy[misc.playing].smil_file);
+ doc = xmlRecoverFile (daisy[misc->playing].smil_file);
if (! (page = xmlReaderWalker (doc)))
{
- endwin ();
- beep ();
- printf (gettext ("\nCannot read %s\n"), daisy[misc.playing].smil_file);
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR,
+ gettext ("\nCannot read %s\n"), daisy[misc->playing].smil_file);
+ failure (str, e);
} // if
id1 = strdup (p);
do
{
- if (! get_tag_or_label (page))
+ if (! get_tag_or_label (misc, my_attribute, page))
{
free (id1);
return;
} // if
- } while (strcasecmp (my_attribute.id, id1) != 0);
+ } while (strcasecmp (my_attribute->id, id1) != 0);
do
{
- if (! get_tag_or_label (page))
+ if (! get_tag_or_label (misc, my_attribute, page))
return;
- } while (strcasecmp (misc.tag, "text") != 0);
- id2 = strdup (my_attribute.id);
+ } while (strcasecmp (misc->tag, "text") != 0);
+ id2 = strdup (my_attribute->id);
xmlTextReaderClose (page);
xmlFreeDoc (doc);
- doc = xmlRecoverFile (misc.NCC_HTML);
+ doc = xmlRecoverFile (misc->NCC_HTML);
if (! (page = xmlReaderWalker (doc)))
{
- endwin ();
- beep ();
- printf (gettext ("\nCannot read %s\n"), misc.NCC_HTML);
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR, gettext ("\nCannot read %s\n"), misc->NCC_HTML);
+ failure (str, e);
} // if
while (1)
{
- if (! get_tag_or_label (page))
+ if (! get_tag_or_label (misc, my_attribute, page))
return;
- if (strcasecmp (misc.tag, "a") == 0)
+ if (strcasecmp (misc->tag, "a") == 0)
{
- if (strchr (my_attribute.href, '#'))
- anchor = strdup (strchr (my_attribute.href, '#') + 1);
+ if (strchr (my_attribute->href, '#'))
+ anchor = strdup (strchr (my_attribute->href, '#') + 1);
if (strcasecmp (anchor, id2) == 0)
break;
} // if
} // while
do
{
- if (! get_tag_or_label (page))
+ if (! get_tag_or_label (misc, my_attribute, page))
return;
- } while (! *misc.label);
+ } while (! *misc->label);
xmlTextReaderClose (page);
xmlFreeDoc (doc);
- misc.current_page_number = atoi (misc.label);
+ misc->current_page_number = atoi (misc->label);
} // get_page_number_2
-int get_next_clips ()
-{
+int get_next_clips (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
+{
while (1)
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return 0;
- if (strcasecmp (my_attribute.id, daisy[misc.playing + 1].anchor) == 0 &&
- misc.playing + 1 != misc.total_items)
+ if (strcasecmp (my_attribute->id, daisy[misc->playing + 1].anchor) == 0 &&
+ misc->playing + 1 != misc->total_items)
return 0;
- if (strcasecmp (my_attribute.class, "pagenum") == 0)
- if (strcasestr (misc.daisy_version, "3"))
- get_page_number_3 (misc);
- if (strcasecmp (misc.tag, "audio") == 0)
+ if (strcasecmp (my_attribute->class, "pagenum") == 0)
+ if (strcasestr (misc->daisy_version, "3"))
+ get_page_number_3 (misc, my_attribute);
+ if (strcasecmp (misc->tag, "audio") == 0)
{
- strncpy (misc.current_audio_file, my_attribute.src, MAX_STR - 1);
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
+ strncpy (misc->current_audio_file, my_attribute->src, MAX_STR - 1);
+ get_clips (misc, my_attribute->clip_begin, my_attribute->clip_end);
return 1;
- } // if (strcasecmp (misc.tag, "audio") == 0)
+ } // if (strcasecmp (misc->tag, "audio") == 0)
} // while
} // get_next_clips
@@ -328,248 +294,255 @@ int compare_playorder (const void *p1, const void *p2)
return (*(int *)p1 - *(int*)p2);
} // compare_playorder
-void parse_smil_2 ()
+void parse_smil_2 (misc_t *misc, my_attribute_t *my_attribute, daisy_t *daisy)
{
// function for daisy 2.02
int x;
xmlTextReaderPtr parse;
- misc.total_time = 0;
- for (x = 0; x < misc.total_items; x++)
+ misc->total_time = 0;
+ for (x = 0; x < misc->total_items; x++)
{
if (*daisy[x].smil_file == 0)
continue;
xmlDocPtr doc = xmlRecoverFile (daisy[x].smil_file);
if (! (parse = xmlReaderWalker (doc)))
{
- endwin ();
- beep ();
- printf (gettext ("\nCannot read %s\n"), daisy[x].smil_file);
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR,
+ gettext ("\nCannot read %s\n"), daisy[x].smil_file);
+ failure (str, e);
} // if
// parse this smil
do
{
- if (! get_tag_or_label (parse))
+ if (! get_tag_or_label (misc, my_attribute, parse))
break;
- } while (strcasecmp (my_attribute.id, daisy[x].anchor) != 0);
+ } while (strcasecmp (my_attribute->id, daisy[x].anchor) != 0);
daisy[x].duration = 0;
while (1)
{
- if (! get_tag_or_label (parse))
+ if (! get_tag_or_label (misc, my_attribute, parse))
break;
- if (strcasecmp (misc.tag, "audio") == 0)
+ if (strcasecmp (misc->tag, "audio") == 0)
{
- strncpy (misc.current_audio_file, my_attribute.src, MAX_STR - 1);
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
- daisy[x].begin = misc.clip_begin;
- daisy[x].duration += misc.clip_end - misc.clip_begin;
+ strncpy (misc->current_audio_file, my_attribute->src, MAX_STR - 1);
+ get_clips (misc, my_attribute->clip_begin, my_attribute->clip_end);
+ daisy[x].begin = misc->clip_begin;
+ daisy[x].duration += misc->clip_end - misc->clip_begin;
while (1)
{
- if (! get_tag_or_label (parse))
+ if (! get_tag_or_label (misc, my_attribute, parse))
break;
if (*daisy[x + 1].anchor)
- if (strcasecmp (my_attribute.id, daisy[x + 1].anchor) == 0)
+ if (strcasecmp (my_attribute->id, daisy[x + 1].anchor) == 0)
break;
- if (strcasecmp (misc.tag, "audio") == 0)
+ if (strcasecmp (misc->tag, "audio") == 0)
{
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
- daisy[x].duration += misc.clip_end - misc.clip_begin;
- } // if (strcasecmp (misc.tag, "audio") == 0)
+ get_clips (misc, my_attribute->clip_begin,
+ my_attribute->clip_end);
+ daisy[x].duration += misc->clip_end - misc->clip_begin;
+ } // if (strcasecmp (misc->tag, "audio") == 0)
} // while
if (*daisy[x + 1].anchor)
- if (strcasecmp (my_attribute.id, daisy[x + 1].anchor) == 0)
+ if (strcasecmp (my_attribute->id, daisy[x + 1].anchor) == 0)
break;
- } // if (strcasecmp (misc.tag, "audio") == 0)
+ } // if (strcasecmp (misc->tag, "audio") == 0)
} // while
xmlTextReaderClose (parse);
xmlFreeDoc (doc);
- misc.total_time += daisy[x].duration;
+ misc->total_time += daisy[x].duration;
} // for
} // parse_smil_2
-void view_page (char *id)
+void view_page (misc_t *misc, my_attribute_t *my_attribute, daisy_t *daisy)
{
- if (misc.playing == -1)
+ if (misc->playing == -1)
return;
- if (daisy[misc.playing].screen != daisy[misc.current].screen)
+ if (daisy[misc->playing].screen != daisy[misc->current].screen)
return;
- if (misc.total_pages == 0)
+ if (misc->total_pages == 0)
return;
- wattron (misc.screenwin, A_BOLD);
- if (strcasestr (misc.daisy_version, "2.02"))
- get_page_number_2 (id);
- if (misc.current_page_number)
- mvwprintw (misc.screenwin, daisy[misc.playing].y, 62, "(%3d)",
- misc.current_page_number);
+ wattron (misc->screenwin, A_BOLD);
+ if (strcasestr (misc->daisy_version, "2.02"))
+ get_page_number_2 (misc, my_attribute, daisy, my_attribute->id);
+ if (misc->current_page_number)
+ mvwprintw (misc->screenwin, daisy[misc->playing].y, 62, "(%3d)",
+ misc->current_page_number);
else
- mvwprintw (misc.screenwin, daisy[misc.playing].y, 62, " ");
- wattroff (misc.screenwin, A_BOLD);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
- wrefresh (misc.screenwin);
+ mvwprintw (misc->screenwin, daisy[misc->playing].y, 62, " ");
+ wattroff (misc->screenwin, A_BOLD);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
+ wrefresh (misc->screenwin);
} // view_page
-void view_time ()
+void view_time (misc_t *misc, daisy_t *daisy)
{
float remain_time = 0, curr_time = 0;
- if (misc.playing == -1 ||
- daisy[misc.current].screen != daisy[misc.playing].screen)
+ if (misc->playing == -1 ||
+ daisy[misc->current].screen != daisy[misc->playing].screen)
return;
- wattron (misc.screenwin, A_BOLD);
- if (misc.audiocd == 0)
- curr_time = misc.start_time + (float) (time (NULL) - misc.seconds);
- if (misc.audiocd == 1)
- curr_time = (misc.lsn_cursor - daisy[misc.playing].first_lsn) / 75;
- curr_time /= misc.speed;
- mvwprintw (misc.screenwin, daisy[misc.playing].y, 68, "%02d:%02d",
+ wattron (misc->screenwin, A_BOLD);
+ if (misc->audiocd == 0)
+ curr_time = misc->start_time + (float) (time (NULL) - misc->seconds);
+ if (misc->audiocd == 1)
+ curr_time = (misc->lsn_cursor - daisy[misc->playing].first_lsn) / 75;
+ curr_time /= misc->speed;
+ mvwprintw (misc->screenwin, daisy[misc->playing].y, 68, "%02d:%02d",
(int) curr_time / 60, (int) curr_time % 60);
- if (misc.audiocd == 0)
- remain_time = daisy[misc.playing].duration - curr_time;
- if (misc.audiocd == 1)
- remain_time = (daisy[misc.playing].last_lsn -
- daisy[misc.playing].first_lsn) / 75 - curr_time;
- remain_time /= misc.speed;
- mvwprintw (misc.screenwin, daisy[misc.playing].y, 74, "%02d:%02d",
+ if (misc->audiocd == 0)
+ remain_time = daisy[misc->playing].duration - curr_time;
+ if (misc->audiocd == 1)
+ remain_time = (daisy[misc->playing].last_lsn -
+ daisy[misc->playing].first_lsn) / 75 - curr_time;
+ remain_time /= misc->speed;
+ mvwprintw (misc->screenwin, daisy[misc->playing].y, 74, "%02d:%02d",
(int) remain_time / 60, (int) remain_time % 60);
- wattroff (misc.screenwin, A_BOLD);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
- wrefresh (misc.screenwin);
+ wattroff (misc->screenwin, A_BOLD);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
+ wrefresh (misc->screenwin);
} // view_time
-void view_screen ()
+void view_screen (misc_t *misc, daisy_t *daisy)
{
int i, x, x2;
float time;
- mvwaddstr (misc.titlewin, 1, 0,
+ mvwaddstr (misc->titlewin, 1, 0,
"----------------------------------------");
- waddstr (misc.titlewin, "----------------------------------------");
- mvwprintw (misc.titlewin, 1, 0, gettext ("'h' for help -"));
- if (misc.total_pages)
- wprintw (misc.titlewin, gettext (" %d pages "), misc.total_pages);
- mvwprintw (misc.titlewin, 1, 28, gettext (" level: %d of %d "),
- misc.level, misc.depth);
- time = misc.total_time / misc.speed;
+ waddstr (misc->titlewin, "----------------------------------------");
+ mvwprintw (misc->titlewin, 1, 0, gettext ("'h' for help -"));
+ if (misc->total_pages)
+ wprintw (misc->titlewin, gettext (" %d pages "), misc->total_pages);
+ mvwprintw (misc->titlewin, 1, 28, gettext (" level: %d of %d "),
+ misc->level, misc->depth);
+ time = misc->total_time / misc->speed;
int hours = time / 3600;
int minutes = (time - hours * 3600) / 60;
int seconds = time - (hours * 3600 + minutes * 60);
- mvwprintw (misc.titlewin, 1, 47, gettext (" total length: %02d:%02d:%02d "),
+ mvwprintw (misc->titlewin, 1, 47, gettext (" total length: %02d:%02d:%02d "),
hours, minutes,seconds);
- mvwprintw (misc.titlewin, 1, 74, " %d/%d ",
- daisy[misc.current].screen + 1,
- daisy[misc.total_items - 1].screen + 1);
- wrefresh (misc.titlewin);
- wclear (misc.screenwin);
- for (i = 0; daisy[i].screen != daisy[misc.current].screen; i++);
+ mvwprintw (misc->titlewin, 1, 74, " %d/%d ",
+ daisy[misc->current].screen + 1,
+ daisy[misc->total_items - 1].screen + 1);
+ wrefresh (misc->titlewin);
+ wclear (misc->screenwin);
+ for (i = 0; daisy[i].screen != daisy[misc->current].screen; i++);
do
{
- mvwprintw (misc.screenwin, daisy[i].y, daisy[i].x + 1, daisy[i].label);
+ mvwprintw (misc->screenwin, daisy[i].y, daisy[i].x + 1, daisy[i].label);
x = strlen (daisy[i].label) + daisy[i].x;
if (x / 2 * 2 != x)
- waddstr (misc.screenwin, " ");
+ waddstr (misc->screenwin, " ");
for (x2 = x; x2 < 59; x2 = x2 + 2)
- waddstr (misc.screenwin, " .");
+ waddstr (misc->screenwin, " .");
if (daisy[i].page_number)
- mvwprintw (misc.screenwin, daisy[i].y, 61, " (%3d)", daisy[i].page_number);
- if (daisy[i].level <= misc.level)
+ mvwprintw (misc->screenwin, daisy[i].y, 61, " (%3d)", daisy[i].page_number);
+ if (daisy[i].level <= misc->level)
{
int x = i, dur = 0;
do
{
dur += daisy[x].duration;
- } while (daisy[++x].level > misc.level);
- dur /= misc.speed;
- mvwprintw (misc.screenwin, daisy[i].y, 74, "%02d:%02d",
+ } while (daisy[++x].level > misc->level);
+ dur /= misc->speed;
+ mvwprintw (misc->screenwin, daisy[i].y, 74, "%02d:%02d",
(int) (dur + .5) / 60, (int) (dur + .5) % 60);
} // if
- if (i >= misc.total_items - 1)
+ if (i >= misc->total_items - 1)
break;
- } while (daisy[++i].screen == daisy[misc.current].screen);
- if (misc.just_this_item != -1 &&
- daisy[misc.current].screen == daisy[misc.playing].screen)
- mvwprintw (misc.screenwin, daisy[misc.displaying].y, 0, "J");
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
- wrefresh (misc.screenwin);
+ } while (daisy[++i].screen == daisy[misc->current].screen);
+ if (misc->just_this_item != -1 &&
+ daisy[misc->current].screen == daisy[misc->playing].screen)
+ mvwprintw (misc->screenwin, daisy[misc->displaying].y, 0, "J");
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
+ wrefresh (misc->screenwin);
} // view_screen
-void read_daisy_2 ()
+void read_daisy_2 (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
{
// function for daisy 2.02
int indent = 0, found_page_normal = 0;
xmlTextReaderPtr ncc;
+ xmlDocPtr doc;
- xmlDocPtr doc = xmlRecoverFile (misc.NCC_HTML);
+ if ((doc = xmlRecoverFile (misc->NCC_HTML)) == NULL)
+ failure ("read_daisy_2 ()", errno);
if (! (ncc = xmlReaderWalker (doc)))
{
- endwin ();
- beep ();
- printf (gettext ("\nCannot read %s\n"), misc.NCC_HTML);
- fflush (stdout);
- _exit (1);
+ char str[MAX_STR];
+ int e;
+
+ e = errno;
+ snprintf (str, MAX_STR, gettext ("\nCannot read %s\n"), misc->NCC_HTML);
+ failure (str, e);
} // if
- misc.current = misc.displaying = 0;
+ misc->current = misc->displaying = 0;
while (1)
{
- if (! get_tag_or_label (ncc))
+ if (! get_tag_or_label (misc, my_attribute, ncc))
break;
- if (strcasecmp (misc.tag, "h1") == 0 ||
- strcasecmp (misc.tag, "h2") == 0 ||
- strcasecmp (misc.tag, "h3") == 0 ||
- strcasecmp (misc.tag, "h4") == 0 ||
- strcasecmp (misc.tag, "h5") == 0 ||
- strcasecmp (misc.tag, "h6") == 0)
+ if (strcasecmp (misc->tag, "h1") == 0 ||
+ strcasecmp (misc->tag, "h2") == 0 ||
+ strcasecmp (misc->tag, "h3") == 0 ||
+ strcasecmp (misc->tag, "h4") == 0 ||
+ strcasecmp (misc->tag, "h5") == 0 ||
+ strcasecmp (misc->tag, "h6") == 0)
{
int l;
found_page_normal = 0;
- daisy[misc.current].page_number = 0;
- l = misc.tag[1] - '0';
- daisy[misc.current].level = l;
- daisy[misc.current].x = l + 3 - 1;
- indent = daisy[misc.current].x = (l - 1) * 3 + 1;
+ daisy[misc->current].page_number = 0;
+ l = misc->tag[1] - '0';
+ daisy[misc->current].level = l;
+ daisy[misc->current].x = l + 3 - 1;
+ indent = daisy[misc->current].x = (l - 1) * 3 + 1;
do
{
- if (! get_tag_or_label (ncc))
+ if (! get_tag_or_label (misc, my_attribute, ncc))
break;
- } while (strcasecmp (misc.tag, "a") != 0);
- strncpy (daisy[misc.current].smil_file, my_attribute.href,
+ } while (strcasecmp (misc->tag, "a") != 0);
+ strncpy (daisy[misc->current].smil_file, my_attribute->href,
MAX_STR - 1);
- if (strchr (daisy[misc.current].smil_file, '#'))
+ if (strchr (daisy[misc->current].smil_file, '#'))
{
- strncpy (daisy[misc.current].anchor,
- strchr (daisy[misc.current].smil_file, '#') + 1, MAX_STR - 1);
- *strchr (daisy[misc.current].smil_file, '#') = 0;
+ strncpy (daisy[misc->current].anchor,
+ strchr (daisy[misc->current].smil_file, '#') + 1, MAX_STR - 1);
+ *strchr (daisy[misc->current].smil_file, '#') = 0;
} // if
do
{
- if (! get_tag_or_label (ncc))
+ if (! get_tag_or_label (misc, my_attribute, ncc))
break;
- } while (*misc.label == 0);
- get_label (indent, 0);
- misc.current++;
- misc.displaying++;
- } // if (strcasecmp (misc.tag, "h1") == 0 || ...
- if (strcasecmp (my_attribute.class, "page-normal") == 0 &&
+ } while (*misc->label == 0);
+ get_label (misc, daisy, indent);
+ misc->current++;
+ misc->displaying++;
+ } // if (strcasecmp (misc->tag, "h1") == 0 || ...
+ if (strcasecmp (my_attribute->class, "page-normal") == 0 &&
found_page_normal == 0)
{
found_page_normal = 1;
do
{
- if (! get_tag_or_label (ncc))
+ if (! get_tag_or_label (misc, my_attribute, ncc))
break;
- } while (*misc.label == 0);
- daisy[misc.current - 1].page_number = atoi (misc.label);
- } // if (strcasecmp (my_attribute.class, "page-normal")
+ } while (*misc->label == 0);
+ daisy[misc->current - 1].page_number = atoi (misc->label);
+ } // if (strcasecmp (my_attribute->class, "page-normal")
} // while
xmlTextReaderClose (ncc);
xmlFreeDoc (doc);
- misc.total_items = misc.current;
- parse_smil_2 ();
+ misc->total_items = misc->current;
+ parse_smil_2 (misc, my_attribute, daisy);
} // read_daisy_2
void player_ended ()
@@ -577,21 +550,18 @@ void player_ended ()
wait (NULL);
} // player_ended
-void play_now ()
-{
- if (misc.playing == -1)
+void play_now (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
+{
+ if (misc->playing == -1)
return;
- misc.seconds = time (NULL);
- misc.start_time = misc.clip_begin;
- switch (misc.player_pid = fork ())
+ misc->seconds = time (NULL);
+ misc->start_time = misc->clip_begin;
+ switch (misc->player_pid = fork ())
{
case -1:
- endwin ();
- beep ();
- puts ("fork()");
- fflush (stdout);
- _exit (1);
+ failure ("fork ()", errno);
case 0: // child
break;
default: // parent
@@ -601,454 +571,464 @@ void play_now ()
char tempo_str[15], cmd[MAX_CMD];
setsid ();
- view_page (my_attribute.id);
- lseek (misc.tmp_wav_fd, SEEK_SET, 0);
+ view_page (misc, my_attribute, daisy);
+ lseek (misc->tmp_wav_fd, SEEK_SET, 0);
snprintf (cmd, MAX_CMD - 1, "madplay -Q %s -s %f -t %f -o wav:\"%s\"",
- misc.current_audio_file, misc.clip_begin,
- misc.clip_end - misc.clip_begin, misc.tmp_wav);
+ misc->current_audio_file, misc->clip_begin,
+ misc->clip_end - misc->clip_begin, misc->tmp_wav);
if (system (cmd) != 0)
_exit (0);
- snprintf (tempo_str, 10, "%lf", misc.speed);
- playfile (misc.tmp_wav, "wav", misc.sound_dev, "alsa", tempo_str);
+ snprintf (tempo_str, 10, "%lf", misc->speed);
+ playfile (misc, misc->tmp_wav, "wav", misc->sound_dev, "alsa", tempo_str);
_exit (0);
} // play_now
-void open_smil_file (char *smil_file, char *anchor)
+void open_smil_file (misc_t *misc, my_attribute_t *my_attribute,
+ char *smil_file, char *anchor)
{
- if (misc.audiocd == 1)
+ xmlDocPtr local_doc;
+
+ if (misc->audiocd == 1)
return;
- xmlTextReaderClose (misc.reader);
- xmlDocPtr doc = xmlRecoverFile (smil_file);
- if (! (misc.reader = xmlReaderWalker (doc)))
+ local_doc = xmlRecoverFile (smil_file);
+ if (! (misc->reader = xmlReaderWalker (local_doc)))
{
- endwin ();
- printf ("open_smil_file(): %s: %s\n", smil_file, strerror (errno));
- beep ();
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR, "open_smil_file(): %s\n", smil_file);
+ failure (str, e);
} // if
// skip to anchor
while (1)
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
break;;
- if (strcasecmp (my_attribute.id, anchor) == 0)
+ if (strcasecmp (my_attribute->id, anchor) == 0)
break;
} // while
+ return;
} // open_smil_file
-void pause_resume ()
-{
- if (misc.playing > -1)
+void pause_resume (misc_t *misc, my_attribute_t *my_attribute, daisy_t *daisy)
+{
+ if (misc->playing > -1)
{
- misc.playing = -1;
- if (misc.audiocd == 0)
+ misc->playing = -1;
+ if (misc->audiocd == 0)
{
- kill (misc.player_pid, SIGKILL);
- misc.player_pid = -2;
+ kill (misc->player_pid, SIGKILL);
+ misc->player_pid = -2;
}
else
{
- kill (misc.player_pid, SIGKILL);
+ kill (misc->player_pid, SIGKILL);
} // if
}
else
{
- misc.playing = misc.displaying;
- if (misc.audiocd == 0)
+ misc->playing = misc->displaying;
+ if (misc->audiocd == 0)
{
- skip_left (misc);
+ skip_left (misc, my_attribute, daisy);
skip_right (misc);
}
else
{
lsn_t start;
- start = (lsn_t) (misc.start_time + (float) (time (NULL) - misc.seconds) * 75) +
- daisy[misc.playing].first_lsn;
- misc.player_pid = play_track (misc.sound_dev, "alsa",
+ start = (lsn_t) (misc->start_time + (float) (time (NULL) - misc->seconds) * 75) +
+ daisy[misc->playing].first_lsn;
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
start);
} // if
} // if
} // pause_resume
-void write_wav (char *outfile)
+void write_wav (misc_t *misc, daisy_t *daisy, char *outfile)
{
- char str[MAX_STR];
+ char str[MAX_STR];
struct passwd *pw;
pw = getpwuid (geteuid ());
snprintf (str, MAX_STR - 1, "%s/%s", pw->pw_dir, outfile);
+ while (access (str, F_OK) == 0)
+ strncat (str, ".wav", MAX_STR - 1);
- set_drive_speed (100); // fastest
- if (misc.audiocd == 1)
+ set_drive_speed (misc, 100); // fastest
+ if (misc->audiocd == 1)
{
pid_t pid;
int sp;
int16_t *p_readbuf;
- sp = misc.speed;
- misc.speed = 1;
- pid = play_track (str, "wav",
- daisy[misc.current].first_lsn);
- misc.speed = sp;
+ sp = misc->speed;
+ misc->speed = 1;
+ pid = play_track (misc, str, "wav",
+ daisy[misc->current].first_lsn);
+ misc->speed = sp;
do
{
- if (! (p_readbuf = paranoia_read (misc.par, NULL)))
+ if (! (p_readbuf = paranoia_read (misc->par, NULL)))
break;
- switch (write (misc.pipefd[1], p_readbuf, CDIO_CD_FRAMESIZE_RAW))
+ switch (write (misc->pipefd[1], p_readbuf, CDIO_CD_FRAMESIZE_RAW))
{
default:
break;
} // switch
- } while (++misc.lsn_cursor <= daisy[misc.current].last_lsn);
+ } while (++misc->lsn_cursor <= daisy[misc->current].last_lsn);
kill (pid, SIGQUIT);
- set_drive_speed (4);
+ set_drive_speed (misc, 4);
return;
} // if
char cmd[MAX_CMD];
- lseek (misc.tmp_wav_fd, SEEK_SET, 0);
+ lseek (misc->tmp_wav_fd, SEEK_SET, 0);
snprintf (cmd, MAX_CMD, "madplay -Q \"%s\" -s %f -t %f -o wav:\"%s\"",
- misc.current_audio_file,
- daisy[misc.current].begin, daisy[misc.current].duration, str);
+ misc->current_audio_file,
+ daisy[misc->current].begin, daisy[misc->current].duration, str);
if (system (cmd) != 0)
- _exit (0);
- set_drive_speed (4);
+ failure (cmd, errno);
+ set_drive_speed (misc, 4);
} // write_wav
-void store_to_disk ()
-{
+void store_to_disk (misc_t *misc, my_attribute_t *my_attribute, daisy_t *daisy)
+{
char str[MAX_STR];
int i, pause_flag;
- pause_flag = misc.playing;
+ pause_flag = misc->playing;
if (pause_flag > -1)
- pause_resume (misc);
- wclear (misc.screenwin);
- snprintf (str, MAX_STR - 1, "%s.wav", daisy[misc.current].label);
- wprintw (misc.screenwin,
+ pause_resume (misc, my_attribute, daisy);
+ wclear (misc->screenwin);
+ snprintf (str, MAX_STR - 1, "%s.wav", daisy[misc->current].label);
+ wprintw (misc->screenwin,
"\nStoring \"%s\" as \"%s\" into your home-folder...",
- daisy[misc.current].label, str);
- wrefresh (misc.screenwin);
+ daisy[misc->current].label, str);
+ wrefresh (misc->screenwin);
for (i = 0; str[i] != 0; i++)
if (str[i] == '/')
str[i] = '-';
- write_wav (str);
+ write_wav (misc, daisy, str);
if (pause_flag > -1)
- pause_resume (misc);
- view_screen (misc);
+ pause_resume (misc, my_attribute, daisy);
+ view_screen (misc, daisy);
} // store_to_disk
-void help ()
-{
+void help (misc_t *misc, daisy_t *daisy)
+{
int y, x;
- getyx (misc.screenwin, y, x);
- wclear (misc.screenwin);
- waddstr (misc.screenwin, gettext ("\nThese commands are available in this version:\n"));
- waddstr (misc.screenwin, "========================================");
- waddstr (misc.screenwin, "========================================\n\n");
- waddstr (misc.screenwin, gettext ("cursor down - move cursor to the next item\n"));
- waddstr (misc.screenwin, gettext ("cursor up - move cursor to the previous item\n"));
- waddstr (misc.screenwin, gettext ("cursor right - skip to next phrase\n"));
- waddstr (misc.screenwin, gettext ("cursor left - skip to previous phrase\n"));
- waddstr (misc.screenwin, gettext ("page-down - view next page\n"));
- waddstr (misc.screenwin, gettext ("page-up - view previous page\n"));
- waddstr (misc.screenwin, gettext ("enter - start playing\n"));
- waddstr (misc.screenwin, gettext ("space - pause/resume playing\n"));
- waddstr (misc.screenwin, gettext ("home - play on normal speed\n"));
- waddstr (misc.screenwin, "\n");
- waddstr (misc.screenwin, gettext ("Press any key for next page..."));
- nodelay (misc.screenwin, FALSE);
- wgetch (misc.screenwin);
- nodelay (misc.screenwin, TRUE);
- wclear (misc.screenwin);
- waddstr (misc.screenwin, gettext ("\n/ - search for a label\n"));
- waddstr (misc.screenwin, gettext ("d - store current item to disk\n"));
- waddstr (misc.screenwin, gettext ("D - decrease playing speed\n"));
- waddstr (misc.screenwin, gettext (
+ getyx (misc->screenwin, y, x);
+ wclear (misc->screenwin);
+ waddstr (misc->screenwin, gettext ("\nThese commands are available in this version:\n"));
+ waddstr (misc->screenwin, "========================================");
+ waddstr (misc->screenwin, "========================================\n\n");
+ waddstr (misc->screenwin, gettext ("cursor down - move cursor to the next item\n"));
+ waddstr (misc->screenwin, gettext ("cursor up - move cursor to the previous item\n"));
+ waddstr (misc->screenwin, gettext ("cursor right - skip to next phrase\n"));
+ waddstr (misc->screenwin, gettext ("cursor left - skip to previous phrase\n"));
+ waddstr (misc->screenwin, gettext ("page-down - view next page\n"));
+ waddstr (misc->screenwin, gettext ("page-up - view previous page\n"));
+ waddstr (misc->screenwin, gettext ("enter - start playing\n"));
+ waddstr (misc->screenwin, gettext ("space - pause/resume playing\n"));
+ waddstr (misc->screenwin, gettext ("home - play on normal speed\n"));
+ waddstr (misc->screenwin, "\n");
+ waddstr (misc->screenwin, gettext ("Press any key for next page..."));
+ nodelay (misc->screenwin, FALSE);
+ wgetch (misc->screenwin);
+ nodelay (misc->screenwin, TRUE);
+ wclear (misc->screenwin);
+ waddstr (misc->screenwin, gettext ("\n/ - search for a label\n"));
+ waddstr (misc->screenwin, gettext ("d - store current item to disk\n"));
+ waddstr (misc->screenwin, gettext ("D - decrease playing speed\n"));
+ waddstr (misc->screenwin, gettext (
"f - find the currently playing item and place the cursor there\n"));
- if (misc.audiocd == 0)
- waddstr (misc.screenwin,
+ if (misc->audiocd == 0)
+ waddstr (misc->screenwin,
gettext ("g - go to page number (if any)\n"));
else
- waddstr (misc.screenwin,
+ waddstr (misc->screenwin,
gettext ("g - go to time in this song (MM:SS)\n"));
- waddstr (misc.screenwin, gettext ("h or ? - give this help\n"));
- waddstr (misc.screenwin, gettext ("j - just play current item\n"));
- waddstr (misc.screenwin,
+ waddstr (misc->screenwin, gettext ("h or ? - give this help\n"));
+ waddstr (misc->screenwin, gettext ("j - just play current item\n"));
+ waddstr (misc->screenwin,
gettext ("l - switch to next level\n"));
- waddstr (misc.screenwin, gettext ("L - switch to previous level\n"));
- waddstr (misc.screenwin, gettext ("n - search forwards\n"));
- waddstr (misc.screenwin, gettext ("N - search backwards\n"));
- waddstr (misc.screenwin, gettext ("o - select next output sound device\n"));
- waddstr (misc.screenwin, gettext ("p - place a bookmark\n"));
- waddstr (misc.screenwin, gettext ("q - quit daisy-player and place a bookmark\n"));
- waddstr (misc.screenwin, gettext ("s - stop playing\n"));
- waddstr (misc.screenwin, gettext ("U - increase playing speed\n"));
- waddstr (misc.screenwin, gettext ("\nPress any key to leave help..."));
- nodelay (misc.screenwin, FALSE);
- wgetch (misc.screenwin);
- nodelay (misc.screenwin, TRUE);
- view_screen (misc);
- wmove (misc.screenwin, y, x);
+ waddstr (misc->screenwin, gettext ("L - switch to previous level\n"));
+ waddstr (misc->screenwin, gettext ("n - search forwards\n"));
+ waddstr (misc->screenwin, gettext ("N - search backwards\n"));
+ waddstr (misc->screenwin, gettext ("o - select next output sound device\n"));
+ waddstr (misc->screenwin, gettext ("p - place a bookmark\n"));
+ waddstr (misc->screenwin, gettext ("q - quit daisy-player and place a bookmark\n"));
+ waddstr (misc->screenwin, gettext ("s - stop playing\n"));
+ waddstr (misc->screenwin, gettext ("U - increase playing speed\n"));
+ waddstr (misc->screenwin, gettext ("\nPress any key to leave help..."));
+ nodelay (misc->screenwin, FALSE);
+ wgetch (misc->screenwin);
+ nodelay (misc->screenwin, TRUE);
+ view_screen (misc, daisy);
+ wmove (misc->screenwin, y, x);
} // help
-void previous_item ()
-{
- if (misc.current == 0)
+void previous_item (misc_t *misc, daisy_t *daisy)
+{
+ if (misc->current == 0)
return;
- while (daisy[misc.current].level > misc.level)
- misc.current--;
- if (misc.playing == -1)
- misc.displaying = misc.current;
- view_screen (misc);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
+ while (daisy[misc->current].level > misc->level)
+ misc->current--;
+ if (misc->playing == -1)
+ misc->displaying = misc->current;
+ view_screen (misc, daisy);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
} // previous_item
-void next_item ()
-{
- if (misc.current >= misc.total_items - 1)
+void next_item (misc_t *misc, daisy_t *daisy)
+{
+ if (misc->current >= misc->total_items - 1)
{
beep ();
return;
} // if
- while (daisy[++misc.current].level > misc.level)
+ while (daisy[++misc->current].level > misc->level)
{
- if (misc.current >= misc.total_items - 1)
+ if (misc->current >= misc->total_items - 1)
{
beep ();
- previous_item (misc);
+ previous_item (misc, daisy);
return;
} // if
} // while
- view_screen (misc);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
+ view_screen (misc, daisy);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
} // next_item
-void play_clip ()
-{
+void play_clip (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
+{
char str[MAX_STR];
- if (kill (misc.player_pid, 0) == 0)
+ if (kill (misc->player_pid, 0) == 0)
// if still playing
return;
- misc.player_pid = -2;
- if (get_next_clips (misc))
+ misc->player_pid = -2;
+ if (get_next_clips (misc, my_attribute, daisy))
{
- play_now (misc);
+ play_now (misc, my_attribute, daisy);
return;
} // if
// go to next item
- strncpy (my_attribute.clip_begin, "0", 2);
- misc.clip_begin = 0;
- if (++misc.playing >= misc.total_items)
+ strncpy (my_attribute->clip_begin, "0", 2);
+ misc->clip_begin = 0;
+ if (++misc->playing >= misc->total_items)
{
struct passwd *pw;
pw = getpwuid (geteuid ());
quit_daisy_player (misc);
snprintf (str, MAX_STR - 1, "%s/.daisy-player/%s%s", pw->pw_dir,
- misc.bookmark_title, get_mcn (misc));
+ misc->bookmark_title, get_mcn (misc));
unlink (str);
_exit (0);
} // if
- if (daisy[misc.playing].level <= misc.level)
- misc.displaying = misc.current = misc.playing;
- if (misc.just_this_item != -1)
- if (daisy[misc.playing].level <= misc.level)
- misc.playing = misc.just_this_item = -1;
- if (misc.playing > -1)
- open_smil_file (daisy[misc.playing].smil_file,
- daisy[misc.playing].anchor);
- view_screen (misc);
+ if (daisy[misc->playing].level <= misc->level)
+ misc->displaying = misc->current = misc->playing;
+ if (misc->just_this_item != -1)
+ if (daisy[misc->playing].level <= misc->level)
+ misc->playing = misc->just_this_item = -1;
+ if (misc->playing > -1)
+ open_smil_file (misc, my_attribute, daisy[misc->playing].smil_file,
+ daisy[misc->playing].anchor);
+ view_screen (misc, daisy);
} // play_clip
-void skip_left ()
+void skip_left (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
{
struct
{
char src[MAX_STR], clip_begin[MAX_STR], clip_end[MAX_STR];
} curr, prev, orig;
- if (misc.audiocd == 1)
+ if (misc->audiocd == 1)
return;
- if (misc.playing < 0)
+ if (misc->playing < 0)
{
beep ();
return;
} // if
- if (misc.player_pid > 0)
- while (kill (misc.player_pid, SIGKILL) != 0);
- if (misc.audiocd == 1)
+ if (misc->player_pid > 0)
+ while (kill (misc->player_pid, SIGKILL) != 0);
+ if (misc->audiocd == 1)
{
beep ();
return;
} // if
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
- if (daisy[misc.playing].begin != misc.clip_begin)
+ get_clips (misc, my_attribute->clip_begin, my_attribute->clip_end);
+ if (daisy[misc->playing].begin != misc->clip_begin)
{
// save current values in orig and curr arrays
- strncpy (orig.clip_begin, my_attribute.clip_begin, MAX_STR - 1);
- strncpy (orig.clip_end, my_attribute.clip_end, MAX_STR - 1);
- strncpy (orig.src, my_attribute.src, MAX_STR - 1);
- strncpy (curr.clip_begin, my_attribute.clip_begin, MAX_STR - 1);
- strncpy (curr.clip_end, my_attribute.clip_end, MAX_STR - 1);
- strncpy (curr.src, my_attribute.src, MAX_STR - 1);
- open_smil_file (daisy[misc.playing].smil_file,
- daisy[misc.playing].anchor);
+ strncpy (orig.clip_begin, my_attribute->clip_begin, MAX_STR - 1);
+ strncpy (orig.clip_end, my_attribute->clip_end, MAX_STR - 1);
+ strncpy (orig.src, my_attribute->src, MAX_STR - 1);
+ strncpy (curr.clip_begin, my_attribute->clip_begin, MAX_STR - 1);
+ strncpy (curr.clip_end, my_attribute->clip_end, MAX_STR - 1);
+ strncpy (curr.src, my_attribute->src, MAX_STR - 1);
+ open_smil_file (misc, my_attribute, daisy[misc->playing].smil_file,
+ daisy[misc->playing].anchor);
while (1)
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return;
- if (strcasecmp (my_attribute.class, "pagenum") == 0)
+ if (strcasecmp (my_attribute->class, "pagenum") == 0)
{
do
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return;
- } while (strcasecmp (misc.tag, "/par") != 0);
- } // if (strcasecmp (my_attribute.class, "pagenum") == 0)
- if (strcasecmp (misc.tag, "audio") == 0)
+ } while (strcasecmp (misc->tag, "/par") != 0);
+ } // if (strcasecmp (my_attribute->class, "pagenum") == 0)
+ if (strcasecmp (misc->tag, "audio") == 0)
{
strncpy (prev.clip_begin, curr.clip_begin, MAX_STR - 1);
strncpy (prev.clip_end, curr.clip_end, MAX_STR - 1);
strncpy (prev.src, curr.src, MAX_STR - 1);
- strncpy (curr.clip_begin, my_attribute.clip_begin, MAX_STR - 1);
- strncpy (curr.clip_end, my_attribute.clip_end, MAX_STR - 1);
- strncpy (curr.src, my_attribute.src, MAX_STR - 1);
+ strncpy (curr.clip_begin, my_attribute->clip_begin, MAX_STR - 1);
+ strncpy (curr.clip_end, my_attribute->clip_end, MAX_STR - 1);
+ strncpy (curr.src, my_attribute->src, MAX_STR - 1);
if (strcasecmp (orig.clip_begin, curr.clip_begin) == 0 &&
strcasecmp (orig.src, curr.src) == 0)
{
- open_smil_file (daisy[misc.playing].smil_file,
- daisy[misc.playing].anchor);
+ open_smil_file (misc, my_attribute, daisy[misc->playing].smil_file,
+ daisy[misc->playing].anchor);
while (1)
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return;
- if (strcasecmp (misc.tag , "audio") == 0)
+ if (strcasecmp (misc->tag , "audio") == 0)
{
- if (strcasecmp (my_attribute.clip_begin,
+ if (strcasecmp (my_attribute->clip_begin,
prev.clip_begin) == 0 &&
- strcasecmp (my_attribute.src, prev.src) == 0)
+ strcasecmp (my_attribute->src, prev.src) == 0)
{
- get_clips (my_attribute.clip_begin,
- my_attribute.clip_end);
- play_now (misc);
+ get_clips (misc, my_attribute->clip_begin,
+ my_attribute->clip_end);
+ play_now (misc, my_attribute, daisy);
return;
- } // if (strcasecmp (my_attribute.clip_begin, prev.cli ...
- } // if (strcasecmp (misc.tag , "audio") == 0)
+ } // if (strcasecmp (my_attribute->clip_begin, prev.cli ...
+ } // if (strcasecmp (misc->tag , "audio") == 0)
} // while
} // if (strcasecmp (orig.clip_begin, curr.clip_begin) == 0 &&
- } // if (strcasecmp (misc.tag, "audio") == 0)
+ } // if (strcasecmp (misc->tag, "audio") == 0)
} // while
- } // if (clip_begin != daisy[misc.playing].begin)
+ } // if (clip_begin != daisy[misc->playing].begin)
// go to end of previous item
- misc.current = misc.displaying = --misc.playing;
- if (misc.current < 0)
+ misc->current = misc->displaying = --misc->playing;
+ if (misc->current < 0)
{
beep ();
- misc.current = misc.displaying = misc.playing = 0;
+ misc->current = misc->displaying = misc->playing = 0;
return;
} // if
- open_smil_file (daisy[misc.current].smil_file, daisy[misc.current].anchor);
+ open_smil_file (misc, my_attribute, daisy[misc->current].smil_file, daisy[misc->current].anchor);
while (1)
{
// search last clip
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
break;
- if (strcasecmp (my_attribute.class, "pagenum") == 0)
+ if (strcasecmp (my_attribute->class, "pagenum") == 0)
{
do
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return;
- } while (strcasecmp (misc.tag, "/par") != 0);
- } // if (strcasecmp (my_attribute.class, "pagenum") == 0)
- if (strcasecmp (misc.tag, "audio") == 0)
+ } while (strcasecmp (misc->tag, "/par") != 0);
+ } // if (strcasecmp (my_attribute->class, "pagenum") == 0)
+ if (strcasecmp (misc->tag, "audio") == 0)
{
- strncpy (curr.clip_begin, my_attribute.clip_begin, MAX_STR - 1);
- strncpy (curr.clip_end, my_attribute.clip_end, MAX_STR - 1);
- strncpy (curr.src, my_attribute.src, MAX_STR - 1);
- } // if (strcasecmp (misc.tag, "audio") == 0)
- if (strcasecmp (my_attribute.id, daisy[misc.current + 1].anchor) == 0)
+ strncpy (curr.clip_begin, my_attribute->clip_begin, MAX_STR - 1);
+ strncpy (curr.clip_end, my_attribute->clip_end, MAX_STR - 1);
+ strncpy (curr.src, my_attribute->src, MAX_STR - 1);
+ } // if (strcasecmp (misc->tag, "audio") == 0)
+ if (strcasecmp (my_attribute->id, daisy[misc->current + 1].anchor) == 0)
break;
} // while
- misc.just_this_item = -1;
- open_smil_file (daisy[misc.current].smil_file, daisy[misc.current].anchor);
+ misc->just_this_item = -1;
+ open_smil_file (misc, my_attribute, daisy[misc->current].smil_file,
+ daisy[misc->current].anchor);
while (1)
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return;
- if (strcasecmp (misc.tag , "audio") == 0)
+ if (strcasecmp (misc->tag , "audio") == 0)
{
- if (strcasecmp (my_attribute.clip_begin, curr.clip_begin) == 0 &&
- strcasecmp (my_attribute.src, curr.src) == 0)
+ if (strcasecmp (my_attribute->clip_begin, curr.clip_begin) == 0 &&
+ strcasecmp (my_attribute->src, curr.src) == 0)
{
- strncpy (misc.current_audio_file, my_attribute.src, MAX_STR - 1);
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
- view_screen (misc);
- play_now (misc);
+ strncpy (misc->current_audio_file, my_attribute->src, MAX_STR - 1);
+ get_clips (misc, my_attribute->clip_begin, my_attribute->clip_end);
+ view_screen (misc, daisy);
+ play_now (misc, my_attribute, daisy);
return;
- } // if (strcasecmp (my_attribute.clip_begin, curr.clip_begin) == 0 &&
- } // if (strcasecmp (misc.tag , "audio") == 0)
+ } // if (strcasecmp (my_attribute->clip_begin, curr.clip_begin) == 0 &&
+ } // if (strcasecmp (misc->tag , "audio") == 0)
} // while
} // skip_left
-void skip_right ()
-{
- if (misc.audiocd == 1)
+void skip_right (misc_t *misc)
+{
+ if (misc->audiocd == 1)
return;
- if (misc.playing == -1)
+ if (misc->playing == -1)
{
beep ();
return;
} // if
- if (misc.audiocd == 0)
+ if (misc->audiocd == 0)
{
- kill (misc.player_pid, SIGKILL);
- misc.player_pid = -2;
+ kill (misc->player_pid, SIGKILL);
+ misc->player_pid = -2;
} // if
} // skip_right
-void change_level (char key)
+void change_level (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char key)
{
int c, l;
- if (misc.depth == 1)
+ if (misc->depth == 1)
return;
if (key == 'l')
- if (++misc.level > misc.depth)
- misc.level = 1;
+ if (++misc->level > misc->depth)
+ misc->level = 1;
if (key == 'L')
- if (--misc.level < 1)
- misc.level = misc.depth;
- mvwprintw (misc.titlewin, 1, 0, gettext ("Please wait... -------------------------"));
- wprintw (misc.titlewin, "----------------------------------------");
- wrefresh (misc.titlewin);
- c = misc.current;
- l = misc.level;
- if (strcasestr (misc.daisy_version, "2.02"))
- read_daisy_2 (misc);
- if (strcasestr (misc.daisy_version, "3"))
- {
- read_daisy_3 (misc);
- parse_smil_3 (misc);
+ if (--misc->level < 1)
+ misc->level = misc->depth;
+ mvwprintw (misc->titlewin, 1, 0, gettext ("Please wait... -------------------------"));
+ wprintw (misc->titlewin, "----------------------------------------");
+ wrefresh (misc->titlewin);
+ c = misc->current;
+ l = misc->level;
+ if (strcasestr (misc->daisy_version, "2.02"))
+ read_daisy_2 (misc, my_attribute, daisy);
+ if (strcasestr (misc->daisy_version, "3"))
+ {
+ read_daisy_3 (misc, my_attribute, daisy);
+ parse_smil_3 (misc, my_attribute, daisy);
} // if
- misc.current = c;
- misc.level = l;
- if (daisy[misc.current].level > misc.level)
- previous_item (misc);
- view_screen (misc);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
+ misc->current = c;
+ misc->level = l;
+ if (daisy[misc->current].level > misc->level)
+ previous_item (misc, daisy);
+ view_screen (misc, daisy);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
} // change_level
-void read_rc ()
+void read_rc (misc_t *misc, my_attribute_t *my_attribute)
{
char str[MAX_STR];
struct passwd *pw;;
@@ -1060,21 +1040,21 @@ void read_rc ()
doc = xmlRecoverFile (str);
if (! (reader = xmlReaderWalker (doc)))
{
- strncpy (misc.sound_dev, "hw:0", MAX_STR - 1);
+ strncpy (misc->sound_dev, "hw:0", MAX_STR - 1);
return;
} // if
do
{
- if (! get_tag_or_label (reader))
+ if (! get_tag_or_label (misc, my_attribute, reader))
break;
- } while (strcasecmp (misc.tag, "prefs") != 0);
+ } while (strcasecmp (misc->tag, "prefs") != 0);
xmlTextReaderClose (reader);
xmlFreeDoc (doc);
- if (misc.cddb_flag != 'n' && misc.cddb_flag != 'y')
- misc.cddb_flag = 'y';
+ if (misc->cddb_flag != 'n' && misc->cddb_flag != 'y')
+ misc->cddb_flag = 'y';
} // read_rc
-void save_rc ()
+void save_rc (misc_t *misc)
{
struct passwd *pw;
char str[MAX_STR];
@@ -1087,55 +1067,56 @@ void save_rc ()
xmlTextWriterStartDocument (writer, NULL, NULL, NULL);
xmlTextWriterStartElement (writer, BAD_CAST "prefs");
xmlTextWriterWriteFormatAttribute
- (writer, BAD_CAST "sound_dev", "%s", misc.sound_dev);
+ (writer, BAD_CAST "sound_dev", "%s", misc->sound_dev);
xmlTextWriterWriteFormatAttribute (writer, BAD_CAST "speed", "%lf",
- misc.speed);
+ misc->speed);
xmlTextWriterWriteFormatAttribute
- (writer, BAD_CAST "cd_dev", "%s", misc.cd_dev);
+ (writer, BAD_CAST "cd_dev", "%s", misc->cd_dev);
xmlTextWriterWriteFormatAttribute
- (writer, BAD_CAST "cddb_flag", "%c", misc.cddb_flag);
+ (writer, BAD_CAST "cddb_flag", "%c", misc->cddb_flag);
xmlTextWriterEndElement (writer);
xmlTextWriterEndDocument (writer);
xmlFreeTextWriter (writer);
} // save_rc
-void quit_daisy_player ()
+void quit_daisy_player (misc_t *misc)
{
endwin ();
- kill (misc.player_pid, SIGKILL);
- misc.player_pid = -2;
+ kill (misc->player_pid, SIGKILL);
+ misc->player_pid = -2;
put_bookmark (misc);
save_rc (misc);
// reset the CD speed
- set_drive_speed (100);
- close (misc.tmp_wav_fd);
+ set_drive_speed (misc, 100);
+ close (misc->tmp_wav_fd);
puts ("");
} // quit_daisy_player
-void search (int start, char mode)
+void search (misc_t *misc, my_attribute_t *my_attribute, daisy_t *daisy,
+ int start, char mode)
{
int c, found = 0, flag = 0;
- if (misc.playing != -1)
+ if (misc->playing != -1)
{
flag = 1;
- pause_resume (misc);
+ pause_resume (misc, my_attribute, daisy);
} // if
if (mode == '/')
{
- mvwaddstr (misc.titlewin, 1, 0, "----------------------------------------");
- waddstr (misc.titlewin, "----------------------------------------");
- mvwprintw (misc.titlewin, 1, 0, gettext ("What do you search? "));
+ mvwaddstr (misc->titlewin, 1, 0, "----------------------------------------");
+ waddstr (misc->titlewin, "----------------------------------------");
+ mvwprintw (misc->titlewin, 1, 0, gettext ("What do you search? "));
echo ();
- wgetnstr (misc.titlewin, misc.search_str, 25);
+ wgetnstr (misc->titlewin, misc->search_str, 25);
noecho ();
} // if
if (mode == '/' || mode == 'n')
{
- for (c = start; c <= misc.total_items + 1; c++)
+ for (c = start; c <= misc->total_items + 1; c++)
{
- if (strcasestr (daisy[c].label, misc.search_str))
+ if (strcasestr (daisy[c].label, misc->search_str))
{
found = 1;
break;
@@ -1145,7 +1126,7 @@ void search (int start, char mode)
{
for (c = 0; c < start; c++)
{
- if (strcasestr (daisy[c].label, misc.search_str))
+ if (strcasestr (daisy[c].label, misc->search_str))
{
found = 1;
break;
@@ -1157,7 +1138,7 @@ void search (int start, char mode)
{ // mode == 'N'
for (c = start; c >= 0; c--)
{
- if (strcasestr (daisy[c].label, misc.search_str))
+ if (strcasestr (daisy[c].label, misc->search_str))
{
found = 1;
break;
@@ -1165,9 +1146,9 @@ void search (int start, char mode)
} // for
if (! found)
{
- for (c = misc.total_items + 1; c > start; c--)
+ for (c = misc->total_items + 1; c > start; c--)
{
- if (strcasestr (daisy[c].label, misc.search_str))
+ if (strcasestr (daisy[c].label, misc->search_str))
{
found = 1;
break;
@@ -1177,90 +1158,93 @@ void search (int start, char mode)
} // if
if (found)
{
- misc.playing = misc.displaying= misc.current = c;
- misc.clip_begin = daisy[misc.current].begin;
- misc.just_this_item = -1;
- view_screen (misc);
- if (misc.audiocd == 0)
- open_smil_file (daisy[misc.current].smil_file,
- daisy[misc.current].anchor);
+ misc->playing = misc->displaying= misc->current = c;
+ misc->clip_begin = daisy[misc->current].begin;
+ misc->just_this_item = -1;
+ view_screen (misc, daisy);
+ if (misc->audiocd == 0)
+ open_smil_file (misc, my_attribute, daisy[misc->current].smil_file,
+ daisy[misc->current].anchor);
else
{
- misc.seconds = time (NULL);
- misc.player_pid = play_track (misc.sound_dev, "alsa",
- daisy[misc.current].first_lsn);
+ misc->seconds = time (NULL);
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
+ daisy[misc->current].first_lsn);
} // if
}
else
{
beep ();
- view_screen (misc);
+ view_screen (misc, daisy);
if (! flag)
return;
- misc.playing = misc.displaying;
- if (misc.audiocd == 0)
+ misc->playing = misc->displaying;
+ if (misc->audiocd == 0)
{
- skip_left (misc);
+ skip_left (misc, my_attribute, daisy);
skip_right (misc);
}
else
{
- misc.playing = -1;
- pause_resume (misc);
+ misc->playing = -1;
+ pause_resume (misc, my_attribute, daisy);
} // if
} // if
} // search
-void go_to_page_number ()
-{
+void go_to_page_number (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
+{
char filename[MAX_STR], *anchor = 0;
char pn[15], href[MAX_STR], prev_href[MAX_STR];
- kill (misc.player_pid, SIGKILL);
- misc.player_pid = -2;
- mvwaddstr (misc.titlewin, 1, 0, "----------------------------------------");
- waddstr (misc.titlewin, "----------------------------------------");
- mvwprintw (misc.titlewin, 1, 0, gettext ("Go to page number: "));
+ kill (misc->player_pid, SIGKILL);
+ misc->player_pid = -2;
+ mvwaddstr (misc->titlewin, 1, 0, "----------------------------------------");
+ waddstr (misc->titlewin, "----------------------------------------");
+ mvwprintw (misc->titlewin, 1, 0, gettext ("Go to page number: "));
echo ();
- wgetnstr (misc.titlewin, pn, 5);
+ wgetnstr (misc->titlewin, pn, 5);
noecho ();
- view_screen (misc);
- if (! *pn || atoi (pn) > misc.total_pages || ! atoi (pn))
+ view_screen (misc, daisy);
+ if (! *pn || atoi (pn) > misc->total_pages || ! atoi (pn))
{
beep ();
- skip_left (misc);
+ skip_left (misc, my_attribute, daisy);
skip_right (misc);
return;
} // if
- if (strcasestr (misc.daisy_version, "2.02"))
+ if (strcasestr (misc->daisy_version, "2.02"))
{
- xmlTextReaderClose (misc.reader);
- xmlDocPtr doc = xmlRecoverFile (misc.NCC_HTML);
- if (! (misc.reader = xmlReaderWalker (doc)))
+ xmlTextReaderClose (misc->reader);
+ xmlDocPtr doc = xmlRecoverFile (misc->NCC_HTML);
+ if (! (misc->reader = xmlReaderWalker (doc)))
{
- endwin ();
- printf (gettext ("\nCannot read %s\n"), misc.NCC_HTML);
- beep ();
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR,
+ gettext ("\nCannot read %s\n"), misc->NCC_HTML);
+ failure (str, e);
} // if
*href = 0;
while (1)
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return;
- if (strcasecmp (misc.tag, "a") == 0)
+ if (strcasecmp (misc->tag, "a") == 0)
{
strncpy (prev_href, href, MAX_STR - 1);
- strncpy (href, my_attribute.href, MAX_STR - 1);
+ strncpy (href, my_attribute->href, MAX_STR - 1);
do
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return;
- } while (! *misc.label);
- if (strcasecmp (misc.label, pn) == 0)
+ } while (! *misc->label);
+ if (strcasecmp (misc->label, pn) == 0)
break;
- } // if (strcasecmp (misc.tag, "a") == 0)
+ } // if (strcasecmp (misc->tag, "a") == 0)
} // while
if (*prev_href)
{
@@ -1271,117 +1255,125 @@ void go_to_page_number ()
*strchr (filename, '#') = 0;
} // if
} // if (*prev_href)
- for (misc.current = misc.total_items - 1; misc.current >= 0; misc.current--)
+ for (misc->current = misc->total_items - 1; misc->current >= 0; misc->current--)
{
- if (! daisy[misc.current].page_number)
+ if (! daisy[misc->current].page_number)
continue;
- if (atoi (pn) >= daisy[misc.current].page_number)
+ if (atoi (pn) >= daisy[misc->current].page_number)
break;
} // for
- misc.playing = misc.displaying = misc.current;
- view_screen (misc);
- misc.current_page_number = atoi (pn);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
- misc.just_this_item = -1;
- open_smil_file (daisy[misc.current].smil_file, anchor);
+ misc->playing = misc->displaying = misc->current;
+ view_screen (misc, daisy);
+ misc->current_page_number = atoi (pn);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
+ misc->just_this_item = -1;
+ open_smil_file (misc, my_attribute, daisy[misc->current].smil_file, anchor);
free (anchor);
return;
- } // if (strcasestr (misc.daisy_version, "2.02"))
+ } // if (strcasestr (misc->daisy_version, "2.02"))
- if (strcasestr (misc.daisy_version, "3"))
+ if (strcasestr (misc->daisy_version, "3"))
{
char *anchor = 0;
- xmlTextReaderClose (misc.reader);
- xmlDocPtr doc = xmlRecoverFile (misc.NCC_HTML);
- if (! (misc.reader = xmlReaderWalker (doc)))
+ xmlTextReaderClose (misc->reader);
+ xmlDocPtr doc = xmlRecoverFile (misc->NCC_HTML);
+ if (! (misc->reader = xmlReaderWalker (doc)))
{
- endwin ();
- printf (gettext ("\nCannot read %s\n"), misc.NCC_HTML);
- beep ();
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR,
+ gettext ("\nCannot read %s\n"), misc->NCC_HTML);
+ failure (str, e);
} // if
do
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
{
xmlFreeDoc (doc);
return;
} // if
- } while (strcasecmp (misc.tag, "pageTarget") != 0 ||
- strcasecmp (my_attribute.value, pn) != 0);
+ } while (strcasecmp (misc->tag, "pageTarget") != 0 ||
+ strcasecmp (my_attribute->value, pn) != 0);
do
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
{
- xmlTextReaderClose (misc.reader);
+ xmlTextReaderClose (misc->reader);
xmlFreeDoc (doc);
return;
} // if
- } while (strcasecmp (misc.tag, "content") != 0);
+ } while (strcasecmp (misc->tag, "content") != 0);
xmlFreeDoc (doc);
- if (strchr (my_attribute.src, '#'))
+ if (strchr (my_attribute->src, '#'))
{
- anchor = strdup (strchr (my_attribute.src, '#') + 1);
- *strchr (my_attribute.src, '#') = 0;
+ anchor = strdup (strchr (my_attribute->src, '#') + 1);
+ *strchr (my_attribute->src, '#') = 0;
} // if
// search current item
- for (misc.current = misc.total_items - 1; misc.current >= 0; misc.current--)
+ for (misc->current = misc->total_items - 1; misc->current >= 0; misc->current--)
{
- if (! daisy[misc.current].page_number)
+ if (! daisy[misc->current].page_number)
continue;
- if (atoi (pn) >= daisy[misc.current].page_number)
+ if (atoi (pn) >= daisy[misc->current].page_number)
break;
} // for
- misc.playing = misc.displaying = misc.current;
- view_screen (misc);
- misc.current_page_number = atoi (pn);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
- misc.just_this_item = -1;
- open_smil_file (my_attribute.src, anchor);
- } // if (strcasestr (misc.daisy_version, "3"))
+ misc->playing = misc->displaying = misc->current;
+ view_screen (misc, daisy);
+ misc->current_page_number = atoi (pn);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
+ misc->just_this_item = -1;
+ open_smil_file (misc, my_attribute, my_attribute->src, anchor);
+ } // if (strcasestr (misc->daisy_version, "3"))
} // go_to_page_number
-void go_to_time ()
+void go_to_time (misc_t *misc, daisy_t *daisy)
{
char time_str[10];
int secs;
- kill (misc.player_pid, SIGKILL);
- misc.player_pid = -2;
- mvwaddstr (misc.titlewin, 1, 0, "----------------------------------------");
- waddstr (misc.titlewin, "----------------------------------------");
- mvwprintw (misc.titlewin, 1, 0, gettext ("Go to time (MM:SS): "));
- echo ();
- wgetnstr (misc.titlewin, time_str, 5);
- noecho ();
- view_screen (misc);
+ kill (misc->player_pid, SIGKILL);
+ misc->player_pid = -2;
+ mvwaddstr (misc->titlewin, 1, 0, "----------------------------------------");
+ waddstr (misc->titlewin, "----------------------------------------");
+ while (1)
+ {
+ mvwprintw (misc->titlewin, 1, 0, gettext ("Go to time (MM:SS): "));
+ echo ();
+ wgetnstr (misc->titlewin, time_str, 5);
+ noecho ();
+ if (strlen (time_str) != 5)
+ beep ();
+ else
+ break;
+ } // while
+ view_screen (misc, daisy);
secs = (time_str[0] - 48) * 600 + (time_str[1] - 48)* 60 +
(time_str[3] - 48) * 10 + (time_str[4] - 48);
- misc.player_pid = play_track (misc.sound_dev, "alsa",
- daisy[misc.current].first_lsn + (secs * 75));
- misc.seconds = time (NULL) - secs;
- misc.playing = misc.displaying = misc.current;
+ if (secs >= daisy[misc->current].duration)
+ {
+ beep ();
+ go_to_time (misc, daisy);
+ } // if
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
+ daisy[misc->current].first_lsn + (secs * 75));
+ misc->seconds = time (NULL) - secs;
+ misc->playing = misc->displaying = misc->current;
} // go_to_time
-void select_next_output_device ()
+void select_next_output_device (misc_t *misc, daisy_t *daisy)
{
FILE *r;
int n, y;
size_t bytes;
char *list[10], *trash;
- wclear (misc.screenwin);
- wprintw (misc.screenwin, "\nSelect a soundcard:\n\n");
+ wclear (misc->screenwin);
+ wprintw (misc->screenwin, "\nSelect a soundcard:\n\n");
if (! (r = fopen ("/proc/asound/cards", "r")))
- {
- endwin ();
- beep ();
- puts (gettext ("Cannot read /proc/asound/cards"));
- fflush (stdout);
- _exit (1);
- } // if
+ failure (gettext ("Cannot read /proc/asound/cards"), errno);
for (n = 0; n < 10; n++)
{
list[n] = (char *) malloc (1000);
@@ -1391,21 +1383,21 @@ void select_next_output_device ()
trash = (char *) malloc (1000);
bytes = getline (&trash, &bytes, r);
free (trash);
- wprintw (misc.screenwin, " %s", list[n]);
+ wprintw (misc->screenwin, " %s", list[n]);
free (list[n]);
} // for
fclose (r);
y = 3;
- nodelay (misc.screenwin, FALSE);
+ nodelay (misc->screenwin, FALSE);
for (;;)
{
- wmove (misc.screenwin, y, 2);
- switch (wgetch (misc.screenwin))
+ wmove (misc->screenwin, y, 2);
+ switch (wgetch (misc->screenwin))
{
case 13:
- snprintf (misc.sound_dev, 15, "hw:%i", y - 3);
- view_screen (misc);
- nodelay (misc.screenwin, TRUE);
+ snprintf (misc->sound_dev, 15, "hw:%i", y - 3);
+ view_screen (misc, daisy);
+ nodelay (misc->screenwin, TRUE);
return;
case KEY_DOWN:
if (++y == n + 3)
@@ -1416,48 +1408,49 @@ void select_next_output_device ()
y = n + 2;
break;
default:
- view_screen (misc);
- nodelay (misc.screenwin, TRUE);
+ view_screen (misc, daisy);
+ nodelay (misc->screenwin, TRUE);
return;
} // switch
} // for
} // select_next_output_device
-void browse (char *wd)
+void browse (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char *wd)
{
int old_screen;
char str[MAX_STR];
- misc.current = 0;
- misc.just_this_item = -1;
- get_bookmark (misc);
- view_screen (misc);
- nodelay (misc.screenwin, TRUE);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
- if (misc.audiocd == 1)
+ misc->current = 0;
+ misc->just_this_item = -1;
+ get_bookmark (misc, my_attribute, daisy);
+ view_screen (misc, daisy);
+ nodelay (misc->screenwin, TRUE);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
+ if (misc->audiocd == 1)
{
- misc.depth = 1;
- view_screen (misc);
+ misc->depth = 1;
+ view_screen (misc, daisy);
} // if
for (;;)
{
- switch (wgetch (misc.screenwin))
+ switch (wgetch (misc->screenwin))
{
case 13: // ENTER
- misc.just_this_item = -1;
- view_screen (misc);
- misc.playing = misc.displaying = misc.current;
- misc.current_page_number = daisy[misc.playing].page_number;
- if (misc.player_pid > -1)
- kill (misc.player_pid, SIGKILL);
- misc.player_pid = -2;
- if (misc.discinfo)
+ misc->just_this_item = -1;
+ view_screen (misc, daisy);
+ misc->playing = misc->displaying = misc->current;
+ misc->current_page_number = daisy[misc->playing].page_number;
+ if (misc->player_pid > -1)
+ kill (misc->player_pid, SIGKILL);
+ misc->player_pid = -2;
+ if (misc->discinfo)
{
snprintf (str, MAX_STR - 1,
"cd \"%s\"; \"%s\" \"%s\"/\"%s\" -d %s",
- wd, PACKAGE, misc.daisy_mp,
- daisy[misc.current].daisy_mp, misc.sound_dev);
+ wd, PACKAGE, misc->daisy_mp,
+ daisy[misc->current].daisy_mp, misc->sound_dev);
switch (system (str))
{
default:
@@ -1466,7 +1459,7 @@ void browse (char *wd)
snprintf (str, MAX_STR - 1,
"cd \"%s\"; \"%s\" \"%s\" -d %s\n", wd, PACKAGE,
- misc.daisy_mp, misc.sound_dev);
+ misc->daisy_mp, misc->sound_dev);
switch (system (str))
{
default:
@@ -1475,61 +1468,61 @@ void browse (char *wd)
quit_daisy_player (misc);
_exit (0);
} // if
- if (misc.audiocd == 1)
+ if (misc->audiocd == 1)
{
- misc.player_pid = play_track (misc.sound_dev, "alsa",
- daisy[misc.current].first_lsn);
- misc.seconds = time (NULL);
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
+ daisy[misc->current].first_lsn);
+ misc->seconds = time (NULL);
} // if
- if (misc.audiocd == 0)
+ if (misc->audiocd == 0)
{
- open_smil_file (daisy[misc.current].smil_file,
- daisy[misc.current].anchor);
+ open_smil_file (misc, my_attribute, daisy[misc->current].smil_file,
+ daisy[misc->current].anchor);
} // if
- misc.start_time = 0;
+ misc->start_time = 0;
break;
case '/':
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- search (misc.current + 1, '/');
+ search (misc, my_attribute, daisy, misc->current + 1, '/');
break;
case ' ':
case KEY_IC:
case '0':
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- pause_resume (misc);
+ pause_resume (misc, my_attribute, daisy);
break;
case 'd':
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- store_to_disk (misc);
+ store_to_disk (misc, my_attribute, daisy);
break;
case 'e':
case '.':
case KEY_DC:
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- xmlTextReaderClose (misc.reader);
- quit_daisy_player ();
- while (kill (misc.player_pid, 0) == 0);
+ xmlTextReaderClose (misc->reader);
+ quit_daisy_player (misc);
+ while (kill (misc->player_pid, 0) == 0);
if (chdir ("/") == 0)
{
char cmd[MAX_CMD + 1];
- snprintf (cmd, MAX_CMD, "eject %s", misc.cd_dev);
+ snprintf (cmd, MAX_CMD, "eject %s", misc->cd_dev);
switch (system (cmd))
{
default:
@@ -1538,23 +1531,23 @@ void browse (char *wd)
} // if
_exit (0);
case 'f':
- if (misc.playing == -1)
+ if (misc->playing == -1)
{
beep ();
break;
} // if
- misc.current = misc.playing;
- previous_item (misc);
- view_screen (misc);
+ misc->current = misc->playing;
+ previous_item (misc, daisy);
+ view_screen (misc, daisy);
break;
case 'g':
- if (misc.audiocd == 1)
+ if (misc->audiocd == 1)
{
- go_to_time (misc);
+ go_to_time (misc, daisy);
break;
} // if
- if (misc.total_pages)
- go_to_page_number (misc);
+ if (misc->total_pages)
+ go_to_page_number (misc, my_attribute, daisy);
else
beep ();
break;
@@ -1563,114 +1556,114 @@ void browse (char *wd)
{
int flag = 0;
- if (misc.playing < 0)
+ if (misc->playing < 0)
flag = 1;
- if (! misc.discinfo)
- pause_resume (misc);
- misc.player_pid = -2;
- help (misc);
+ if (! misc->discinfo)
+ pause_resume (misc, my_attribute, daisy);
+ misc->player_pid = -2;
+ help (misc, daisy);
if (flag)
break;
- misc.playing = misc.displaying;
- if (misc.audiocd == 0)
+ misc->playing = misc->displaying;
+ if (misc->audiocd == 0)
{
- skip_left (misc);
+ skip_left (misc, my_attribute, daisy);
skip_right (misc);
} // if
- if (misc.audiocd == 1)
+ if (misc->audiocd == 1)
{
- misc.playing = -1;
- pause_resume (misc);
+ misc->playing = -1;
+ pause_resume (misc, my_attribute, daisy);
} // if
break;
}
case 'j':
case '5':
case KEY_B2:
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- if (misc.just_this_item != -1)
- misc.just_this_item = -1;
+ if (misc->just_this_item != -1)
+ misc->just_this_item = -1;
else
- misc.just_this_item = misc.current;
- mvwprintw (misc.screenwin, daisy[misc.displaying].y, 0, " ");
- if (misc.playing == -1)
- {
- misc.just_this_item = misc.displaying = misc.playing = misc.current;
- kill (misc.player_pid, SIGKILL);
- misc.player_pid = -2;
- if (misc.audiocd == 1)
+ misc->just_this_item = misc->current;
+ mvwprintw (misc->screenwin, daisy[misc->displaying].y, 0, " ");
+ if (misc->playing == -1)
+ {
+ misc->just_this_item = misc->displaying = misc->playing = misc->current;
+ kill (misc->player_pid, SIGKILL);
+ misc->player_pid = -2;
+ if (misc->audiocd == 1)
{
- misc.player_pid = play_track (misc.sound_dev, "alsa",
- daisy[misc.current].first_lsn);
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
+ daisy[misc->current].first_lsn);
}
else
- open_smil_file (daisy[misc.current].smil_file,
- daisy[misc.current].anchor);
+ open_smil_file (misc, my_attribute,
+ daisy[misc->current].smil_file, daisy[misc->current].anchor);
} // if
- wattron (misc.screenwin, A_BOLD);
- if (misc.just_this_item != -1 &&
- daisy[misc.displaying].screen == daisy[misc.playing].screen)
- mvwprintw (misc.screenwin, daisy[misc.displaying].y, 0, "J");
+ wattron (misc->screenwin, A_BOLD);
+ if (misc->just_this_item != -1 &&
+ daisy[misc->displaying].screen == daisy[misc->playing].screen)
+ mvwprintw (misc->screenwin, daisy[misc->displaying].y, 0, "J");
else
- mvwprintw (misc.screenwin, daisy[misc.displaying].y, 0, " ");
- wrefresh (misc.screenwin);
- wattroff (misc.screenwin, A_BOLD);
- misc.current_page_number = daisy[misc.playing].page_number;
+ mvwprintw (misc->screenwin, daisy[misc->displaying].y, 0, " ");
+ wrefresh (misc->screenwin);
+ wattroff (misc->screenwin, A_BOLD);
+ misc->current_page_number = daisy[misc->playing].page_number;
break;
case 'l':
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- change_level ('l');
+ change_level (misc, my_attribute, daisy, 'l');
break;
case 'L':
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- change_level ('L');
+ change_level (misc, my_attribute, daisy, 'L');
break;
case 'n':
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- search (misc.current + 1, 'n');
+ search (misc, my_attribute, daisy, misc->current + 1, 'n');
break;
case 'N':
- if (misc.discinfo)
+ if (misc->discinfo)
{
beep ();
break;
} // if
- search (misc.current - 1, 'N');
+ search (misc, my_attribute, daisy, misc->current - 1, 'N');
break;
case 'o':
- if (misc.playing == -1)
+ if (misc->playing == -1)
{
beep ();
break;
} // if
- pause_resume (misc);
- select_next_output_device (misc);
- misc.playing = misc.displaying;
- if (misc.audiocd == 0)
+ pause_resume (misc, my_attribute, daisy);
+ select_next_output_device (misc, daisy);
+ misc->playing = misc->displaying;
+ if (misc->audiocd == 0)
{
- skip_left (misc);
+ skip_left (misc, my_attribute, daisy);
skip_right (misc);
} // if
- if (misc.audiocd == 1)
+ if (misc->audiocd == 1)
{
- misc.playing = -1;
- pause_resume (misc);
+ misc->playing = -1;
+ pause_resume (misc, my_attribute, daisy);
} // if
break;
case 'p':
@@ -1680,202 +1673,173 @@ void browse (char *wd)
quit_daisy_player (misc);
_exit (0);
case 's':
- if (misc.audiocd == 0)
+ if (misc->audiocd == 0)
{
- kill (misc.player_pid, SIGKILL);
- misc.player_pid = -2;
+ kill (misc->player_pid, SIGKILL);
+ misc->player_pid = -2;
} // if
- if (misc.audiocd == 1)
+ if (misc->audiocd == 1)
{
- kill (misc.player_pid, SIGKILL);
+ kill (misc->player_pid, SIGKILL);
} // if
- misc.playing = misc.just_this_item = -1;
- view_screen (misc);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
+ misc->playing = misc->just_this_item = -1;
+ view_screen (misc, daisy);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
break;
case KEY_DOWN:
case '2':
- next_item (misc);
+ next_item (misc, daisy);
break;
case KEY_UP:
case '8':
- if (misc.current == 0)
+ if (misc->current == 0)
{
beep ();
break;
} // if
- misc.current--;
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
- previous_item (misc);
+ misc->current--;
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
+ previous_item (misc, daisy);
break;
case KEY_RIGHT:
case '6':
- if (misc.audiocd == 0)
+ if (misc->audiocd == 0)
skip_right (misc);
- if (misc.audiocd == 1)
- {
- switch (ftruncate (misc.pipefd[0], 0))
- {
- default:
- break;
- } // switch
- switch (ftruncate (misc.pipefd[1], 0))
- {
- default:
- break;
- } // switch
- paranoia_seek (misc.par, 225, SEEK_CUR);
- misc.lsn_cursor += 225;
- switch (ftruncate (misc.pipefd[0], 0))
- {
- default:
- break;
- } // switch
- switch (ftruncate (misc.pipefd[1], 0))
- {
- default:
- break;
- } // switch
+ if (misc->audiocd == 1)
+ {
+ kill (misc->player_pid, SIGKILL);
+ misc->lsn_cursor += 225;
+ misc->displaying = misc->playing = misc->current;
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
+ misc->lsn_cursor);
+// misc->seconds = time (NULL) - misc->seconds;
} // if
break;
case KEY_LEFT:
case '4':
- if (misc.audiocd == 0)
- skip_left (misc);
- if (misc.audiocd == 1)
- {
- switch (ftruncate (misc.pipefd[0], 0))
- {
- default:
- break;
- } // switch
- switch (ftruncate (misc.pipefd[1], 0))
- {
- default:
- break;
- } // switch
- paranoia_seek (misc.par, -225, SEEK_CUR);
- misc.lsn_cursor -= 225;
- switch (ftruncate (misc.pipefd[0], 0))
- {
- default:
- break;
- } // switch
- switch (ftruncate (misc.pipefd[1], 0))
- {
- default:
- break;
- } // switch
+ if (misc->audiocd == 0)
+ skip_left (misc, my_attribute, daisy);
+ if (misc->audiocd == 1)
+ {
+ kill (misc->player_pid, SIGKILL);
+ misc->lsn_cursor -= 225;
+ misc->displaying = misc->playing = misc->current;
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
+ misc->lsn_cursor);
+// misc->seconds = time (NULL) - misc->seconds;
} // if
break;
case KEY_NPAGE:
case '3':
- if (daisy[misc.current].screen == daisy[misc.total_items - 1].screen)
+ if (daisy[misc->current].screen == daisy[misc->total_items - 1].screen)
{
beep ();
break;
} // if
- old_screen = daisy[misc.current].screen;
- while (daisy[++misc.current].screen == old_screen);
- view_screen (misc);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
+ old_screen = daisy[misc->current].screen;
+ while (daisy[++misc->current].screen == old_screen);
+ view_screen (misc, daisy);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
break;
case KEY_PPAGE:
case '9':
- if (daisy[misc.current].screen == 0)
+ if (daisy[misc->current].screen == 0)
{
beep ();
break;
} // if
- old_screen = daisy[misc.current].screen;
- while (daisy[--misc.current].screen == old_screen);
- misc.current -= misc.max_y - 1;
- view_screen (misc);
- wmove (misc.screenwin, daisy[misc.current].y, daisy[misc.current].x);
+ old_screen = daisy[misc->current].screen;
+ while (daisy[--misc->current].screen == old_screen);
+ misc->current -= misc->max_y - 1;
+ view_screen (misc, daisy);
+ wmove (misc->screenwin, daisy[misc->current].y, daisy[misc->current].x);
break;
case ERR:
break;
case 'U':
case '+':
- if (misc.speed >= 2)
+ if (misc->speed >= 2)
{
beep ();
break;
} // if
- misc.speed += 0.1;
- if (misc.audiocd == 1)
+ misc->speed += 0.1;
+ if (misc->audiocd == 1)
{
- kill (misc.player_pid, SIGKILL);
+ kill (misc->player_pid, SIGKILL);
lsn_t start;
- start = (lsn_t) (misc.start_time + (float) (time (NULL) - misc.seconds) * 75) +
- daisy[misc.playing].first_lsn;
- misc.player_pid = play_track (misc.sound_dev, "alsa",
+ start = (lsn_t) (misc->start_time +
+ (float) (time (NULL) - misc->seconds) * 75) +
+ daisy[misc->playing].first_lsn;
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
start);
- view_screen ();
+ view_screen (misc, daisy);
break;
} // if
- skip_left (misc);
- kill (misc.player_pid, SIGKILL);
- view_screen ();
+ skip_left (misc, my_attribute, daisy);
+ kill (misc->player_pid, SIGKILL);
+ view_screen (misc, daisy);
break;
case 'D':
case '-':
- if (misc.speed <= 0.3)
+ if (misc->speed <= 0.3)
{
beep ();
break;
} // if
- misc.speed -= 0.1;
- if (misc.audiocd == 1)
+ misc->speed -= 0.1;
+ if (misc->audiocd == 1)
{
- kill (misc.player_pid, SIGKILL);
+ kill (misc->player_pid, SIGKILL);
lsn_t start;
- start = (lsn_t) (misc.start_time + (float) (time (NULL) - misc.seconds) * 75) +
- daisy[misc.playing].first_lsn;
- misc.player_pid = play_track (misc.sound_dev, "alsa",
+ start = (lsn_t) (misc->start_time +
+ (float) (time (NULL) - misc->seconds) * 75) +
+ daisy[misc->playing].first_lsn;
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
start);
- view_screen ();
+ view_screen (misc, daisy);
break;
} // if
- skip_left (misc);
- kill (misc.player_pid, SIGKILL);
- view_screen ();
+ skip_left (misc, my_attribute, daisy);
+ kill (misc->player_pid, SIGKILL);
+ view_screen (misc, daisy);
break;
case KEY_HOME:
case '*':
case '7':
- misc.speed = 1;
- if (misc.audiocd == 1)
+ misc->speed = 1;
+ if (misc->audiocd == 1)
{
- kill (misc.player_pid, SIGKILL);
+ kill (misc->player_pid, SIGKILL);
lsn_t start;
- start = (lsn_t) (misc.start_time + (float) (time (NULL) - misc.seconds) * 75) +
- daisy[misc.playing].first_lsn;
- misc.player_pid = play_track (misc.sound_dev, "alsa",
+ start = (lsn_t) (misc->start_time +
+ (float) (time (NULL) - misc->seconds) * 75) +
+ daisy[misc->playing].first_lsn;
+ misc->player_pid = play_track (misc, misc->sound_dev, "alsa",
start);
- view_screen ();
+ view_screen (misc, daisy);
break;
} // if
- kill (misc.player_pid, SIGKILL);
- skip_left (misc);
+ kill (misc->player_pid, SIGKILL);
+ skip_left (misc, my_attribute, daisy);
skip_right (misc);
- view_screen ();
+ view_screen (misc, daisy);
break;
default:
beep ();
break;
} // switch
- if (misc.playing > -1 && misc.audiocd == 0)
+ if (misc->playing > -1 && misc->audiocd == 0)
{
- play_clip (misc);
- view_time (misc);
+ play_clip (misc, my_attribute, daisy);
+ view_time (misc, daisy);
} // if
- if (misc.playing == -1 || misc.audiocd == 0)
+ if (misc->playing == -1 || misc->audiocd == 0)
{
fd_set rfds;
struct timeval tv;
@@ -1884,76 +1848,70 @@ void browse (char *wd)
FD_SET (0, &rfds);
tv.tv_sec = 0;
tv.tv_usec = 100000;
-// pause till a key has been pressed or 0.1 misc.seconds are elapsed
+// pause till a key has been pressed or 0.1 misc->seconds are elapsed
select (1, &rfds, NULL, NULL, &tv);
} // if
- if (misc.playing > -1 && misc.audiocd == 1)
+ if (misc->playing > -1 && misc->audiocd == 1)
{
int16_t *p_readbuf;
- if (! (p_readbuf = paranoia_read (misc.par, NULL)))
+ if (! (p_readbuf = paranoia_read (misc->par, NULL)))
break;
- switch (write (misc.pipefd[1], p_readbuf, CDIO_CD_FRAMESIZE_RAW))
+ switch (write (misc->pipefd[1], p_readbuf, CDIO_CD_FRAMESIZE_RAW))
{
default:
break;
} // switch
- misc.lsn_cursor++;
- if (misc.lsn_cursor > daisy[misc.playing].last_lsn)
+ misc->lsn_cursor++;
+ if (misc->lsn_cursor > daisy[misc->playing].last_lsn)
{
- misc.start_time = 0;
- misc.current = misc.displaying = ++misc.playing;
- misc.lsn_cursor = daisy[misc.playing].first_lsn;
- if (misc.current >= misc.total_items)
+ misc->start_time = 0;
+ misc->current = misc->displaying = ++misc->playing;
+ misc->lsn_cursor = daisy[misc->playing].first_lsn;
+ if (misc->current >= misc->total_items)
{
struct passwd *pw;
pw = getpwuid (geteuid ());
quit_daisy_player (misc);
snprintf (str, MAX_STR - 1, "%s/.daisy-player/%s%s",
- pw->pw_dir, misc.bookmark_title, get_mcn (misc));
+ pw->pw_dir, misc->bookmark_title, get_mcn (misc));
unlink (str);
_exit (0);
} // if
- if (misc.just_this_item > -1)
+ if (misc->just_this_item > -1)
{
- kill (misc.player_pid, SIGKILL);
- misc.playing = misc.just_this_item = -1;
+ kill (misc->player_pid, SIGKILL);
+ misc->playing = misc->just_this_item = -1;
} // if
- view_screen (misc);
- misc.seconds = time (NULL);
+ view_screen (misc, daisy);
+ misc->seconds = time (NULL);
} // if
- view_time (misc);
+ view_time (misc, daisy);
} // if
} // for
} // browse
-void usage (char *argv)
+void usage ()
{
printf (gettext ("Daisy-player - Version %s\n"), PACKAGE_VERSION);
puts ("(C)2003-2014 J. Lemmens");
printf (gettext ("\nUsage: %s [directory_with_a_Daisy-structure] "),
- basename (argv));
+ PACKAGE);
printf (gettext ("[-c cdrom_device] [-d ALSA_sound_device] [-n | -y]\n"));
fflush (stdout);
_exit (1);
} // usage
-char *get_mount_point ()
+char *get_mount_point (misc_t *misc)
{
FILE *proc;
size_t len = 0;
char *str = NULL;
if (! (proc = fopen ("/proc/mounts", "r")))
- {
- endwin ();
- beep ();
- puts (gettext ("\nCannot read /proc/mounts."));
- fflush (stdout);
- _exit (1);
- } // if
+ failure (gettext ("\nCannot read /proc/mounts."), errno);
do
{
str = malloc (len + 1);
@@ -1963,110 +1921,115 @@ char *get_mount_point ()
fclose (proc);
if (strcasestr (str, "iso9660"))
{
- strncpy (misc.daisy_mp, strchr (str, ' ') + 1, MAX_STR - 1);
- *strchr (misc.daisy_mp, ' ') = 0;
+ strncpy (misc->daisy_mp, strchr (str, ' ') + 1, MAX_STR - 1);
+ *strchr (misc->daisy_mp, ' ') = 0;
free (str);
- return misc.daisy_mp;
+ return misc->daisy_mp;
} // if
free (str);
return NULL;
} // get_mount_point
-void handle_discinfo (char *discinfo_html)
+void handle_discinfo (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char *discinfo_html)
{
int h, m, s;
float t = 0;
xmlTextReaderPtr di, ncc;
+ xmlDocPtr doc;
- xmlDocPtr doc = xmlRecoverFile (discinfo_html);
+ doc = xmlRecoverFile (discinfo_html);
if (! (di = xmlReaderWalker (doc)))
{
- endwin ();
- beep ();
- printf (gettext ("\nCannot read %s\n"), discinfo_html);
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR, gettext ("\nCannot read %s\n"), discinfo_html);
+ failure (str, e);
} // if (! (di = xmlReaderWalker (doc)
while (1)
{
- if (! get_tag_or_label (di))
+ if (! get_tag_or_label (misc, my_attribute, di))
break;
- if (strcasecmp (misc.tag, "title") == 0)
+ if (strcasecmp (misc->tag, "title") == 0)
{
do
{
- if (! get_tag_or_label (di))
+ if (! get_tag_or_label (misc, my_attribute, di))
break;
- } while ( !*misc.label);
- strncpy (misc.daisy_title, misc.label, MAX_STR - 1);
- } // if (strcasecmp (misc.tag, "title") == 0)
- if (strcasecmp (misc.tag, "a") == 0)
+ } while ( !*misc->label);
+ strncpy (misc->daisy_title, misc->label, MAX_STR - 1);
+ } // if (strcasecmp (misc->tag, "title") == 0)
+ if (strcasecmp (misc->tag, "a") == 0)
{
- strncpy (daisy[misc.current].filename, my_attribute.href, MAX_STR - 1);
- xmlDocPtr doc = xmlRecoverFile (daisy[misc.current].filename);
+ strncpy (daisy[misc->current].filename, my_attribute->href, MAX_STR - 1);
+ xmlDocPtr doc = xmlRecoverFile (daisy[misc->current].filename);
if (! (ncc = xmlReaderWalker (doc)))
{
- endwin ();
- beep ();
- printf (gettext ("\nCannot read %s\n"), daisy[misc.current].filename);
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR,
+ gettext ("\nCannot read %s\n"), daisy[misc->current].filename);
+ failure (str, e);
} // if
do
{
- *misc.ncc_totalTime = 0;
- if (! get_tag_or_label (ncc))
+ *misc->ncc_totalTime = 0;
+ if (! get_tag_or_label (misc, my_attribute, ncc))
break;
- } while (! *misc.ncc_totalTime);
- daisy[misc.current].duration = read_time (misc.ncc_totalTime);
- t += daisy[misc.current].duration;
+ } while (! *misc->ncc_totalTime);
+ daisy[misc->current].duration = read_time (misc->ncc_totalTime);
+ t += daisy[misc->current].duration;
xmlTextReaderClose (ncc);
xmlFreeDoc (doc);
do
{
- if (! get_tag_or_label (di))
+ if (! get_tag_or_label (misc, my_attribute, di))
break;
- } while (! *misc.label);
- strncpy (daisy[misc.current].label, misc.label, MAX_STR - 1);
- strncpy (daisy[misc.current].daisy_mp, dirname (daisy[misc.current].filename),
+ } while (! *misc->label);
+ strncpy (daisy[misc->current].label, misc->label, MAX_STR - 1);
+ strncpy (daisy[misc->current].daisy_mp, dirname (daisy[misc->current].filename),
MAX_STR - 1);
- daisy[misc.current].level = 1;
- daisy[misc.current].x = 0;
- daisy[misc.current].y = misc.displaying;
- daisy[misc.current].screen = misc.current / misc.max_y;
- misc.current++;
- misc.displaying++;
- } // if (strcasecmp (misc.tag, "a") == 0)
+ daisy[misc->current].level = 1;
+ daisy[misc->current].x = 0;
+ daisy[misc->current].y = misc->displaying;
+ daisy[misc->current].screen = misc->current / misc->max_y;
+ misc->current++;
+ misc->displaying++;
+ } // if (strcasecmp (misc->tag, "a") == 0)
} // while
xmlTextReaderClose (di);
xmlFreeDoc (doc);
- misc.total_items = misc.current;
- misc.total_time = t;
+ misc->total_items = misc->current;
+ misc->total_time = t;
h = t / 3600;
t -= h * 3600;
m = t / 60;
t -= m * 60;
s = t;
- snprintf (misc.ncc_totalTime, MAX_STR - 1, "%02d:%02d:%02d", h, m, s);
- misc.depth = 1;
- view_screen (misc);
+ snprintf (misc->ncc_totalTime, MAX_STR - 1, "%02d:%02d:%02d", h, m, s);
+ misc->depth = 1;
+ view_screen (misc, daisy);
} // handle_discinfo
int main (int argc, char *argv[])
{
int opt;
char str[MAX_STR], DISCINFO_HTML[MAX_STR], start_wd[MAX_STR];
+ misc_t misc;
+ my_attribute_t my_attribute;
+ daisy_t *daisy = NULL;
-// jos LIBXML_TEST_VERSION // libxml2
misc.daisy_player_pid = getpid ();
misc.speed = 1;
misc.playing = misc.just_this_item = -1;
misc.discinfo = 0;
strncpy (misc.cd_dev, "/dev/sr0", 15);
- atexit (quit_daisy_player);
signal (SIGCHLD, player_ended);
- signal (SIGTERM, quit_daisy_player);
- read_rc (misc);
+ read_rc (&misc, &my_attribute);
setlocale (LC_ALL, "");
setlocale (LC_NUMERIC, "C");
textdomain (PACKAGE);
@@ -2074,7 +2037,7 @@ int main (int argc, char *argv[])
opterr = 0;
while ((opt = getopt (argc, argv, "c:d:ny")) != -1)
{
- switch (opt)
+ switch (opt)
{
case 'c':
strncpy (misc.cd_dev, optarg, 15);
@@ -2098,45 +2061,21 @@ int main (int argc, char *argv[])
} // switch
break;
default:
- usage (PACKAGE);
+ usage ();
} // switch
} // while
initscr ();
if (! (misc.titlewin = newwin (2, 80, 0, 0)) ||
! (misc.screenwin = newwin (23, 80, 2, 0)))
- {
- endwin ();
- beep ();
- printf ("No curses\n");
- fflush (stdout);
- _exit (1);
- } // if
+ failure ("No curses", errno);
fclose (stderr);
getmaxyx (misc.screenwin, misc.max_y, misc.max_x);
printw ("(C)2003-2014 J. Lemmens\n");
printw (gettext ("Daisy-player - Version %s\n"), PACKAGE_VERSION);
printw (gettext ("A parser to play Daisy CD's with Linux\n"));
- if (system ("eject -h 2> /dev/null") != 256)
- {
- endwin ();
- beep ();
- printf (gettext ("\nDaisy-player needs the \"eject\" programme.\n"));
- printf (gettext ("Please install it and try again.\n"));
- fflush (stdout);
- _exit (1);
- } // if
- if (system ("madplay -h > /dev/null") > 0)
- {
- endwin ();
- beep ();
- printf (gettext ("\nDaisy-player needs the \"madplay\" programme.\n"));
- printf (gettext ("Please install it and try again.\n"));
- fflush (stdout);
- _exit (1);
- } // if
// set the CD speed so it makes less noise
- set_drive_speed (4);
+ set_drive_speed (&misc, 4);
printw (gettext ("Scanning for a Daisy CD..."));
refresh ();
@@ -2158,7 +2097,7 @@ int main (int argc, char *argv[])
printf ("%s: %s\n", argv[optind], strerror (e));
beep ();
fflush (stdout);
- usage (PACKAGE);
+ usage ();
} // if
if (strcasestr (magic_file (myt, argv[optind]), "directory"))
{
@@ -2179,23 +2118,7 @@ int main (int argc, char *argv[])
str = strdup ("/tmp/daisy-player.XXXXXX");
if (! mkdtemp (str))
- {
- endwin ();
- printf ("mkdtemp ()\n");
- beep ();
- fflush (stdout);
- _exit (1);
- } // if
- if (system ("unar -h > /dev/null") != 0)
- {
- endwin ();
- beep ();
- printf (gettext (
- "\nDaisy-player needs the \"unar\" programme.\n"));
- printf (gettext ("Please install it and try again.\n"));
- fflush (stdout);
- _exit (1);
- } // if
+ failure ("mkdtemp ()", errno);
snprintf (cmd, MAX_CMD - 1, "unar \"%s\" -o %s > /dev/null",
argv[optind], str);
switch (system (cmd))
@@ -2210,16 +2133,7 @@ int main (int argc, char *argv[])
int entries = 0;
if (! (dir = opendir (str)))
- {
- int e;
-
- e = errno;
- endwin ();
- beep ();
- printf ("\n%s: %s\n", str, strerror (e));
- fflush (stdout);
- _exit (1);
- } // if
+ failure (str, errno);
while ((dirent = readdir (dir)) != NULL)
{
if (strcasecmp (dirent->d_name, ".") == 0 ||
@@ -2237,15 +2151,15 @@ int main (int argc, char *argv[])
endwin ();
printf (gettext ("\nNo DAISY-CD or Audio-cd found\n"));
beep ();
- fflush (stdout);
- usage (PACKAGE);
+ usage ();
} // if
magic_close (myt);
} // if there is an argument
else
// try the default block device (/dev/sr0)
{
- char cmd[MAX_CMD];
+ char cmd[MAX_CMD], *str, *tmp;
+ size_t s;
time_t start;
FILE *r;
@@ -2265,45 +2179,42 @@ int main (int argc, char *argv[])
endwin ();
beep ();
printf ("/run/udev/data/b11:0: %s\n\n", gettext (strerror (e)));
- fflush (stdout);
- usage (PACKAGE);
+ usage ();
} // if
+ tmp = strdup ("/tmp/daisy-player.XXXXXX");
+ strncpy (misc.daisy_mp, mkdtemp (tmp), MAX_STR);
+ str = malloc (MAX_STR);
+ s = MAX_STR - 1;
while (1)
{
- char *str;
- size_t s;
-
- str = malloc (MAX_STR);
- s = MAX_STR - 1;
switch (getline (&str, &s, r))
{
default:
break;
} // switch
- if (strcasestr (str, "TRACK_COUNT_DATA=1"))
+ if (time (NULL) - start >= 30)
+ failure (gettext ("No Daisy CD in drive."), errno);
+ if (feof (r))
+ {
+ r = freopen ("/run/udev/data/b11:0", "r", r);
+ continue;
+ } // if
+
+ if (strcasestr (str, "TRACK_COUNT_DATA"))
{
- if (! get_mount_point ())
+ if (! get_mount_point (&misc))
// if not found a mounted cd, try to mount one
{
- char cmd[MAX_CMD + 1], *tmp;
-
- tmp = strdup ("/tmp/daisy-player.XXXXXX");
- strncpy (misc.daisy_mp, mkdtemp (tmp), MAX_STR);
snprintf (cmd, MAX_CMD,
- "udisksctl mount -b %s > /dev/null", misc.cd_dev);
- if (system (cmd))
+ "udisksctl mount -b %s > /dev/null", misc.cd_dev);
+ switch (system (cmd))
{
- endwin ();
- beep ();
- printf (gettext
- ("\nDaisy-player needs the \"udisksctl\" programme.\n")); printf (gettext ("Please install it and try again.\n"));
- fflush (stdout);
- _exit (1);
- } // if
- get_mount_point ();
+ break;
+ } // switch
+ get_mount_point (&misc);
} // if
break;
- } // if TRACK_COUNT_DATA=1
+ } // TRACK_COUNT_DATA"
if (strcasestr (str, "TRACK_COUNT_AUDIO"))
{
@@ -2315,21 +2226,12 @@ int main (int argc, char *argv[])
refresh ();
strncpy (misc.bookmark_title, "Audio-CD", MAX_STR - 1);
strncpy (misc.daisy_title, "Audio-CD", MAX_STR - 1);
- init_paranoia (misc.cd_dev);
- get_toc_audiocd (misc.cd_dev);
+ init_paranoia (&misc);
+ daisy = get_number_of_tracks (&misc);
+ get_toc_audiocd (&misc, daisy);
strncpy (misc.daisy_mp, "/tmp", MAX_STR - 1);
break;
- } // if TRACK_COUNT_AUDIO
- if (time (NULL) - start >= 30)
- {
- endwin ();
- puts (gettext ("No Daisy CD in drive."));
- fflush (stdout);
- beep ();
- _exit (0);
- } // if
- if (feof (r))
- r = freopen ("/run/udev/data/b11:0", "r", r);
+ } // TRACK_COUNT_AUDIO
} // while
fclose (r);
} // if use misc.cd_dev
@@ -2341,40 +2243,43 @@ int main (int argc, char *argv[])
if (chdir (misc.daisy_mp) == -1)
{
int e;
+ char str[MAX_STR];
e = errno;
- endwin ();
- beep ();
- printf ("\ndaisy_mp %s: %s\n", misc.daisy_mp, strerror (e));
- fflush (stdout);
- _exit (1);
+ snprintf (str, MAX_STR, "\ndaisy_mp %s", misc.daisy_mp);
+ failure (str, e);
} // if
if (misc.audiocd == 0)
{
+ daisy = create_daisy_struct (&misc, &my_attribute);
snprintf (DISCINFO_HTML, MAX_STR - 1, "discinfo.html");
if (access (DISCINFO_HTML, R_OK) == 0)
- handle_discinfo (DISCINFO_HTML);
+ handle_discinfo (&misc, &my_attribute, daisy, DISCINFO_HTML);
if (! misc.discinfo)
{
snprintf (misc.NCC_HTML, MAX_STR - 1, "ncc.html");
if (access (misc.NCC_HTML, R_OK) == 0)
{
- xmlDocPtr doc = xmlRecoverFile (misc.NCC_HTML);
+ xmlDocPtr doc;
+
+ doc = xmlRecoverFile (misc.NCC_HTML);
if (! (misc.reader = xmlReaderWalker (doc)))
{
- endwin ();
- beep ();
- printf (gettext ("\nCannot read %s\n"), misc.NCC_HTML);
- fflush (stdout);
- _exit (1);
+ int e;
+ char str[MAX_STR];
+
+ e = errno;
+ snprintf (str, MAX_STR,
+ gettext ("\nCannot read %s\n"), misc.NCC_HTML);
+ failure (str, e);
} // if
while (1)
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (&misc, &my_attribute, misc.reader))
break;
if (strcasecmp (misc.tag, "title") == 0)
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (&misc, &my_attribute, misc.reader))
break;
if (*misc.label)
{
@@ -2392,17 +2297,18 @@ int main (int argc, char *argv[])
} // if
} // if
} // while
- read_daisy_2 (misc);
+ read_daisy_2 (&misc, &my_attribute, daisy);
}
else
{
- read_daisy_3 (misc);
+ read_daisy_3 (&misc, &my_attribute, daisy);
strncpy (misc.daisy_version, "3", 2);
} // if
if (misc.total_items == 0)
misc.total_items = 1;
} // if (! misc.discinfo);
} // if misc.audiocd == 0
+
wattron (misc.titlewin, A_BOLD);
snprintf (str, MAX_STR - 1, gettext
("Daisy-player - Version %s - (C)2014 J. Lemmens"),
@@ -2424,16 +2330,7 @@ int main (int argc, char *argv[])
*misc.search_str = 0;
snprintf (misc.tmp_wav, MAX_STR, "/tmp/daisy-player_XXXXXX");
if ((misc.tmp_wav_fd = mkstemp (misc.tmp_wav)) == 01)
- {
- int e;
-
- e = errno;
- endwin ();
- beep ();
- printf ("%s\n", strerror (e));
- fflush (stdout);
- _exit (0);
- } // if
- browse (start_wd);
+ failure ("mkstemp ()", errno);
+ browse (&misc, &my_attribute, daisy, start_wd);
return 0;
} // main
diff --git a/src/daisy.h b/src/daisy.h
index c986293..612a59b 100644
--- a/src/daisy.h
+++ b/src/daisy.h
@@ -46,24 +46,24 @@
#include <cdio/disc.h>
#include <magic.h>
-#define max_phrase_len 50000
+#define MAX_PHRASE_LEN 2000
#define MAX_CMD 512
#define MAX_STR 256
#define MAX_TAG 1024
-typedef struct daisy
+typedef struct Daisy
{
int playorder, x, y, screen, n_phrases;
float begin, duration;
char smil_file[MAX_STR], anchor[MAX_STR], class[MAX_STR];
- char label[max_phrase_len];
+ char label[MAX_PHRASE_LEN];
int level, page_number;
char daisy_mp[MAX_STR]; // discinfo
char filename[MAX_STR]; // Audio-CD
lsn_t first_lsn, last_lsn;
} daisy_t;
-typedef struct my_attribute
+typedef struct My_attribute
{
char class[MAX_STR],
clip_begin[MAX_STR],
@@ -90,7 +90,7 @@ typedef struct my_attribute
value[MAX_STR];
} my_attribute_t;
-typedef struct misc
+typedef struct Misc
{
int discinfo, playing, just_this_item, audiocd, current_page_number;
int current, max_y, max_x, total_items, level, displaying;
@@ -103,7 +103,7 @@ typedef struct misc
char NCC_HTML[MAX_STR], ncc_totalTime[MAX_STR];
char daisy_version[MAX_STR], daisy_title[MAX_STR], daisy_language[MAX_STR];
char daisy_mp[MAX_STR];
- char tag[MAX_TAG], label[max_phrase_len];
+ char tag[MAX_TAG], label[MAX_PHRASE_LEN];
char bookmark_title[MAX_STR], search_str[MAX_STR];
char *wd, cd_dev[MAX_STR], sound_dev[MAX_STR];
char cddb_flag, opf_name[MAX_STR], ncx_name[MAX_STR];
@@ -115,3 +115,31 @@ typedef struct misc
CdIo_t *p_cdio;
lsn_t lsn_cursor;
} misc_t;
+
+extern void save_rc (misc_t *);
+extern char *get_mcn (misc_t *);
+extern int get_tag_or_label (misc_t *, my_attribute_t *,
+ xmlTextReaderPtr);
+extern void get_label (misc_t *, daisy_t *, int);
+extern void parse_ncx (misc_t *, my_attribute_t *, daisy_t *, char *);
+extern void usage ();
+extern pid_t play_track (misc_t *, char *, char *, lsn_t);
+extern void get_clips (misc_t *, char *, char *);
+extern void open_smil_file (misc_t *, my_attribute_t *, char *, char *);
+extern void play_now (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy);
+extern void get_page_number_3 (misc_t *, my_attribute_t *);
+extern void skip_left (misc_t *, my_attribute_t *, daisy_t *);
+extern void skip_right (misc_t *);
+extern void set_drive_speed (misc_t *, int);
+extern void quit_daisy_player (misc_t *);
+extern void read_daisy_3 (misc_t *, my_attribute_t *, daisy_t *);
+void parse_smil_3 (misc_t *, my_attribute_t *, daisy_t *);
+extern float read_time (char *);
+extern void init_paranoia (misc_t *);
+extern void get_toc_audiocd (misc_t *, daisy_t *);
+extern void playfile (misc_t *, char *, char *, char *, char *, char *);
+extern void view_screen (misc_t *, daisy_t *);
+extern daisy_t *create_daisy_struct (misc_t *, my_attribute_t *);
+extern daisy_t *get_number_of_tracks (misc_t *);
+extern void failure (char *, int);
diff --git a/src/daisy3.c b/src/daisy3.c
index 0922cf1..fd2cc58 100644
--- a/src/daisy3.c
+++ b/src/daisy3.c
@@ -18,17 +18,75 @@
#include "daisy.h"
-extern my_attribute_t my_attribute;
-extern daisy_t daisy[];
-extern misc_t misc;
+void failure (char *str, int e)
+{
+ endwin ();
+ beep ();
+ printf ("%s: %s\n", str, strerror (e));
+ fflush (stdout);
+ _exit (-1);
+} // failure
+
+daisy_t *create_daisy_struct (misc_t *misc, my_attribute_t *my_attribute)
+{
+ int items;
+ xmlTextReaderPtr ncx;
+ xmlDocPtr doc;
+ char cmd[MAX_CMD], path[MAX_STR];
+ FILE *p;
-void parse_ncx (char *);
-void check_phrases ();
-void get_label (int, int);
-extern void usage (char *);
+ *misc->daisy_version = *path= 0;
+ strncpy (cmd, "find -iname \"ncc.html\" -print0", MAX_CMD - 1);
+ if ((p = popen (cmd, "r")) == NULL)
+ failure (cmd, errno);
+ switch (fread (path, MAX_STR - 1, 1, p))
+ {
+ default:
+ break;
+ } // switch
+ if (*path)
+ strncpy (misc->daisy_version, "2.02", 4);
+ else
+ {
+ strncpy (cmd, "find -iname \"*.ncx\" -print0", MAX_CMD - 1);
+ if ((p = popen (cmd, "r")) == NULL)
+ failure (cmd, errno);
+ switch (fread (path, MAX_STR - 1, 1, p))
+ {
+ default:
+ break;
+ } // switch
+ if (*path)
+ strncpy (misc->daisy_version, "3", 2);
+ } // if
+ pclose (p);
+ items = 0;
+ doc = xmlRecoverFile (path);
+ ncx = xmlReaderWalker (doc);
+ while (1)
+ {
+ if (! get_tag_or_label (misc, my_attribute, ncx))
+ break;
+ if (strcasestr (misc->daisy_version, "2.02"))
+ if (strcasecmp (misc->tag, "h1") == 0 ||
+ strcasecmp (misc->tag, "h2") == 0 ||
+ strcasecmp (misc->tag, "h3") == 0 ||
+ strcasecmp (misc->tag, "h4") == 0 ||
+ strcasecmp (misc->tag, "h5") == 0 ||
+ strcasecmp (misc->tag, "h6") == 0)
+ items++;
+ if (strcasestr (misc->daisy_version, "3"))
+ if (strcasecmp (misc->tag, "navPoint") == 0)
+ items++;
+ } // while
+ xmlTextReaderClose (ncx);
+ if (doc != NULL)
+ xmlFreeDoc (doc);
+ misc->total_items = items;
+ return (daisy_t *) malloc (items * sizeof (daisy_t));
+} // create_daisy_struct
-float read_time (char *p)
-{
+float read_time (char *p){
char *h, *m, *s;
s = strrchr (p, ':') + 1;
@@ -48,11 +106,11 @@ float read_time (char *p)
return atoi (h) * 3600 + atoi (m) * 60 + (float) atof (s);
} // read_time
-void get_clips (char *orig_begin, char *end)
+void get_clips (misc_t *misc, char *orig_begin, char *end)
{
char begin_str[MAX_STR], *begin;
- if (misc.audiocd == 1)
+ if (misc->audiocd == 1)
return;
strncpy (begin_str, orig_begin, MAX_STR - 1);
begin = begin_str;
@@ -61,9 +119,9 @@ void get_clips (char *orig_begin, char *end)
if (strchr (begin, 's'))
*strchr (begin, 's') = 0;
if (! strchr (begin, ':'))
- misc.clip_begin = (float) atof (begin);
+ misc->clip_begin = (float) atof (begin);
else
- misc.clip_begin = read_time (begin);
+ misc->clip_begin = read_time (begin);
// fill end
while (! isdigit (*end))
@@ -71,61 +129,62 @@ void get_clips (char *orig_begin, char *end)
if (strchr (end, 's'))
*strchr (end, 's') = 0;
if (! strchr (end, ':'))
- misc.clip_end = (float) atof (end);
+ misc->clip_end = (float) atof (end);
else
- misc.clip_end = read_time (end);
+ misc->clip_end = read_time (end);
} // get_clips
-void get_attributes (xmlTextReaderPtr reader)
+void get_attributes (misc_t *misc, my_attribute_t *my_attribute,
+ xmlTextReaderPtr reader)
{
char attr[MAX_STR];
snprintf (attr, MAX_STR - 1, "%s", (char *)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "class"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.class, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->class, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*) xmlTextReaderGetAttribute
(reader, (const xmlChar *) "clip-begin"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.clip_begin, MAX_STR - 1,
+ snprintf (my_attribute->clip_begin, MAX_STR - 1,
"%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader,
(const xmlChar *) "clipBegin"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.clip_begin, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->clip_begin, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "clip-end"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.clip_end, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->clip_end, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "clipEnd"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.clip_end, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->clip_end, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "href"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.href, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->href, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "id"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.id, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->id, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "idref"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.idref, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->idref, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "item"));
if (strcmp (attr, "(null)"))
- misc.current = atoi (attr);
+ misc->current = atoi (attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "level"));
if (strcmp (attr, "(null)"))
- misc.level = atoi ((char *) attr);
+ misc->level = atoi ((char *) attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "media-type"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.media_type, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->media_type, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "name"));
if (strcmp (attr, "(null)"))
@@ -143,117 +202,108 @@ void get_attributes (xmlTextReaderPtr reader)
if (strcmp (attr, "(null)"))
snprintf (content, MAX_STR - 1, "%s", attr);
if (strcasestr (name, "dc:format"))
- snprintf (misc.daisy_version, MAX_STR - 1, "%s", content);
- if (strcasestr (name, "dc:title") && ! *misc.daisy_title)
+ snprintf (misc->daisy_version, MAX_STR - 1, "%s", content);
+ if (strcasestr (name, "dc:title") && ! *misc->daisy_title)
{
- snprintf (misc.daisy_title, MAX_STR - 1, "%s", content);
- snprintf (misc.bookmark_title, MAX_STR - 1, "%s", content);
- if (strchr (misc.bookmark_title, '/'))
- *strchr (misc.bookmark_title, '/') = '-';
+ snprintf (misc->daisy_title, MAX_STR - 1, "%s", content);
+ snprintf (misc->bookmark_title, MAX_STR - 1, "%s", content);
+ if (strchr (misc->bookmark_title, '/'))
+ *strchr (misc->bookmark_title, '/') = '-';
} // if
/* don't use it
if (strcasestr (name, "dtb:depth"))
depth = atoi (content);
*/
if (strcasestr (name, "dtb:totalPageCount"))
- misc.total_pages = atoi (content);
+ misc->total_pages = atoi (content);
if (strcasestr (name, "ncc:depth"))
- misc.depth = atoi (content);
+ misc->depth = atoi (content);
if (strcasestr (name, "ncc:maxPageNormal"))
- misc.total_pages = atoi (content);
+ misc->total_pages = atoi (content);
if (strcasestr (name, "ncc:pageNormal"))
- misc.total_pages = atoi (content);
+ misc->total_pages = atoi (content);
if (strcasestr (name, "ncc:page-normal"))
- misc.total_pages = atoi (content);
+ misc->total_pages = atoi (content);
if (strcasestr (name, "dtb:totalTime") ||
strcasestr (name, "ncc:totalTime"))
{
- snprintf (misc.ncc_totalTime, MAX_STR - 1, "%s", content);
- if (strchr (misc.ncc_totalTime, '.'))
- *strchr (misc.ncc_totalTime, '.') = 0;
+ snprintf (misc->ncc_totalTime, MAX_STR - 1, "%s", content);
+ if (strchr (misc->ncc_totalTime, '.'))
+ *strchr (misc->ncc_totalTime, '.') = 0;
} // if
} // if
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "playorder"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.playorder, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->playorder, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "phrase"));
if (strcmp (attr, "(null)"))
- misc.phrase_nr = atoi ((char *) attr);
+ misc->phrase_nr = atoi ((char *) attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "seconds"));
if (strcmp (attr, "(null)"))
{
- misc.seconds = atoi (attr);
- if (misc.seconds < 0)
- misc.seconds = 0;
+ misc->seconds = atoi (attr);
+ if (misc->seconds < 0)
+ misc->seconds = 0;
} // if
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "smilref"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.smilref, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->smilref, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "sound_dev"));
if (strcmp (attr, "(null)"))
- snprintf (misc.sound_dev, MAX_STR, "%s", attr);
+ snprintf (misc->sound_dev, MAX_STR, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "cd_dev"));
if (strcmp (attr, "(null)"))
- snprintf (misc.cd_dev, MAX_STR, "%s", attr);
+ snprintf (misc->cd_dev, MAX_STR, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "cddb_flag"));
if (strcmp (attr, "(null)"))
- misc.cddb_flag = (char) attr[0];
+ misc->cddb_flag = (char) attr[0];
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "speed"));
if (strcmp (attr, "(null)"))
- misc.speed = atof (attr);
+ misc->speed = atof (attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "src"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.src, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->src, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "tts"));
if (strcmp (attr, "(null)"))
- misc.tts_no = atof ((char *) attr);
+ misc->tts_no = atof ((char *) attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "toc"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.toc, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->toc, MAX_STR - 1, "%s", attr);
snprintf (attr, MAX_STR - 1, "%s", (char*)
xmlTextReaderGetAttribute (reader, (const xmlChar *) "value"));
if (strcmp (attr, "(null)"))
- snprintf (my_attribute.value, MAX_STR - 1, "%s", attr);
+ snprintf (my_attribute->value, MAX_STR - 1, "%s", attr);
} // get_attributes
-int get_tag_or_label (xmlTextReaderPtr reader)
+int get_tag_or_label (misc_t *misc, my_attribute_t *my_attribute,
+ xmlTextReaderPtr reader)
{
int type;
- *misc.tag = *misc.label = 0;
- *my_attribute.class = *my_attribute.clip_begin = *my_attribute.clip_end =
- *my_attribute.href = *my_attribute.id = *my_attribute.media_type =
- *my_attribute.playorder = * my_attribute.smilref = *my_attribute.src =
- *my_attribute.toc = *my_attribute.value = 0;
+ *misc->tag = *misc->label = 0;
+ *my_attribute->class = *my_attribute->clip_begin = *my_attribute->clip_end =
+ *my_attribute->href = *my_attribute->id = *my_attribute->media_type =
+ *my_attribute->playorder = * my_attribute->smilref = *my_attribute->src =
+ *my_attribute->toc = *my_attribute->value = 0;
- if (! reader)
+ if (reader == NULL)
return 0;
switch (xmlTextReaderRead (reader))
{
case -1:
- {
- int e;
-
- e = errno;
- endwin ();
- printf ("%s\n", strerror (e));
- printf ("Can't handle this DTB structure!\n");
- printf ("Don't know how to handle it yet, sorry. :-(\n");
- beep ();
- fflush (stdout);
- _exit (1);
- }
+ failure ("Can't handle this DTB structure!\n"
+ "Don't know how to handle it yet, sorry. :-(\n", errno);
case 0:
return 0;
case 1:
@@ -271,14 +321,14 @@ int get_tag_or_label (xmlTextReaderPtr reader)
fflush (stdout);
_exit (1);
case XML_READER_TYPE_ELEMENT:
- strncpy (misc.tag, (char *) xmlTextReaderConstName (reader),
+ strncpy (misc->tag, (char *) xmlTextReaderConstName (reader),
MAX_TAG - 1);
n = xmlTextReaderAttributeCount (reader);
for (i = 0; i < n; i++)
- get_attributes (reader);
+ get_attributes (misc, my_attribute, reader);
return 1;
case XML_READER_TYPE_END_ELEMENT:
- snprintf (misc.tag, MAX_TAG - 1, "/%s",
+ snprintf (misc->tag, MAX_TAG - 1, "/%s",
(char *) xmlTextReaderName (reader));
return 1;
case XML_READER_TYPE_TEXT:
@@ -293,20 +343,20 @@ int get_tag_or_label (xmlTextReaderPtr reader)
else
break;
} // while
- strncpy (misc.label, (char *) xmlTextReaderConstValue (reader) + x,
- max_phrase_len);
- for (x = strlen (misc.label) - 1; x >= 0 && isspace (misc.label[x]); x--)
- misc.label[x] = 0;
- for (x = 0; misc.label[x] > 0; x++)
- if (! isascii (misc.label[x]))
- misc.label[x] = ' ';
- return 1;
+ strncpy (misc->label, (char *) xmlTextReaderConstValue (reader) + x,
+ MAX_PHRASE_LEN);
+ for (x = strlen (misc->label) - 1; x >= 0 && isspace (misc->label[x]); x--)
+ misc->label[x] = 0;
+ for (x = 0; misc->label[x] > 0; x++)
+ if (! isascii (misc->label[x]))
+ misc->label[x] = ' ';
+ return 1;
}
case XML_READER_TYPE_ENTITY_REFERENCE:
case XML_READER_TYPE_DOCUMENT_TYPE:
case XML_READER_TYPE_SIGNIFICANT_WHITESPACE:
-// snprintf (misc.tag, MAX_TAG - 1, "/%s",
-// (char *) xmlTextReaderName (reader));
+ snprintf (misc->tag, MAX_TAG - 1, "/%s",
+ (char *) xmlTextReaderName (reader));
return 1;
default:
return 1;
@@ -314,7 +364,8 @@ int get_tag_or_label (xmlTextReaderPtr reader)
return 0;
} // get_tag_or_label
-void parse_text_file (char *text_file)
+void parse_text_file (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char *text_file)
// page-number
{
xmlTextReaderPtr textptr;
@@ -339,29 +390,29 @@ void parse_text_file (char *text_file)
{
do
{
- if (! get_tag_or_label (textptr))
+ if (! get_tag_or_label (misc, my_attribute, textptr))
{
xmlTextReaderClose (textptr);
xmlFreeDoc (doc);
return;
} // if
- } while (strcasecmp (my_attribute.id, anchor) != 0);
+ } while (strcasecmp (my_attribute->id, anchor) != 0);
} // if
do
{
- if (! get_tag_or_label (textptr))
+ if (! get_tag_or_label (misc, my_attribute, textptr))
{
xmlTextReaderClose (textptr);
xmlFreeDoc (doc);
return;
} // if
- } while (! *misc.label);
- daisy[misc.current].page_number = atoi (misc.label);
+ } while (! *misc->label);
+ daisy[misc->current].page_number = atoi (misc->label);
xmlTextReaderClose (textptr);
xmlFreeDoc (doc);
} // parse_text_file
-void get_page_number_3 ()
+void get_page_number_3 (misc_t *misc, my_attribute_t *my_attribute)
{
xmlDocPtr doc;
xmlTextReaderPtr page;
@@ -369,54 +420,55 @@ void get_page_number_3 ()
do
{
- if (! get_tag_or_label (misc.reader))
+ if (! get_tag_or_label (misc, my_attribute, misc->reader))
return;
- } while (strcasecmp (misc.tag, "text") != 0);
- if (strchr (my_attribute.src, '#'))
+ } while (strcasecmp (misc->tag, "text") != 0);
+ if (strchr (my_attribute->src, '#'))
{
- anchor = strdup (strchr (my_attribute.src, '#') + 1);
- *strchr (my_attribute.src, '#') = 0;
+ anchor = strdup (strchr (my_attribute->src, '#') + 1);
+ *strchr (my_attribute->src, '#') = 0;
} // if
- doc = xmlRecoverFile (my_attribute.src);
+ doc = xmlRecoverFile (my_attribute->src);
if (! (page = xmlReaderWalker (doc)))
{
endwin ();
beep ();
- printf (gettext ("\nCannot read %s\n"), my_attribute.src);
+ printf (gettext ("\nCannot read %s\n"), my_attribute->src);
fflush (stdout);
_exit (1);
} // if
do
{
- if (! get_tag_or_label (page))
+ if (! get_tag_or_label (misc, my_attribute, page))
{
xmlTextReaderClose (page);
xmlFreeDoc (doc);
return;
} // if
- } while (strcasecmp (my_attribute.id, anchor) != 0);
+ } while (strcasecmp (my_attribute->id, anchor) != 0);
do
{
- if (! get_tag_or_label (page))
+ if (! get_tag_or_label (misc, my_attribute, page))
{
xmlTextReaderClose (page);
xmlFreeDoc (doc);
return;
} // if
- } while (! *misc.label);
+ } while (! *misc->label);
xmlTextReaderClose (page);
xmlFreeDoc (doc);
- misc.current_page_number = atoi (misc.label);
+ misc->current_page_number = atoi (misc->label);
} // get_page_number_3
-void parse_smil_3 ()
+void parse_smil_3 (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
{
int x;
xmlTextReaderPtr parse;
xmlDocPtr doc;
- misc.total_time = 0;
- for (x = 0; x < misc.total_items; x++)
+ misc->total_time = 0;
+ for (x = 0; x < misc->total_items; x++)
{
if (*daisy[x].smil_file == 0)
continue;
@@ -433,114 +485,116 @@ void parse_smil_3 ()
// parse this smil
while (1)
{
- if (! get_tag_or_label (parse))
+ if (! get_tag_or_label (misc, my_attribute, parse))
break;
- if (strcasecmp (daisy[x].anchor, my_attribute.id) == 0)
+ if (strcasecmp (daisy[x].anchor, my_attribute->id) == 0)
break;
} // while
daisy[x].duration = 0;
while (1)
{
- if (! get_tag_or_label (parse))
+ if (! get_tag_or_label (misc, my_attribute, parse))
break;
-// get misc.clip_begin
- if (strcasecmp (misc.tag, "audio") == 0)
+// get misc->clip_begin
+ if (strcasecmp (misc->tag, "audio") == 0)
{
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
- daisy[x].begin = misc.clip_begin;
- daisy[x].duration += misc.clip_end - misc.clip_begin;
+ get_clips (misc, my_attribute->clip_begin, my_attribute->clip_end);
+ daisy[x].begin = misc->clip_begin;
+ daisy[x].duration += misc->clip_end - misc->clip_begin;
// get clip_end
while (1)
{
- if (! get_tag_or_label (parse))
+ if (! get_tag_or_label (misc, my_attribute, parse))
break;
if (*daisy[x + 1].anchor)
- if (strcasecmp (my_attribute.id, daisy[x + 1].anchor) == 0)
+ if (strcasecmp (my_attribute->id, daisy[x + 1].anchor) == 0)
break;
- if (strcasecmp (misc.tag, "audio") == 0)
+ if (strcasecmp (misc->tag, "audio") == 0)
{
- get_clips (my_attribute.clip_begin, my_attribute.clip_end);
- daisy[x].duration += misc.clip_end - misc.clip_begin;
+ get_clips (misc, my_attribute->clip_begin, my_attribute->clip_end);
+ daisy[x].duration += misc->clip_end - misc->clip_begin;
} // IF
} // while
if (*daisy[x + 1].anchor)
- if (strcasecmp (my_attribute.id, daisy[x + 1].anchor) == 0)
+ if (strcasecmp (my_attribute->id, daisy[x + 1].anchor) == 0)
break;
- } // if (strcasecmp (misc.tag, "audio") == 0)
+ } // if (strcasecmp (misc->tag, "audio") == 0)
} // while
- misc.total_time += daisy[x].duration;
+ misc->total_time += daisy[x].duration;
xmlTextReaderClose (parse);
xmlFreeDoc (doc);
} // for
} // parse_smil_3
-void parse_content (char *src)
+void parse_content (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char *src)
{
int found_anchor, found_text;
char text_file[MAX_STR];
xmlTextReaderPtr content;
- strncpy (daisy[misc.current].smil_file, src, MAX_STR - 1);
- if (strchr (daisy[misc.current].smil_file, '#'))
+ strncpy (daisy[misc->current].smil_file, src, MAX_STR - 1);
+ if (strchr (daisy[misc->current].smil_file, '#'))
{
- strncpy (daisy[misc.current].anchor,
- strchr (daisy[misc.current].smil_file, '#') + 1, MAX_STR - 1);
- *strchr (daisy[misc.current].smil_file, '#') = 0;
+ strncpy (daisy[misc->current].anchor,
+ strchr (daisy[misc->current].smil_file, '#') + 1, MAX_STR - 1);
+ *strchr (daisy[misc->current].smil_file, '#') = 0;
} // if
- xmlDocPtr doc = xmlRecoverFile (daisy[misc.current].smil_file);
+ xmlDocPtr doc = xmlRecoverFile (daisy[misc->current].smil_file);
if (! (content = xmlReaderWalker (doc)))
{
endwin ();
beep ();
- printf (gettext ("\nCannot read %s\n"), daisy[misc.current].smil_file);
+ printf (gettext ("\nCannot read %s\n"), daisy[misc->current].smil_file);
fflush (stdout);
_exit (1);
} // if
found_anchor = found_text = 0;
while (1)
{
- if (! get_tag_or_label (content))
+ if (! get_tag_or_label (misc, my_attribute, content))
{
xmlTextReaderClose (content);
xmlFreeDoc (doc);
return;
} // if
- if (strcasecmp (misc.tag, "text") == 0)
+ if (strcasecmp (misc->tag, "text") == 0)
{
found_text = 1;
- strncpy (text_file, my_attribute.src, MAX_STR - 1);
+ strncpy (text_file, my_attribute->src, MAX_STR - 1);
} // if
- if (strcasecmp (my_attribute.id, daisy[misc.current].anchor) == 0)
+ if (strcasecmp (my_attribute->id, daisy[misc->current].anchor) == 0)
found_anchor = 1;
if (found_anchor && found_text)
break;
} // while
- parse_text_file (text_file);
+ parse_text_file (misc, my_attribute, daisy, text_file);
xmlTextReaderClose (content);
xmlFreeDoc (doc);
} // parse_content
-void parse_xml (char *name)
+void parse_xml (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char *name)
{
xmlTextReaderPtr xml;
int indent = 0;
char xml_name[MAX_STR];
strncpy (xml_name, name, MAX_STR - 1);
- xmlDocPtr doc = xmlRecoverFile (misc.ncx_name);
+ xmlDocPtr doc = xmlRecoverFile (misc->ncx_name);
if (! (xml = xmlReaderWalker (doc)))
{
endwin ();
beep ();
- printf (gettext ("\nCannot read %s\n"), misc.ncx_name);
+ printf (gettext ("\nCannot read %s\n"), misc->ncx_name);
fflush (stdout);
_exit (1);
} // if
- misc.total_pages = misc.depth = 0;
+ misc->total_pages = misc->depth = 0;
while (1)
{
// get dtb:totalPageCount
- if (! get_tag_or_label (xml))
+ if (! get_tag_or_label (misc, my_attribute, xml))
break;
} // while
xmlTextReaderClose (xml);
@@ -555,60 +609,61 @@ void parse_xml (char *name)
fflush (stdout);
_exit (1);
} // if
- misc.current = 0;
+ misc->current = 0;
while (1)
{
- if (! get_tag_or_label (xml))
+ if (! get_tag_or_label (misc, my_attribute, xml))
break;
- if (strcasecmp (misc.tag, "pagenum") == 0)
+ if (strcasecmp (misc->tag, "pagenum") == 0)
{
do
{
- if (! get_tag_or_label (xml))
+ if (! get_tag_or_label (misc, my_attribute, xml))
break;
- } while (! *misc.label);
- daisy[misc.current].page_number = atoi (misc.label);
+ } while (! *misc->label);
+ daisy[misc->current].page_number = atoi (misc->label);
} // if pagenum
- if (strcasecmp (misc.tag, "h1") == 0 ||
- strcasecmp (misc.tag, "h2") == 0 ||
- strcasecmp (misc.tag, "h3") == 0 ||
- strcasecmp (misc.tag, "h4") == 0 ||
- strcasecmp (misc.tag, "h5") == 0 ||
- strcasecmp (misc.tag, "h6") == 0)
+ if (strcasecmp (misc->tag, "h1") == 0 ||
+ strcasecmp (misc->tag, "h2") == 0 ||
+ strcasecmp (misc->tag, "h3") == 0 ||
+ strcasecmp (misc->tag, "h4") == 0 ||
+ strcasecmp (misc->tag, "h5") == 0 ||
+ strcasecmp (misc->tag, "h6") == 0)
{
int l;
- l = misc.tag[1] - '0';
- if (l > misc.depth)
- misc.depth = l;
- daisy[misc.current].level = l;
- daisy[misc.current].x = l + 3 - 1;
- indent = daisy[misc.current].x = (l - 1) * 3 + 1;
- if (! *my_attribute.smilref)
+ l = misc->tag[1] - '0';
+ if (l > misc->depth)
+ misc->depth = l;
+ daisy[misc->current].level = l;
+ daisy[misc->current].x = l + 3 - 1;
+ indent = daisy[misc->current].x = (l - 1) * 3 + 1;
+ if (! *my_attribute->smilref)
continue;
- strncpy (daisy[misc.current].smil_file,
+ strncpy (daisy[misc->current].smil_file,
xml_name, MAX_STR - 1);
- if (strchr (my_attribute.smilref, '#'))
+ if (strchr (my_attribute->smilref, '#'))
{
- strncpy (daisy[misc.current].anchor,
- strchr (my_attribute.smilref, '#') + 1,
+ strncpy (daisy[misc->current].anchor,
+ strchr (my_attribute->smilref, '#') + 1,
MAX_STR - 1);
} // if
do
{
- if (! get_tag_or_label (xml))
+ if (! get_tag_or_label (misc, my_attribute, xml))
break;
- } while (*misc.label == 0);
- get_label (indent, misc.displaying);
- misc.current++;
- misc.displaying++;
- } // if (strcasecmp (misc.tag, "h1") == 0 || ...
+ } while (*misc->label == 0);
+ get_label (misc, daisy, indent);
+ misc->current++;
+ misc->displaying++;
+ } // if (strcasecmp (misc->tag, "h1") == 0 || ...
} // while
xmlTextReaderClose (xml);
xmlFreeDoc (doc);
} // parse_xml
-void parse_manifest (char *name, char *id_ptr)
+void parse_manifest (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char *name, char *id_ptr)
{
xmlTextReaderPtr manifest;
char *id, *toc;
@@ -619,7 +674,7 @@ void parse_manifest (char *name, char *id_ptr)
free (id);
return;
} // if
- toc = strdup (my_attribute.toc);
+ toc = strdup (my_attribute->toc);
xmlDocPtr doc = xmlRecoverFile (name);
if (! (manifest = xmlReaderWalker (doc)))
{
@@ -631,145 +686,64 @@ void parse_manifest (char *name, char *id_ptr)
} // if
do
{
- if (! get_tag_or_label (manifest))
+ if (! get_tag_or_label (misc, my_attribute, manifest))
break;
- if (strcasecmp (misc.tag, "dc:language") == 0 && ! *misc.daisy_language)
+ if (strcasecmp (misc->tag, "dc:language") == 0 && ! *misc->daisy_language)
{
do
{
- if (! get_tag_or_label (manifest))
+ if (! get_tag_or_label (misc, my_attribute, manifest))
break;
- if (*misc.label)
+ if (*misc->label)
break;
- } while (strcasecmp (misc.tag, "/dc:language") != 0);
- strncpy (misc.daisy_language, misc.label, MAX_STR - 1);
+ } while (strcasecmp (misc->tag, "/dc:language") != 0);
+ strncpy (misc->daisy_language, misc->label, MAX_STR - 1);
} // if dc:language
- if (strcasecmp (misc.tag, "dc:title") == 0 && ! *misc.daisy_title)
+ if (strcasecmp (misc->tag, "dc:title") == 0 && ! *misc->daisy_title)
{
do
{
- if (! get_tag_or_label (manifest))
+ if (! get_tag_or_label (misc, my_attribute, manifest))
break;
- if (*misc.label)
+ if (*misc->label)
break;
- } while (strcasecmp (misc.tag, "/dc:title") != 0);
- strncpy (misc.daisy_title, misc.label, MAX_STR - 1);
- strncpy (misc.bookmark_title, misc.label, MAX_STR - 1);
- if (strchr (misc.bookmark_title, '/'))
- *strchr (misc.bookmark_title, '/') = '-';
+ } while (strcasecmp (misc->tag, "/dc:title") != 0);
+ strncpy (misc->daisy_title, misc->label, MAX_STR - 1);
+ strncpy (misc->bookmark_title, misc->label, MAX_STR - 1);
+ if (strchr (misc->bookmark_title, '/'))
+ *strchr (misc->bookmark_title, '/') = '-';
} // if dc:title
- } while (strcasecmp (misc.tag, "manifest") != 0);
+ } while (strcasecmp (misc->tag, "manifest") != 0);
while (1)
{
- if (! get_tag_or_label (manifest))
+ if (! get_tag_or_label (misc, my_attribute, manifest))
break;
- if (*toc && strcasecmp (my_attribute.id, id) == 0)
+ if (*toc && strcasecmp (my_attribute->id, id) == 0)
{
- parse_ncx (my_attribute.href);
+ parse_ncx (misc, my_attribute, daisy, my_attribute->href);
xmlTextReaderClose (manifest);
xmlFreeDoc (doc);
return;
} // if toc
- if (*id && strcasecmp (my_attribute.id, id) == 0)
+ if (*id && strcasecmp (my_attribute->id, id) == 0)
{
- strncpy (daisy[misc.current].smil_file, my_attribute.href,
+ strncpy (daisy[misc->current].smil_file, my_attribute->href,
MAX_STR - 1);
- snprintf (daisy[misc.current].label,
- MAX_STR - 1, "%d", misc.current + 1);
- daisy[misc.current].screen = misc.current / misc.max_y;
- daisy[misc.current].y =
- misc.current - (daisy[misc.current].screen * misc.max_y);
- daisy[misc.current].x = 1;
- misc.current++;
- } // if (strcasecmp (my_attribute.id, id) == 0)
+ snprintf (daisy[misc->current].label,
+ MAX_STR - 1, "%d", misc->current + 1);
+ daisy[misc->current].screen = misc->current / misc->max_y;
+ daisy[misc->current].y =
+ misc->current - (daisy[misc->current].screen * misc->max_y);
+ daisy[misc->current].x = 1;
+ misc->current++;
+ } // if (strcasecmp (my_attribute->id, id) == 0)
} // while
xmlTextReaderClose (manifest);
xmlFreeDoc (doc);
} // parse_manifest
-void parse_opf (char *name)
-{
- xmlTextReaderPtr opf;
-
- xmlDocPtr doc = xmlRecoverFile (name);
- if (! (opf = xmlReaderWalker (doc)))
- {
- endwin ();
- beep ();
- printf (gettext ("\nCannot read %s\n"), name);
- fflush (stdout);
- _exit (1);
- } // if
- misc.current = misc.displaying = 0;
- while (1)
- {
- if (! (get_tag_or_label (opf)))
- break;
- if (strcasecmp (misc.tag, "dc:language") == 0)
- {
- do
- {
- if (! get_tag_or_label (opf))
- break;
- } while (! *misc.label);
- strncpy (misc.daisy_language, misc.label, MAX_STR - 1);
- } // if dc:language
- if (strcasecmp (misc.tag, "dtb:totalTime") == 0)
- {
- do
- {
- if (! get_tag_or_label (opf))
- break;
- } while (! *misc.label);
- strncpy (misc.ncc_totalTime, misc.label, MAX_STR - 1);
- } // if (strcasestr (misc.tag, "dtb:totalTime") == 0)
- if (strcasecmp (misc.tag, "dc:title") == 0 && ! *misc.daisy_title)
- {
- do
- {
- if (! get_tag_or_label (opf))
- break;
- } while (! *misc.label);
- strncpy (misc.daisy_title, misc.label, MAX_STR - 1);
- strncpy (misc.bookmark_title, misc.label, MAX_STR - 1);
- if (strchr (misc.bookmark_title, '/'))
- *strchr (misc.bookmark_title, '/') = '-';
- } // if dc:title
- if (strcasecmp (my_attribute.media_type,
- "application/x-dtbook+xml") == 0)
- {
- parse_xml (my_attribute.href);
- xmlTextReaderClose (opf);
- xmlFreeDoc (doc);
- return;
- } // if "application/x-dtbook+xml"
- if (strcasecmp (misc.tag, "spine") == 0)
- {
- if (*my_attribute.toc)
- {
- parse_ncx (misc.ncx_name);
- if (misc.total_phrases > 0)
- {
- xmlTextReaderClose (opf);
- xmlFreeDoc (doc);
- return;
- } // if
- } // if
- do
- {
- if (! get_tag_or_label (opf))
- break;
- if (strcasecmp (misc.tag, "itemref") == 0)
- parse_manifest (name, my_attribute.idref);
- } while (strcasecmp (misc.tag, "/spine") != 0);
- } // if spine
- } // while
- misc.total_items = misc.current;
- xmlTextReaderClose (opf);
- xmlFreeDoc (doc);
-} // parse_opf
-
-void read_daisy_3 ()
+void read_daisy_3 (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy)
{
char cmd[MAX_CMD], path[MAX_STR];
FILE *r;
@@ -779,7 +753,7 @@ void read_daisy_3 ()
*path = 0;
r = popen (cmd, "r");
ret = fread (path, MAX_STR - 1, 1, r);
- fclose (r);
+ pclose (r);
if (*path == 0)
{
endwin ();
@@ -788,40 +762,41 @@ void read_daisy_3 ()
fflush (stdout);
usage (PACKAGE);
} // if
- strncpy (misc.ncx_name, basename (path), MAX_STR - 1);
- strncpy (misc.NCC_HTML, misc.ncx_name, MAX_STR - 1);
- snprintf (misc.daisy_mp, MAX_STR - 1, "%s/%s",
+ strncpy (misc->ncx_name, basename (path), MAX_STR - 1);
+ strncpy (misc->NCC_HTML, misc->ncx_name, MAX_STR - 1);
+ snprintf (misc->daisy_mp, MAX_STR - 1, "%s/%s",
get_current_dir_name (), dirname (path));
- ret = chdir (misc.daisy_mp);
+ ret = chdir (misc->daisy_mp);
snprintf (cmd, MAX_CMD - 1, "find -iname \"*.opf\" -print0");
r = popen (cmd, "r");
ret = fread (path, MAX_STR - 1, 1, r);
- fclose (r);
+ pclose (r);
ret = ret; // discard compiler warning
- strncpy (misc.opf_name, basename (path), MAX_STR - 1);
- parse_ncx (misc.ncx_name);
- misc.total_items = misc.current;
- parse_smil_3 (misc);
- misc.total_items = misc.current;
+ strncpy (misc->opf_name, basename (path), MAX_STR - 1);
+ parse_ncx (misc, my_attribute, daisy, misc->ncx_name);
+ misc->total_items = misc->current;
+ parse_smil_3 (misc, my_attribute, daisy);
+ misc->total_items = misc->current;
} // read_daisy_3
-void get_label (int indent, int displaying)
+void get_label (misc_t *misc, daisy_t *daisy, int indent)
{
- strncpy (daisy[misc.current].label, misc.label, MAX_STR - 1);
- daisy[misc.current].label[64 - daisy[misc.current].x] = 0;
- if (displaying == misc.max_y)
- displaying = 1;
- if (strcasecmp (daisy[misc.current].class, "pagenum") == 0)
- daisy[misc.current].x = 0;
+ strncpy (daisy[misc->current].label, misc->label, MAX_STR - 1);
+ daisy[misc->current].label[64 - daisy[misc->current].x] = 0;
+ if (misc->displaying == misc->max_y)
+ misc->displaying = 1;
+ if (strcasecmp (daisy[misc->current].class, "pagenum") == 0)
+ daisy[misc->current].x = 0;
else
- if (daisy[misc.current].x == 0)
- daisy[misc.current].x = indent + 3;
- daisy[misc.current].screen = misc.current / misc.max_y;
- daisy[misc.current].y =
- misc.current - daisy[misc.current].screen * misc.max_y;
+ if (daisy[misc->current].x == 0)
+ daisy[misc->current].x = indent + 3;
+ daisy[misc->current].screen = misc->current / misc->max_y;
+ daisy[misc->current].y =
+ misc->current - daisy[misc->current].screen * misc->max_y;
} // get_label
-void parse_ncx (char *name)
+void parse_ncx (misc_t *misc, my_attribute_t *my_attribute,
+ daisy_t *daisy, char *name)
{
int indent, found_page = 0;
xmlTextReaderPtr ncx;
@@ -836,91 +811,91 @@ void parse_ncx (char *name)
fflush (stdout);
_exit (1);
} // if
- misc.current = misc.displaying = misc.level = misc.depth = 0;
+ misc->current = misc->displaying = misc->level = misc->depth = 0;
while (1)
{
- if (! get_tag_or_label (ncx))
+ if (! get_tag_or_label (misc, my_attribute, ncx))
break;
- if (strcasecmp (misc.tag, "docTitle") == 0)
+ if (strcasecmp (misc->tag, "docTitle") == 0)
{
do
{
- if (! get_tag_or_label (ncx))
+ if (! get_tag_or_label (misc, my_attribute, ncx))
break;
- } while (! *misc.label);
- strncpy (misc.daisy_title, misc.label, MAX_STR - 1);
- strncpy (misc.bookmark_title, misc.label, MAX_STR - 1);
- if (strchr (misc.bookmark_title, '/'))
- *strchr (misc.bookmark_title, '/') = '-';
- } // if (strcasecmp (misc.tag, "docTitle") == 0)
- if (strcasecmp (misc.tag, "docAuthor") == 0)
+ } while (! *misc->label);
+ strncpy (misc->daisy_title, misc->label, MAX_STR - 1);
+ strncpy (misc->bookmark_title, misc->label, MAX_STR - 1);
+ if (strchr (misc->bookmark_title, '/'))
+ *strchr (misc->bookmark_title, '/') = '-';
+ } // if (strcasecmp (misc->tag, "docTitle") == 0)
+ if (strcasecmp (misc->tag, "docAuthor") == 0)
{
do
{
- if (! get_tag_or_label (ncx))
+ if (! get_tag_or_label (misc, my_attribute, ncx))
break;
- } while (strcasecmp (misc.tag, "/docAuthor") != 0);
- } // if (strcasecmp (misc.tag, "docAuthor") == 0)
- if (strcasecmp (misc.tag, "navPoint") == 0)
+ } while (strcasecmp (misc->tag, "/docAuthor") != 0);
+ } // if (strcasecmp (misc->tag, "docAuthor") == 0)
+ if (strcasecmp (misc->tag, "navPoint") == 0)
{
- misc.level++;
- if (misc.level > misc.depth)
- misc.depth = misc.level;
- daisy[misc.current].page_number = 0;
- daisy[misc.current].playorder = atoi (my_attribute.playorder);
- daisy[misc.current].level = misc.level;
- if (daisy[misc.current].level < 1)
- daisy[misc.current].level = 1;
- daisy[misc.current].x = misc.level + 2;
- indent = (misc.level - 1) * 3 + 1;
- strncpy (daisy[misc.current].class, my_attribute.class, MAX_STR - 1);
+ misc->level++;
+ if (misc->level > misc->depth)
+ misc->depth = misc->level;
+ daisy[misc->current].page_number = 0;
+ daisy[misc->current].playorder = atoi (my_attribute->playorder);
+ daisy[misc->current].level = misc->level;
+ if (daisy[misc->current].level < 1)
+ daisy[misc->current].level = 1;
+ daisy[misc->current].x = misc->level + 2;
+ indent = (misc->level - 1) * 3 + 1;
+ strncpy (daisy[misc->current].class, my_attribute->class, MAX_STR - 1);
while (1)
{
- if (! get_tag_or_label (ncx))
+ if (! get_tag_or_label (misc, my_attribute, ncx))
break;
- if (strcasecmp (misc.tag, "text") == 0)
+ if (strcasecmp (misc->tag, "text") == 0)
{
while (1)
{
- if (! get_tag_or_label (ncx))
+ if (! get_tag_or_label (misc, my_attribute, ncx))
break;
- if (strcasecmp (misc.tag, "/text") == 0)
+ if (strcasecmp (misc->tag, "/text") == 0)
break;
- if (*misc.label)
+ if (*misc->label)
{
- get_label (indent, misc.displaying);
+ get_label (misc, daisy, indent);
break;
} // if
} // while
- } // if (strcasecmp (misc.tag, "text") == 0)
- if (strcasecmp (misc.tag, "content") == 0)
+ } // if (strcasecmp (misc->tag, "text") == 0)
+ if (strcasecmp (misc->tag, "content") == 0)
{
- if (*my_attribute.src)
+ if (*my_attribute->src)
{
- parse_content (my_attribute.src);
- misc.current++;
+ parse_content (misc, my_attribute, daisy, my_attribute->src);
+ misc->current++;
} // if
break;
- } // if (strcasecmp (misc.tag, "content") == 0)
+ } // if (strcasecmp (misc->tag, "content") == 0)
} // while
- } // if (strcasecmp (misc.tag, "navPoint") == 0)
- if (strcasecmp (misc.tag, "/navpoint") == 0)
- misc.level--;
- if (strcasecmp (misc.tag, "page") == 0 || found_page)
+ } // if (strcasecmp (misc->tag, "navPoint") == 0)
+ if (strcasecmp (misc->tag, "/navpoint") == 0)
+ misc->level--;
+ if (strcasecmp (misc->tag, "page") == 0 || found_page)
{
found_page = 0;
- strncpy (daisy[++misc.current].label, my_attribute.number,
- max_phrase_len - 1);
- strncpy (daisy[misc.current].smil_file, name, MAX_STR - 1);
- daisy[misc.current].screen = misc.current / misc.max_y;
- daisy[misc.current].y =
- misc.current - (daisy[misc.current].screen * misc.max_y);
- daisy[misc.current].x = 2;
- } // if (strcasecmp (misc.tag, "page") == 0)
+ strncpy (daisy[++misc->current].label, my_attribute->number,
+ MAX_PHRASE_LEN - 1);
+ strncpy (daisy[misc->current].smil_file, name, MAX_STR - 1);
+ daisy[misc->current].screen = misc->current / misc->max_y;
+ daisy[misc->current].y =
+ misc->current - (daisy[misc->current].screen * misc->max_y);
+ daisy[misc->current].x = 2;
+ } // if (strcasecmp (misc->tag, "page") == 0)
} // while
xmlTextReaderClose (ncx);
xmlFreeDoc (doc);
- misc.total_items = misc.current;
+ misc->total_items = misc->current;
#ifdef EBOOK_SPEAKER
check_phrases ();
#endif
diff --git a/src/gettext.h b/src/gettext.h
index e76b592..96cc6ac 100644
--- a/src/gettext.h
+++ b/src/gettext.h
@@ -1,280 +1,63 @@
-/* Convenience header for conditional use of GNU <libintl.h>.
- Copyright (C) 1995-1998, 2000-2002, 2004-2006, 2009 Free Software Foundation, Inc.
-
- This program is free software; you can redistribute it and/or modify it
- under the terms of the GNU General Public License as published
- by the Free Software Foundation; either version 3, or (at your option)
- any later version.
-
- This program is distributed in the hope that it will be useful,
- but WITHOUT ANY WARRANTY; without even the implied warranty of
- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- Library General Public License for more details.
-
- You should have received a copy of the GNU General Public
- License along with this program; if not, write to the Free Software
- Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
- USA. */
-
-#ifndef _LIBGETTEXT_H
-#define _LIBGETTEXT_H 1
-
-/* NLS can be disabled through the configure --disable-nls option. */
-#if ENABLE_NLS
-
-/* Get declarations of GNU message catalog functions. */
-# include <libintl.h>
-
-/* You can set the DEFAULT_TEXT_DOMAIN macro to specify the domain used by
- the gettext() and ngettext() macros. This is an alternative to calling
- textdomain(), and is useful for libraries. */
-# ifdef DEFAULT_TEXT_DOMAIN
-# undef gettext
-# define gettext(Msgid) \
- dgettext (DEFAULT_TEXT_DOMAIN, Msgid)
-# undef ngettext
-# define ngettext(Msgid1, Msgid2, N) \
- dngettext (DEFAULT_TEXT_DOMAIN, Msgid1, Msgid2, N)
-# endif
-
-#else
-
-/* Solaris /usr/include/locale.h includes /usr/include/libintl.h, which
- chokes if dcgettext is defined as a macro. So include it now, to make
- later inclusions of <locale.h> a NOP. We don't include <libintl.h>
- as well because people using "gettext.h" will not include <libintl.h>,
- and also including <libintl.h> would fail on SunOS 4, whereas <locale.h>
- is OK. */
-#if defined(__sun)
-# include <locale.h>
-#endif
-
-/* Many header files from the libstdc++ coming with g++ 3.3 or newer include
- <libintl.h>, which chokes if dcgettext is defined as a macro. So include
- it now, to make later inclusions of <libintl.h> a NOP. */
-#if defined(__cplusplus) && defined(__GNUG__) && (__GNUC__ >= 3)
-# include <cstdlib>
-# if (__GLIBC__ >= 2) || _GLIBCXX_HAVE_LIBINTL_H
-# include <libintl.h>
-# endif
-#endif
-
-/* Disabled NLS.
- The casts to 'const char *' serve the purpose of producing warnings
- for invalid uses of the value returned from these functions.
- On pre-ANSI systems without 'const', the config.h file is supposed to
- contain "#define const". */
-# undef gettext
-# define gettext(Msgid) ((const char *) (Msgid))
-# undef dgettext
-# define dgettext(Domainname, Msgid) ((void) (Domainname), gettext (Msgid))
-# undef dcgettext
-# define dcgettext(Domainname, Msgid, Category) \
- ((void) (Category), dgettext (Domainname, Msgid))
-# undef ngettext
-# define ngettext(Msgid1, Msgid2, N) \
- ((N) == 1 \
- ? ((void) (Msgid2), (const char *) (Msgid1)) \
- : ((void) (Msgid1), (const char *) (Msgid2)))
-# undef dngettext
-# define dngettext(Domainname, Msgid1, Msgid2, N) \
- ((void) (Domainname), ngettext (Msgid1, Msgid2, N))
-# undef dcngettext
-# define dcngettext(Domainname, Msgid1, Msgid2, N, Category) \
- ((void) (Category), dngettext(Domainname, Msgid1, Msgid2, N))
-# undef textdomain
-# define textdomain(Domainname) ((const char *) (Domainname))
-# undef bindtextdomain
-# define bindtextdomain(Domainname, Dirname) \
- ((void) (Domainname), (const char *) (Dirname))
-# undef bind_textdomain_codeset
-# define bind_textdomain_codeset(Domainname, Codeset) \
- ((void) (Domainname), (const char *) (Codeset))
-
-#endif
-
-/* A pseudo function call that serves as a marker for the automated
- extraction of messages, but does not call gettext(). The run-time
- translation is done at a different place in the code.
- The argument, String, should be a literal string. Concatenated strings
- and other string expressions won't work.
- The macro's expansion is not parenthesized, so that it is suitable as
- initializer for static 'char[]' or 'const char[]' variables. */
-#define gettext_noop(String) String
-
-/* The separator between msgctxt and msgid in a .mo file. */
-#define GETTEXT_CONTEXT_GLUE "\004"
-
-/* Pseudo function calls, taking a MSGCTXT and a MSGID instead of just a
- MSGID. MSGCTXT and MSGID must be string literals. MSGCTXT should be
- short and rarely need to change.
- The letter 'p' stands for 'particular' or 'special'. */
-#ifdef DEFAULT_TEXT_DOMAIN
-# define pgettext(Msgctxt, Msgid) \
- pgettext_aux (DEFAULT_TEXT_DOMAIN, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, LC_MESSAGES)
-#else
-# define pgettext(Msgctxt, Msgid) \
- pgettext_aux (NULL, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, LC_MESSAGES)
-#endif
-#define dpgettext(Domainname, Msgctxt, Msgid) \
- pgettext_aux (Domainname, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, LC_MESSAGES)
-#define dcpgettext(Domainname, Msgctxt, Msgid, Category) \
- pgettext_aux (Domainname, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, Category)
-#ifdef DEFAULT_TEXT_DOMAIN
-# define npgettext(Msgctxt, Msgid, MsgidPlural, N) \
- npgettext_aux (DEFAULT_TEXT_DOMAIN, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, MsgidPlural, N, LC_MESSAGES)
-#else
-# define npgettext(Msgctxt, Msgid, MsgidPlural, N) \
- npgettext_aux (NULL, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, MsgidPlural, N, LC_MESSAGES)
-#endif
-#define dnpgettext(Domainname, Msgctxt, Msgid, MsgidPlural, N) \
- npgettext_aux (Domainname, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, MsgidPlural, N, LC_MESSAGES)
-#define dcnpgettext(Domainname, Msgctxt, Msgid, MsgidPlural, N, Category) \
- npgettext_aux (Domainname, Msgctxt GETTEXT_CONTEXT_GLUE Msgid, Msgid, MsgidPlural, N, Category)
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static const char *
-pgettext_aux (const char *domain,
- const char *msg_ctxt_id, const char *msgid,
- int category)
-{
- const char *translation = dcgettext (domain, msg_ctxt_id, category);
- if (translation == msg_ctxt_id)
- return msgid;
- else
- return translation;
-}
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static const char *
-npgettext_aux (const char *domain,
- const char *msg_ctxt_id, const char *msgid,
- const char *msgid_plural, unsigned long int n,
- int category)
-{
- const char *translation =
- dcngettext (domain, msg_ctxt_id, msgid_plural, n, category);
- if (translation == msg_ctxt_id || translation == msgid_plural)
- return (n == 1 ? msgid : msgid_plural);
- else
- return translation;
-}
-
-/* The same thing extended for non-constant arguments. Here MSGCTXT and MSGID
- can be arbitrary expressions. But for string literals these macros are
- less efficient than those above. */
-
-#include <string.h>
-
-#define _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS \
- (((__GNUC__ >= 3 || __GNUG__ >= 2) && !__STRICT_ANSI__) \
- /* || __STDC_VERSION__ >= 199901L */ )
-
-#if !_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
-#include <stdlib.h>
-#endif
-
-#define pgettext_expr(Msgctxt, Msgid) \
- dcpgettext_expr (NULL, Msgctxt, Msgid, LC_MESSAGES)
-#define dpgettext_expr(Domainname, Msgctxt, Msgid) \
- dcpgettext_expr (Domainname, Msgctxt, Msgid, LC_MESSAGES)
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static const char *
-dcpgettext_expr (const char *domain,
- const char *msgctxt, const char *msgid,
- int category)
-{
- size_t msgctxt_len = strlen (msgctxt) + 1;
- size_t msgid_len = strlen (msgid) + 1;
- const char *translation;
-#if _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
- char msg_ctxt_id[msgctxt_len + msgid_len];
-#else
- char buf[1024];
- char *msg_ctxt_id =
- (msgctxt_len + msgid_len <= sizeof (buf)
- ? buf
- : (char *) malloc (msgctxt_len + msgid_len));
- if (msg_ctxt_id != NULL)
-#endif
- {
- memcpy (msg_ctxt_id, msgctxt, msgctxt_len - 1);
- msg_ctxt_id[msgctxt_len - 1] = '\004';
- memcpy (msg_ctxt_id + msgctxt_len, msgid, msgid_len);
- translation = dcgettext (domain, msg_ctxt_id, category);
-#if !_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
- if (msg_ctxt_id != buf)
- free (msg_ctxt_id);
-#endif
- if (translation != msg_ctxt_id)
- return translation;
- }
- return msgid;
-}
-
-#define npgettext_expr(Msgctxt, Msgid, MsgidPlural, N) \
- dcnpgettext_expr (NULL, Msgctxt, Msgid, MsgidPlural, N, LC_MESSAGES)
-#define dnpgettext_expr(Domainname, Msgctxt, Msgid, MsgidPlural, N) \
- dcnpgettext_expr (Domainname, Msgctxt, Msgid, MsgidPlural, N, LC_MESSAGES)
-
-#ifdef __GNUC__
-__inline
-#else
-#ifdef __cplusplus
-inline
-#endif
-#endif
-static const char *
-dcnpgettext_expr (const char *domain,
- const char *msgctxt, const char *msgid,
- const char *msgid_plural, unsigned long int n,
- int category)
-{
- size_t msgctxt_len = strlen (msgctxt) + 1;
- size_t msgid_len = strlen (msgid) + 1;
- const char *translation;
-#if _LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
- char msg_ctxt_id[msgctxt_len + msgid_len];
-#else
- char buf[1024];
- char *msg_ctxt_id =
- (msgctxt_len + msgid_len <= sizeof (buf)
- ? buf
- : (char *) malloc (msgctxt_len + msgid_len));
- if (msg_ctxt_id != NULL)
-#endif
- {
- memcpy (msg_ctxt_id, msgctxt, msgctxt_len - 1);
- msg_ctxt_id[msgctxt_len - 1] = '\004';
- memcpy (msg_ctxt_id + msgctxt_len, msgid, msgid_len);
- translation = dcngettext (domain, msg_ctxt_id, msgid_plural, n, category);
-#if !_LIBGETTEXT_HAVE_VARIABLE_SIZE_ARRAYS
- if (msg_ctxt_id != buf)
- free (msg_ctxt_id);
-#endif
- if (!(translation == msg_ctxt_id || translation == msgid_plural))
- return translation;
- }
- return (n == 1 ? msgid : msgid_plural);
-}
-
-#endif /* _LIBGETTEXT_H */
+/* GLIB - Library of useful routines for C programming
+ * Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this library; if not, see <http://www.gnu.org/licenses/>.
+ */
+
+/*
+ * Modified by the GLib Team and others 1997-2000. See the AUTHORS
+ * file for a list of people on the GLib Team. See the ChangeLog
+ * files for a list of changes. These files are distributed with
+ * GLib at ftp://ftp.gtk.org/pub/gtk/.
+ */
+
+#ifndef __G_GETTEXT_H__
+#define __G_GETTEXT_H__
+
+#if !defined (__GLIB_H_INSIDE__) && !defined (GLIB_COMPILATION)
+#error "Only <glib.h> can be included directly."
+#endif
+
+#include <glib/gtypes.h>
+
+G_BEGIN_DECLS
+
+GLIB_AVAILABLE_IN_ALL
+const gchar *g_strip_context (const gchar *msgid,
+ const gchar *msgval) G_GNUC_FORMAT(1);
+
+GLIB_AVAILABLE_IN_ALL
+const gchar *g_dgettext (const gchar *domain,
+ const gchar *msgid) G_GNUC_FORMAT(2);
+GLIB_AVAILABLE_IN_ALL
+const gchar *g_dcgettext (const gchar *domain,
+ const gchar *msgid,
+ gint category) G_GNUC_FORMAT(2);
+GLIB_AVAILABLE_IN_ALL
+const gchar *g_dngettext (const gchar *domain,
+ const gchar *msgid,
+ const gchar *msgid_plural,
+ gulong n) G_GNUC_FORMAT(3);
+GLIB_AVAILABLE_IN_ALL
+const gchar *g_dpgettext (const gchar *domain,
+ const gchar *msgctxtid,
+ gsize msgidoffset) G_GNUC_FORMAT(2);
+GLIB_AVAILABLE_IN_ALL
+const gchar *g_dpgettext2 (const gchar *domain,
+ const gchar *context,
+ const gchar *msgid) G_GNUC_FORMAT(3);
+
+G_END_DECLS
+
+#endif /* __G_GETTEXT_H__ */
diff --git a/src/paranoia.c b/src/paranoia.c
index 914d338..b70a836 100644
--- a/src/paranoia.c
+++ b/src/paranoia.c
@@ -17,43 +17,37 @@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#include "src/daisy.h"
+#include "daisy.h"
-extern daisy_t daisy[];
-extern misc_t misc;
-
-void view_screen ();
-void playfile (char *, char *, char *, char *, char *);
-
-char *get_mcn ()
+char *get_mcn (misc_t *misc)
{
- if (misc.audiocd == 1)
+ if (misc->audiocd == 1)
{
- snprintf (misc.mcn, MAX_STR, ".MCN_%s", cdio_get_mcn (misc.p_cdio));
- return misc.mcn;
+ snprintf (misc->mcn, MAX_STR, ".MCN_%s", cdio_get_mcn (misc->p_cdio));
+ return misc->mcn;
} // if
return "";
} // get_mcn
-void init_paranoia ()
+void init_paranoia (misc_t *misc)
{
- misc.p_cdio = cdio_open (misc.cd_dev, DRIVER_UNKNOWN);
- if (! (misc.drv = cdio_cddap_identify_cdio (misc.p_cdio, 0, NULL)))
+ misc->p_cdio = cdio_open (misc->cd_dev, DRIVER_UNKNOWN);
+ if (! (misc->drv = cdio_cddap_identify_cdio (misc->p_cdio, 0, NULL)))
{
endwin ();
beep ();
printf ("Unable to identify audio CD disc.\n");
kill (getppid (), SIGKILL);
} // if
- if (cdda_open (misc.drv) != 0)
+ if (cdda_open (misc->drv) != 0)
{
endwin ();
beep ();
printf ("Unable to open disc.\n");
kill (getppid (), SIGKILL);
} // if
- if (pipe (misc.pipefd) == -1)
- {
+ if (pipe (misc->pipefd) == -1)
+ {
int e;
e = errno;
@@ -62,34 +56,34 @@ void init_paranoia ()
printf ("pipe: %s\n", strerror (e));
kill (getppid (), SIGKILL);
} // if
- misc.par = paranoia_init (misc.drv);
- paranoia_modeset (misc.par, PARANOIA_MODE_FULL ^ PARANOIA_MODE_NEVERSKIP);
+ misc->par = paranoia_init (misc->drv);
+ paranoia_modeset (misc->par, PARANOIA_MODE_FULL ^ PARANOIA_MODE_NEVERSKIP);
} // init_paranoia
-pid_t play_track (char *out_file, char *type,
+pid_t play_track (misc_t *misc, char *out_file, char *type,
lsn_t from)
{
- cdio_paranoia_free (misc.par);
- init_paranoia ();
- switch (misc.player_pid = fork ())
+ cdio_paranoia_free (misc->par);
+ init_paranoia (misc);
+ switch (misc->player_pid = fork ())
{
case 0: /* Child reads from pipe */
{
char path[MAX_STR + 1], str[MAX_STR + 1];
- close (misc.pipefd[1]); /* don't need this in child */
+ close (misc->pipefd[1]); /* don't need this in child */
#ifdef F_SETPIPE_SZ
- fcntl (misc.pipefd[0], F_SETPIPE_SZ, 1024000);
+ fcntl (misc->pipefd[0], F_SETPIPE_SZ, 1024000);
#endif
- snprintf (path, MAX_STR, "/dev/fd/%d", misc.pipefd[0]);
- snprintf (str, MAX_STR, "%f", misc.speed);
- playfile (path, "cdda", out_file, type, str);
- close (misc.pipefd[0]);
+ snprintf (path, MAX_STR, "/dev/fd/%d", misc->pipefd[0]);
+ snprintf (str, MAX_STR, "%f", misc->speed);
+ playfile (misc, path, "cdda", out_file, type, str);
+ close (misc->pipefd[0]);
_exit (0);
}
default:
- paranoia_seek (misc.par, from, SEEK_SET);
- misc.lsn_cursor = from;
- return misc.player_pid;
+ paranoia_seek (misc->par, from, SEEK_SET);
+ misc->lsn_cursor = from;
+ return misc->player_pid;
} // switch
} // play_track