changeset 13822:38e3bfc4e076

provide default message for waitbar * waitabar.m: If no message is supplied for a new waitbar object, set messge to "Please wait...".
author John W. Eaton <jwe@octave.org>
date Fri, 04 Nov 2011 16:40:07 -0400
parents 4d1927edf194
children 94a37dae80a9
files scripts/plot/waitbar.m
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/plot/waitbar.m	Fri Nov 04 16:35:58 2011 -0400
+++ b/scripts/plot/waitbar.m	Fri Nov 04 16:40:07 2011 -0400
@@ -114,9 +114,10 @@
 
     patch (ax, [0; frac; frac; 0], [0; 0; 1; 1], [0, 0.35, 0.75]);
 
-    if (ischar (msg))
-      title (ax, msg);
+    if (! ischar (msg))
+      msg = "Please wait...";
     endif
+    title (ax, msg);
   endif
 
   drawnow ();