summaryrefslogtreecommitdiff
path: root/samples/report-string
diff options
context:
space:
mode:
Diffstat (limited to 'samples/report-string')
-rw-r--r--samples/report-string23
1 files changed, 23 insertions, 0 deletions
diff --git a/samples/report-string b/samples/report-string
new file mode 100644
index 000000000000..a674517c75e2
--- /dev/null
+++ b/samples/report-string
@@ -0,0 +1,23 @@
+# $Id: report-string,v 1.2 2010/01/13 10:00:11 tom Exp $
+# Report result passed in a string $RESULT
+# vile:shmode
+
+case $retval in
+ $DIALOG_OK)
+ echo "Result is $RESULT";;
+ $DIALOG_CANCEL)
+ echo "Cancel pressed.";;
+ $DIALOG_HELP)
+ echo "Help pressed ($RESULT).";;
+ $DIALOG_EXTRA)
+ echo "Extra button pressed.";;
+ $DIALOG_ITEM_HELP)
+ echo "Item-help button pressed.";;
+ $DIALOG_ESC)
+ if test -n "$RESULT" ; then
+ echo "$RESULT"
+ else
+ echo "ESC pressed."
+ fi
+ ;;
+esac