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:
authorDalai Felinto <dfelinto@gmail.com>2017-02-09 16:30:35 +0300
committerDalai Felinto <dfelinto@gmail.com>2017-02-09 16:30:35 +0300
commit8ff7f14c76df2cd2d214e3b5f8078a213a262a6b (patch)
treed56bcb5975559993259fb89599ab47e7ee7abb63 /source/blender/editors/space_buttons
parentf20cc9e54cb0573e0dcf8c20002af766c765bb6e (diff)
Temporary fix for object panel
Diffstat (limited to 'source/blender/editors/space_buttons')
-rw-r--r--source/blender/editors/space_buttons/buttons_context.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/editors/space_buttons/buttons_context.c b/source/blender/editors/space_buttons/buttons_context.c
index 8106e0cfddf..f53d98a1b59 100644
--- a/source/blender/editors/space_buttons/buttons_context.c
+++ b/source/blender/editors/space_buttons/buttons_context.c
@@ -181,7 +181,9 @@ static int buttons_context_path_object(ButsContextPath *path)
/* if we have a scene, use the scene's active object */
else if (buttons_context_path_scene(path)) {
scene = path->ptr[path->len - 1].data;
- ob = (scene->basact) ? scene->basact->object : NULL;
+ TODO_LAYER_CONTEXT; /* use context, not active one */
+ SceneLayer *sl = BKE_scene_layer_active(scene);
+ ob = (sl->basact) ? sl->basact->object : NULL;
if (ob) {
RNA_id_pointer_create(&ob->id, &path->ptr[path->len]);