From ebdc5f3fcb9a4a06dee7c7455e032344d068c9d3 Mon Sep 17 00:00:00 2001 From: Suzanne Soy Date: Thu, 28 Jan 2021 00:58:16 +0000 Subject: [PATCH] Disable parametric tools when there is no active document. --- ToolCommand.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ToolCommand.py b/ToolCommand.py index 591e072..db53d52 100644 --- a/ToolCommand.py +++ b/ToolCommand.py @@ -26,7 +26,7 @@ class ToolCommand(): def IsActive(self): # return false to grey out the command in the menus, toolbars etc. - return True + return App.ActiveDocument is not None def createCommands(appName): for toolName in ExternalAppsList.apps[appName].Tools: