From 875272cdb6f7f2b9d51f78c6a6dc2bfe4d56301a Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Wed, 28 Oct 2015 13:14:52 -0400 Subject: dbg(), info(), warn() err(): Call log_*() functions --- diff --git a/src/ui.sh b/src/ui.sh index 3df6bc7..5336c5e 100644 --- a/src/ui.sh +++ b/src/ui.sh @@ -15,8 +15,6 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . -ui_functions='exit_ui resume_ui dbg info warn err show_menu' - init_ui() { local ui="${1}" @@ -31,9 +29,12 @@ init_ui() ;; esac - for fn in ${ui_functions}; do + for fn in exit_ui resume_ui show_menu; do eval "${fn}() { ${ui}_${fn} \"\${@}\"; }" done + for fn in dbg info warn err; do + eval "${fn}() { ${ui}_${fn} \"\${@}\"; log_${fn} \"\${@}\"; }" + done ${ui}_init_ui } -- cgit v0.9.1