Cleanup: avoid risky list as default argument in keymap
This commit is contained in:
parent
06245d0d94
commit
8dd9bb1749
|
@ -352,12 +352,12 @@ def _template_items_tool_select_actions(operator, *, type, value):
|
|||
|
||||
|
||||
# This could have a more generic name, for now use for circle select.
|
||||
def _template_items_tool_select_actions_simple(operator, *, type, value, properties=[]):
|
||||
def _template_items_tool_select_actions_simple(operator, *, type, value, properties=()):
|
||||
kmi_args = {"type": type, "value": value}
|
||||
return [
|
||||
# Don't define 'SET' here, take from the tool options.
|
||||
(operator, kmi_args,
|
||||
{"properties": properties}),
|
||||
{"properties": [*properties]}),
|
||||
(operator, {**kmi_args, "shift": True},
|
||||
{"properties": [*properties, ("mode", 'ADD')]}),
|
||||
(operator, {**kmi_args, "ctrl": True},
|
||||
|
|
|
@ -161,12 +161,12 @@ def _template_items_tool_select_actions(operator, *, type, value):
|
|||
|
||||
|
||||
# This could have a more generic name, for now use for circle select.
|
||||
def _template_items_tool_select_actions_simple(operator, *, type, value, properties=[]):
|
||||
def _template_items_tool_select_actions_simple(operator, *, type, value, properties=()):
|
||||
kmi_args = {"type": type, "value": value}
|
||||
return [
|
||||
# Don't define 'SET' here, take from the tool options.
|
||||
(operator, kmi_args,
|
||||
{"properties": properties}),
|
||||
{"properties": [*properties]}),
|
||||
(operator, {**kmi_args, "shift": True},
|
||||
{"properties": [*properties, ("mode", 'ADD')]}),
|
||||
(operator, {**kmi_args, "ctrl": True},
|
||||
|
|
Loading…
Reference in New Issue