added Goofster's mergemenu to the alt-w menu.

revised by Matt Ebb
This commit is contained in:
2003-05-10 12:22:26 +00:00
parent 8218dd2614
commit 3c77276bd7
3 changed files with 24 additions and 18 deletions

View File

@@ -1177,18 +1177,18 @@ void mergemenu(void)
extern float doublimit;
short event;
event = pupmenu("MERGE %t|At Cursor%x1|At Center%x2");
event = pupmenu("MERGE %t|At Center%x1|At Cursor%x2");
switch (event) {
case 1: /*Merge at Cursor*/
snap_sel_to_curs();
notice("Removed: %d\n", removedoublesflag(1, doublimit));
case 1: /*Merge at center of selection*/
snap_to_center();
notice("Removed: %d", removedoublesflag(1, doublimit));
allqueue(REDRAWVIEW3D, 0);
break;
case 2: /*Merge at center of selection*/
snap_to_center();
notice("Removed: %d\n", removedoublesflag(1, doublimit));
case 2: /*Merge at Cursor*/
snap_sel_to_curs();
notice("Removed: %d", removedoublesflag(1, doublimit));
allqueue(REDRAWVIEW3D, 0);
break;
}

View File

@@ -1506,7 +1506,7 @@ void special_editmenu(void)
}
else if(G.obedit->type==OB_MESH) {
nr= pupmenu("Specials%t|Subdivide%x1|Subdivide Fractal%x2|Subdivide Smooth%x3|Remove Doubles%x4|Hide%x5|Reveal%x6|Select swap%x7|Flip Normals %x8|Smooth %x9");
nr= pupmenu("Specials%t|Subdivide%x1|Subdivide Fractal%x2|Subdivide Smooth%x3|Merge%x4|Remove Doubles%x5|Hide%x6|Reveal%x7|Select swap%x8|Flip Normals %x9|Smooth %x10");
if(nr>0) waitcursor(1);
switch(nr) {
@@ -1523,21 +1523,24 @@ void special_editmenu(void)
subdivideflag(1, 0.0, editbutflag | B_SMOOTH);
break;
case 4:
notice("Removed: %d\n", removedoublesflag(1, doublimit));
mergemenu();
break;
case 5:
hide_mesh(0);
notice("Removed: %d", removedoublesflag(1, doublimit));
break;
case 6:
reveal_mesh();
hide_mesh(0);
break;
case 7:
selectswap_mesh();
reveal_mesh();
break;
case 8:
flip_editnormals();
selectswap_mesh();
break;
case 9:
flip_editnormals();
break;
case 10:
vertexsmooth();
break;
}

View File

@@ -877,11 +877,14 @@ void winqreadview3dspace(ScrArea *sa, void *spacedata, BWinEvent *evt)
else make_local();
}
break;
case MKEY:
if((G.obedit) && (G.qual & LR_ALTKEY))
mergemenu();
else movetolayer();
break;
case MKEY:
if((G.obedit) && (G.qual & LR_ALTKEY)) {
if(G.obedit->type==OB_MESH) mergemenu();
}
else {
movetolayer();
}
break;
case NKEY:
if(G.obedit) {
switch (G.obedit->type){