File tree Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Expand file tree Collapse file tree 1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -37,18 +37,16 @@ def log(msg):
37
37
futil .log (f"[{ CMD_NAME } ] { str (msg )} " )
38
38
39
39
40
- def getErrorMessage (
41
- text = "An unknown error occurred, please validate your inputs and try again" ,
42
- ):
40
+ def getErrorMessage (text = "An unknown error occurred, please validate your inputs and try again" ):
43
41
stackTrace = traceback .format_exc ()
44
42
return f"{ text } :<br>{ stackTrace } "
45
43
46
44
47
45
# Named for easy importing into commandDialog/entry.py
48
46
def command_created (args : adsk .core .CommandCreatedEventArgs ):
49
47
log ("Command Created Event" )
50
- global OPTIONS , INPUTS
51
48
OPTIONS .restoreDefaults ()
49
+ global INPUTS
52
50
INPUTS = Inputs (args .command .commandInputs , OPTIONS )
53
51
54
52
args .command .setDialogMinimumSize (400 , 450 )
@@ -91,8 +89,6 @@ def onCommandInputChanged(args: adsk.core.InputChangedEventArgs):
91
89
# which allows you to verify that all of the inputs are valid and enables the OK button.
92
90
def onCommandValidateInput (args : adsk .core .ValidateInputsEventArgs ):
93
91
log ("Validate Input Event" )
94
- global INPUTS
95
-
96
92
args .areInputsValid = INPUTS .isValid
97
93
98
94
if INPUTS .isValid :
@@ -107,7 +103,6 @@ def onCommandDestroy(args: adsk.core.CommandEventArgs):
107
103
108
104
109
105
def generatePanel (args : adsk .core .CommandEventArgs ):
110
- global OPTIONS
111
106
try :
112
107
des = adsk .fusion .Design .cast (app .activeProduct )
113
108
if des .designType == 0 :
You can’t perform that action at this time.
0 commit comments