* Added 'Set Smooth' and 'Set Solid' to the mesh edit mode specials menu/toolbox/3d view menu so you don't always have to keep switching back to edit buttons.

This commit is contained in:
2005-09-28 11:55:43 +00:00
parent 2a08be6e50
commit c1e8340638
6 changed files with 84 additions and 31 deletions

View File

@@ -5871,3 +5871,29 @@ void subdivideflag(int flag, float rad, int beauty)
allqueue(REDRAWVIEW3D, 0);
DAG_object_flush_update(G.scene, G.obedit, OB_RECALC_DATA);
}
void mesh_set_smooth_faces(short event)
{
EditMesh *em = G.editMesh;
EditFace *efa;
if(G.obedit==0) return;
if(G.obedit->type != OB_MESH) return;
efa= em->faces.first;
while(efa) {
if(efa->f & SELECT) {
if(event==1) efa->flag |= ME_SMOOTH;
else if(event==0) efa->flag &= ~ME_SMOOTH;
}
efa= efa->next;
}
DAG_object_flush_update(G.scene, G.obedit, OB_RECALC_DATA);
allqueue(REDRAWVIEW3D, 0);
if(event==1) BIF_undo_push("Set Smooth");
else if(event==0) BIF_undo_push("Set Solid");
}