Sculpt and Paint undo steps kept hanging in the sculpt/paint modes.
Now undo will switch back to global undo, and redo enter the mode 
again. Just like weight/vertex paint.
This commit is contained in:
Ton Roosendaal 2011-06-14 09:55:38 +00:00
parent ce914e51ab
commit 113d653edb

@ -156,11 +156,11 @@ static int ed_undo_step(bContext *C, int step, const char *undoname)
int do_glob_undo= 0;
if(obact && obact->mode & OB_MODE_TEXTURE_PAINT) {
if(!ED_undo_paint_step(C, UNDO_PAINT_IMAGE, step, undoname) && undoname)
if(!ED_undo_paint_step(C, UNDO_PAINT_IMAGE, step, undoname))
do_glob_undo= 1;
}
else if(obact && obact->mode & OB_MODE_SCULPT) {
if(!ED_undo_paint_step(C, UNDO_PAINT_MESH, step, undoname) && undoname)
if(!ED_undo_paint_step(C, UNDO_PAINT_MESH, step, undoname))
do_glob_undo= 1;
}
else if(obact && obact->mode & OB_MODE_PARTICLE_EDIT) {