Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-08-15 15:31:04 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-08-15 15:31:04 +0400
commit60915c90995e2ce12216cc70eb1365de03d3f423 (patch)
tree7581b0557b03b7b3e7d687c881d121a47d704b69 /source/blender/editors/space_node/node_edit.c
parente2cffbe732fde055c0a3d619126dde0589c958b6 (diff)
escape key now quits composite.
Diffstat (limited to 'source/blender/editors/space_node/node_edit.c')
-rw-r--r--source/blender/editors/space_node/node_edit.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/source/blender/editors/space_node/node_edit.c b/source/blender/editors/space_node/node_edit.c
index d34c5f16afa..e4fc19fbd08 100644
--- a/source/blender/editors/space_node/node_edit.c
+++ b/source/blender/editors/space_node/node_edit.c
@@ -40,6 +40,7 @@
#include "BLI_math.h"
#include "BLI_blenlib.h"
+#include "BKE_blender.h"
#include "BKE_context.h"
#include "BKE_depsgraph.h"
#include "BKE_global.h"
@@ -72,6 +73,8 @@
#include "node_intern.h" /* own include */
+#define USE_ESC_COMPO
+
/* ***************** composite job manager ********************** */
typedef struct CompoJob {
@@ -88,7 +91,13 @@ static int compo_breakjob(void *cjv)
{
CompoJob *cj = cjv;
- return *(cj->stop);
+ /* without G.is_break 'ESC' wont quit - which annoys users */
+ return (*(cj->stop)
+#ifdef USE_ESC_COMPO
+ ||
+ G.is_break
+#endif
+ );
}
/* called by compo, wmJob sends notifier */
@@ -181,6 +190,10 @@ void ED_node_composite_job(const bContext *C, struct bNodeTree *nodetree, Scene
return;
}
+#ifdef USE_ESC_COMPO
+ G.is_break = FALSE;
+#endif
+
wm_job = WM_jobs_get(CTX_wm_manager(C), CTX_wm_window(C), scene_owner, "Compositing",
WM_JOB_EXCL_RENDER | WM_JOB_PROGRESS, WM_JOB_TYPE_COMPOSITE);
cj = MEM_callocN(sizeof(CompoJob), "compo job");