From de80a63ae6762a170dba1bf45e1ef620182a82ea Mon Sep 17 00:00:00 2001 From: mfranz Date: Thu, 29 Mar 2007 18:39:10 +0000 Subject: [PATCH] don't rely on the existence of an "arg" pointer --- Nasal/gui.nas | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Nasal/gui.nas b/Nasal/gui.nas index 0022e7e2e..9c2af5389 100644 --- a/Nasal/gui.nas +++ b/Nasal/gui.nas @@ -85,8 +85,8 @@ settimer(INIT, 1); ## # Show/hide the fps display dialog. # -fpsDisplay = func { - var w = size(arg) ? arg[0] : cmdarg().getBoolValue(); +fpsDisplay = func(v = nil) { + var w = v != nil ? v : cmdarg().getBoolValue(); fgcommand(w ? "dialog-show" : "dialog-close", props.Node.new({"dialog-name": "fps"})); }