From 4e59fb23525e09763115ea790ac6903c4cc6d3f4 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Wed, 27 Feb 2013 10:19:31 +0000 Subject: [PATCH] minor changes to outliner - linking groups into a scene now uses the objects original layers (some users have the layers set to useful values, so overwriting isnt so nice). - dropping objects into the 3d view would make them active but not selected, a valid but confusing state, since most tools activate and select now objects. --- source/blender/editors/object/object_add.c | 1 + source/blender/editors/space_outliner/outliner_tools.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/source/blender/editors/object/object_add.c b/source/blender/editors/object/object_add.c index f31324935d2..81372a753df 100644 --- a/source/blender/editors/object/object_add.c +++ b/source/blender/editors/object/object_add.c @@ -2122,6 +2122,7 @@ static int add_named_exec(bContext *C, wmOperator *op) ED_view3d_cursor3d_position(C, basen->object->loc, mval); } + ED_base_object_select(basen, BA_SELECT); ED_base_object_activate(C, basen); copy_object_set_idnew(C, dupflag); diff --git a/source/blender/editors/space_outliner/outliner_tools.c b/source/blender/editors/space_outliner/outliner_tools.c index 303782f3fbd..cd04c8c6bd1 100644 --- a/source/blender/editors/space_outliner/outliner_tools.c +++ b/source/blender/editors/space_outliner/outliner_tools.c @@ -389,7 +389,7 @@ static void group_linkobs2scene_cb(bContext *UNUSED(C), Scene *scene, TreeElemen /* link to scene */ base = MEM_callocN(sizeof(Base), "add_base"); BLI_addhead(&scene->base, base); - base->lay = (1 << 20) - 1; /*v3d->lay;*/ /* would be nice to use the 3d layer but the include's not here */ + base->lay = gob->ob->lay; gob->ob->flag |= SELECT; base->flag = gob->ob->flag; base->object = gob->ob;