WM: default tool was being set for space types w/o tools
Add mask for space types so we don't accidentally add tools for space types that don't support it.
This commit is contained in:
@@ -2398,7 +2398,7 @@ class WM_OT_tool_set_by_name(Operator):
|
||||
if fn(context, space_type, self.name):
|
||||
return {'FINISHED'}
|
||||
else:
|
||||
self.report({'WARNING'}, f"Tool {self.name!r} not found.")
|
||||
self.report({'WARNING'}, f"Tool {self.name!r:s} not found for space {space_type!r:s}.")
|
||||
return {'CANCELLED'}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user