diff options
author | Campbell Barton <ideasman42@gmail.com> | 2017-11-20 12:45:03 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2017-11-20 12:45:03 +0300 |
commit | a8777f905846f80385fc90135e000c3169bbefc6 (patch) | |
tree | 928a7db22a8553abd35f99a0afe2990be87d69ac /source/blender/editors/space_outliner/outliner_tools.c | |
parent | c0c696b014e3c21b923a2c21fb33a18839a3faa3 (diff) | |
parent | 65af15ad887b30e678db9acab75efc7897c9197e (diff) |
Merge branch 'master' into blender2.8
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_tools.c')
-rw-r--r-- | source/blender/editors/space_outliner/outliner_tools.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/source/blender/editors/space_outliner/outliner_tools.c b/source/blender/editors/space_outliner/outliner_tools.c index ca168094ae2..79122de70dd 100644 --- a/source/blender/editors/space_outliner/outliner_tools.c +++ b/source/blender/editors/space_outliner/outliner_tools.c @@ -376,17 +376,14 @@ static void object_select_cb( } static void object_select_hierarchy_cb( - bContext *C, ReportList *UNUSED(reports), Scene *UNUSED(scene), TreeElement *UNUSED(te), - TreeStoreElem *UNUSED(tsep), TreeStoreElem *UNUSED(tselem), void *UNUSED(user_data)) + bContext *C, ReportList *UNUSED(reports), Scene *UNUSED(scene), TreeElement *te, + TreeStoreElem *UNUSED(tsep), TreeStoreElem *tselem, void *UNUSED(user_data)) { - /* From where do i get the x,y coordinate of the mouse event ? */ - wmWindow *win = CTX_wm_window(C); - int x = win->eventstate->mval[0]; - int y = win->eventstate->mval[1]; - outliner_item_activate_or_toggle_closed(C, x, y, true, true); + /* Don't extend because this toggles, which is nice for Ctrl-Click but not for a menu item. + * it's especially confusing when multiple items are selected since some toggle on/off. */ + outliner_item_do_activate_from_tree_element(C, te, tselem, false, true); } - static void object_deselect_cb( bContext *C, ReportList *UNUSED(reports), Scene *UNUSED(scene), TreeElement *UNUSED(te), TreeStoreElem *UNUSED(tsep), TreeStoreElem *tselem, void *UNUSED(user_data)) |