Cleanup: Remove unused operator
This commit is contained in:
parent
ed8184cff0
commit
03a931a876
|
@ -125,68 +125,6 @@ class VIEW3D_OT_edit_mesh_extrude_move(Operator):
|
|||
return self.execute(context)
|
||||
|
||||
|
||||
class VIEW3D_OT_edit_mesh_extrude_dissolve_and_intersect(Operator):
|
||||
"""Extrude region together along the average normal"""
|
||||
bl_label = "Extrude, Dissolve, Move and Intersect"
|
||||
bl_idname = "view3d.edit_mesh_extrude_dissolve_and_intersect"
|
||||
|
||||
@classmethod
|
||||
def poll(cls, context):
|
||||
obj = context.active_object
|
||||
return (obj is not None and obj.mode == 'EDIT')
|
||||
|
||||
@staticmethod
|
||||
def extrude_region(context, use_vert_normals):
|
||||
mesh = context.object.data
|
||||
|
||||
totface = mesh.total_face_sel
|
||||
totedge = mesh.total_edge_sel
|
||||
# totvert = mesh.total_vert_sel
|
||||
|
||||
if totface >= 1:
|
||||
if use_vert_normals:
|
||||
bpy.ops.mesh.extrude_region_shrink_fatten(
|
||||
'INVOKE_REGION_WIN',
|
||||
TRANSFORM_OT_shrink_fatten={},
|
||||
)
|
||||
else:
|
||||
bpy.ops.mesh.extrude_region_dissolve_move_intersect(
|
||||
'INVOKE_REGION_WIN',
|
||||
MESH_OT_extrude_region_move={
|
||||
"use_dissolve_ortho_edges": True,
|
||||
},
|
||||
TRANSFORM_OT_translate={
|
||||
"orient_type": 'NORMAL',
|
||||
"constraint_axis": (False, False, True),
|
||||
"use_automerge_and_split": True,
|
||||
},
|
||||
)
|
||||
|
||||
elif totedge == 1:
|
||||
bpy.ops.mesh.extrude_region_move(
|
||||
'INVOKE_REGION_WIN',
|
||||
TRANSFORM_OT_translate={
|
||||
# Don't set the constraint axis since users will expect MMB
|
||||
# to use the user setting, see: T61637
|
||||
# "orient_type": 'NORMAL',
|
||||
# Not a popular choice, too restrictive for retopo.
|
||||
# "constraint_axis": (True, True, False)})
|
||||
"constraint_axis": (False, False, False),
|
||||
})
|
||||
else:
|
||||
bpy.ops.mesh.extrude_region_move('INVOKE_REGION_WIN')
|
||||
|
||||
# ignore return from operators above because they are 'RUNNING_MODAL',
|
||||
# and cause this one not to be freed. [#24671]
|
||||
return {'FINISHED'}
|
||||
|
||||
def execute(self, context):
|
||||
return VIEW3D_OT_edit_mesh_extrude_dissolve_and_intersect.extrude_region(context, False)
|
||||
|
||||
def invoke(self, context, _event):
|
||||
return self.execute(context)
|
||||
|
||||
|
||||
class VIEW3D_OT_edit_mesh_extrude_shrink_fatten(Operator):
|
||||
"""Extrude region together along local normals"""
|
||||
bl_label = "Extrude and Move on Individual Normals"
|
||||
|
@ -252,7 +190,6 @@ class VIEW3D_OT_transform_gizmo_set(Operator):
|
|||
classes = (
|
||||
VIEW3D_OT_edit_mesh_extrude_individual_move,
|
||||
VIEW3D_OT_edit_mesh_extrude_move,
|
||||
VIEW3D_OT_edit_mesh_extrude_dissolve_and_intersect,
|
||||
VIEW3D_OT_edit_mesh_extrude_shrink_fatten,
|
||||
VIEW3D_OT_transform_gizmo_set,
|
||||
)
|
||||
|
|
|
@ -680,7 +680,6 @@ class _defs_edit_mesh:
|
|||
),
|
||||
icon="none",
|
||||
widget="VIEW3D_GGT_tool_generic_handle_normal",
|
||||
operator="view3d.edit_mesh_extrude_dissolve_and_intersect",
|
||||
keymap=(),
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in New Issue