diff options
author | Campbell Barton <campbell@blender.org> | 2022-05-18 10:40:19 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-05-18 10:53:45 +0300 |
commit | c536791f36b7b175a188b615ffcc5e366b833da4 (patch) | |
tree | 73fc4eb1c6491304285fc1f102619090b5c0783b | |
parent | ba2c6c90face552eff4a85f093639788d0ca9d57 (diff) |
Cleanup: remove unused variables, redundant assignments
6 files changed, 5 insertions, 10 deletions
diff --git a/doc/python_api/sphinx_doc_gen.py b/doc/python_api/sphinx_doc_gen.py index 1c52bb3e57d..1949d77a50b 100644 --- a/doc/python_api/sphinx_doc_gen.py +++ b/doc/python_api/sphinx_doc_gen.py @@ -1210,7 +1210,6 @@ def pycontext2sphinx(basepath): for ctx_str, ctx_members in sorted(context_member_map.items()): subsection = "%s Context" % ctx_str.split("_")[0].title() fw("\n%s\n%s\n\n" % (subsection, (len(subsection) * '-'))) - i = 0 for member in ctx_members: unique_all_len = len(unique) unique.add(member) @@ -1231,7 +1230,6 @@ def pycontext2sphinx(basepath): "Error: context key %r not found in context_type_map; update %s" % (member, __file__)) from None fw(" :type: %s :class:`bpy.types.%s`\n\n" % ("sequence of " if is_seq else "", member_type)) - i += 1 # generate typemap... # for member in sorted(unique_context_strings): diff --git a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py index 189210d8540..6b55683ee89 100644 --- a/release/scripts/startup/bl_ui/properties_grease_pencil_common.py +++ b/release/scripts/startup/bl_ui/properties_grease_pencil_common.py @@ -49,7 +49,7 @@ class GreasePencilSculptAdvancedPanel: layout.use_property_decorate = False tool_settings = context.scene.tool_settings - brush = context.tool_settings.gpencil_sculpt_paint.brush + brush = tool_settings.gpencil_sculpt_paint.brush tool = brush.gpencil_sculpt_tool gp_settings = brush.gpencil_settings diff --git a/release/scripts/startup/bl_ui/properties_paint_common.py b/release/scripts/startup/bl_ui/properties_paint_common.py index b8136f26e90..d5b106635ab 100644 --- a/release/scripts/startup/bl_ui/properties_paint_common.py +++ b/release/scripts/startup/bl_ui/properties_paint_common.py @@ -797,7 +797,6 @@ def brush_settings(layout, context, brush, popover=False): col = layout.column() col.active = not brush.curves_sculpt_settings.interpolate_point_count col.prop(brush.curves_sculpt_settings, "points_per_curve") - use_frontface = True elif brush.curves_sculpt_tool == 'GROW_SHRINK': layout.prop(brush.curves_sculpt_settings, "scale_uniform") layout.prop(brush.curves_sculpt_settings, "minimum_length") diff --git a/release/scripts/startup/bl_ui/space_view3d.py b/release/scripts/startup/bl_ui/space_view3d.py index 995b2afebf0..bcc5976fb59 100644 --- a/release/scripts/startup/bl_ui/space_view3d.py +++ b/release/scripts/startup/bl_ui/space_view3d.py @@ -5689,7 +5689,7 @@ class VIEW3D_PT_object_type_visibility(Panel): # Allows derived classes to pass view data other than context.space_data. # This is used by the official VR add-on, which passes XrSessionSettings # since VR has a 3D view that only exists for the duration of the VR session. - def draw_ex(self, context, view, show_select): + def draw_ex(self, _context, view, show_select): layout = self.layout layout.use_property_split = True layout.use_property_decorate = False diff --git a/release/scripts/startup/bl_ui/space_view3d_toolbar.py b/release/scripts/startup/bl_ui/space_view3d_toolbar.py index 3e1754fd908..1b714a40d03 100644 --- a/release/scripts/startup/bl_ui/space_view3d_toolbar.py +++ b/release/scripts/startup/bl_ui/space_view3d_toolbar.py @@ -276,7 +276,7 @@ class VIEW3D_PT_tools_posemode_options(View3DPanel, Panel): class TEXTURE_UL_texpaintslots(UIList): - def draw_item(self, _context, layout, _data, item, icon, _active_data, _active_propname, _index): + def draw_item(self, _context, layout, _data, item, _icon, _active_data, _active_propname, _index): # mat = data if self.layout_type in {'DEFAULT', 'COMPACT'}: diff --git a/source/blender/modifiers/intern/MOD_screw.c b/source/blender/modifiers/intern/MOD_screw.c index 4157acf8bac..0e22f59c2fb 100644 --- a/source/blender/modifiers/intern/MOD_screw.c +++ b/source/blender/modifiers/intern/MOD_screw.c @@ -881,10 +881,8 @@ static Mesh *modifyMesh(ModifierData *md, const ModifierEvalContext *ctx, Mesh * /* set normal */ if (vert_connect) { if (do_normal_create) { - /* set the normal now its transformed */ - float nor_tx[3]; - mul_v3_m3v3(nor_tx, mat3, vert_connect[j].no); - copy_v3_v3(vert_normals_new[mv_new - mvert_new], nor_tx); + /* Set the normal now its transformed. */ + mul_v3_m3v3(vert_normals_new[mv_new - mvert_new], mat3, vert_connect[j].no); } } |