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:
authorBastien Montagne <montagne29@wanadoo.fr>2018-06-15 18:43:18 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2018-06-15 18:43:18 +0300
commitecc57e7524bf04d498646715dcf4f9340ef3fc56 (patch)
tree220f951e1ff1be7bc769a1401845928f3f581330
parent9c629b06bfdf645c009d953902c936b82900053a (diff)
parentd645b1a78a752950d061a4ccb125721acade5544 (diff)
Merge branch 'master' into blender2.8
-rw-r--r--source/blender/blenlib/BLI_callbacks.h2
-rw-r--r--source/blender/blenlib/intern/callbacks.c4
-rw-r--r--source/blender/render/intern/source/pipeline.c2
-rw-r--r--source/creator/creator_args.c6
-rw-r--r--source/creator/creator_signals.c10
5 files changed, 12 insertions, 12 deletions
diff --git a/source/blender/blenlib/BLI_callbacks.h b/source/blender/blenlib/BLI_callbacks.h
index adc7bf5af6b..c913510bda3 100644
--- a/source/blender/blenlib/BLI_callbacks.h
+++ b/source/blender/blenlib/BLI_callbacks.h
@@ -62,7 +62,7 @@ typedef struct bCallbackFuncStore {
} bCallbackFuncStore;
-void BLI_callback_exec(struct Main *main, struct ID *self, eCbEvent evt);
+void BLI_callback_exec(struct Main *bmain, struct ID *self, eCbEvent evt);
void BLI_callback_add(bCallbackFuncStore *funcstore, eCbEvent evt);
void BLI_callback_global_init(void);
diff --git a/source/blender/blenlib/intern/callbacks.c b/source/blender/blenlib/intern/callbacks.c
index 191be49263c..766e3f38f00 100644
--- a/source/blender/blenlib/intern/callbacks.c
+++ b/source/blender/blenlib/intern/callbacks.c
@@ -32,13 +32,13 @@
static ListBase callback_slots[BLI_CB_EVT_TOT] = {{NULL}};
-void BLI_callback_exec(struct Main *main, struct ID *self, eCbEvent evt)
+void BLI_callback_exec(struct Main *bmain, struct ID *self, eCbEvent evt)
{
ListBase *lb = &callback_slots[evt];
bCallbackFuncStore *funcstore;
for (funcstore = lb->first; funcstore; funcstore = funcstore->next) {
- funcstore->func(main, self, funcstore->arg);
+ funcstore->func(bmain, self, funcstore->arg);
}
}
diff --git a/source/blender/render/intern/source/pipeline.c b/source/blender/render/intern/source/pipeline.c
index 14160782898..8ecfe801d70 100644
--- a/source/blender/render/intern/source/pipeline.c
+++ b/source/blender/render/intern/source/pipeline.c
@@ -2325,7 +2325,7 @@ static int do_write_image_or_movie(Render *re, Main *bmain, Scene *scene, bMovie
/* Flush stdout to be sure python callbacks are printing stuff after blender. */
fflush(stdout);
- BLI_callback_exec(G.main, NULL, BLI_CB_EVT_RENDER_STATS);
+ BLI_callback_exec(re->main, NULL, BLI_CB_EVT_RENDER_STATS);
BLI_timecode_string_from_time_simple(name, sizeof(name), re->i.lastframetime - render_time);
printf(" (Saving: %s)\n", name);
diff --git a/source/creator/creator_args.c b/source/creator/creator_args.c
index 657ea3f1eb3..da5dcf9ff8b 100644
--- a/source/creator/creator_args.c
+++ b/source/creator/creator_args.c
@@ -397,7 +397,7 @@ static void arg_py_context_restore(
/* script may load a file, check old data is valid before using */
if (c_py->has_win) {
if ((c_py->win == NULL) ||
- ((BLI_findindex(&G.main->wm, c_py->wm) != -1) &&
+ ((BLI_findindex(&G_MAIN->wm, c_py->wm) != -1) &&
(BLI_findindex(&c_py->wm->windows, c_py->win) != -1)))
{
CTX_wm_window_set(C, c_py->win);
@@ -405,7 +405,7 @@ static void arg_py_context_restore(
}
if ((c_py->scene == NULL) ||
- BLI_findindex(&G.main->scene, c_py->scene) != -1)
+ BLI_findindex(&G_MAIN->scene, c_py->scene) != -1)
{
CTX_data_scene_set(C, c_py->scene);
}
@@ -1774,7 +1774,7 @@ static int arg_handle_load_file(int UNUSED(argc), const char **argv, void *data)
if (BLO_has_bfile_extension(filename)) {
/* Just pretend a file was loaded, so the user can press Save and it'll save at the filename from the CLI. */
- BLI_strncpy(G.main->name, filename, FILE_MAX);
+ BLI_strncpy(G_MAIN->name, filename, FILE_MAX);
G.relbase_valid = true;
G.save_over = true;
printf("... opened default scene instead; saving will write to: %s\n", filename);
diff --git a/source/creator/creator_signals.c b/source/creator/creator_signals.c
index 55f9777f55a..44c93d2c615 100644
--- a/source/creator/creator_signals.c
+++ b/source/creator/creator_signals.c
@@ -110,7 +110,7 @@ static void sig_handle_crash_backtrace(FILE *fp)
static void sig_handle_crash(int signum)
{
- wmWindowManager *wm = G.main->wm.first;
+ wmWindowManager *wm = G_MAIN->wm.first;
#ifdef USE_WRITE_CRASH_BLEND
if (wm->undo_stack) {
@@ -118,11 +118,11 @@ static void sig_handle_crash(int signum)
if (memfile) {
char fname[FILE_MAX];
- if (!G.main->name[0]) {
+ if (!G_MAIN->name[0]) {
BLI_make_file_string("/", fname, BKE_tempdir_base(), "crash.blend");
}
else {
- BLI_strncpy(fname, G.main->name, sizeof(fname));
+ BLI_strncpy(fname, G_MAIN->name, sizeof(fname));
BLI_replace_extension(fname, sizeof(fname), ".crash.blend");
}
@@ -139,11 +139,11 @@ static void sig_handle_crash(int signum)
char fname[FILE_MAX];
- if (!G.main->name[0]) {
+ if (!G_MAIN->name[0]) {
BLI_join_dirfile(fname, sizeof(fname), BKE_tempdir_base(), "blender.crash.txt");
}
else {
- BLI_join_dirfile(fname, sizeof(fname), BKE_tempdir_base(), BLI_path_basename(G.main->name));
+ BLI_join_dirfile(fname, sizeof(fname), BKE_tempdir_base(), BLI_path_basename(G_MAIN->name));
BLI_replace_extension(fname, sizeof(fname), ".crash.txt");
}