diff options
author | Ton Roosendaal <ton@blender.org> | 2011-03-12 18:09:29 +0300 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2011-03-12 18:09:29 +0300 |
commit | f6b21ecf840627f384c84e1a869ca54698792a87 (patch) | |
tree | 8a1bbcf48e19d6aa690dc98d5982ed513005d057 /source/blender/editors | |
parent | a41694938231a108ed414561311663c3c4ae7c4c (diff) |
More on bug #26432
More undo-push disabling for switching render slots.
Also added 'undo push' print in debug mode (blender -d)
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/space_image/image_ops.c | 2 | ||||
-rw-r--r-- | source/blender/editors/util/undo.c | 3 |
2 files changed, 4 insertions, 1 deletions
diff --git a/source/blender/editors/space_image/image_ops.c b/source/blender/editors/space_image/image_ops.c index 3990f0916b1..93e5465cd64 100644 --- a/source/blender/editors/space_image/image_ops.c +++ b/source/blender/editors/space_image/image_ops.c @@ -2134,7 +2134,7 @@ static int cycle_render_slot_exec(bContext *C, wmOperator *op) WM_event_add_notifier(C, NC_IMAGE|ND_DRAW, NULL); /* no undo push for browsing existing */ - if(ima->renders[ima->render_slot]) + if(ima->renders[ima->render_slot] || ima->render_slot==ima->last_render_slot) return OPERATOR_CANCELLED; return OPERATOR_FINISHED; diff --git a/source/blender/editors/util/undo.c b/source/blender/editors/util/undo.c index b366a8460fc..2659863e592 100644 --- a/source/blender/editors/util/undo.c +++ b/source/blender/editors/util/undo.c @@ -80,6 +80,9 @@ void ED_undo_push(bContext *C, const char *str) Object *obedit= CTX_data_edit_object(C); Object *obact= CTX_data_active_object(C); + if (G.f & G_DEBUG) + printf("undo push %s\n", str); + if(obedit) { if (U.undosteps == 0) return; |