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:
authorJacques Lucke <mail@jlucke.com>2018-10-19 11:59:53 +0300
committerJacques Lucke <mail@jlucke.com>2018-10-19 11:59:53 +0300
commit3c30d3bcbd93da4e4cded76c3fc3a30152a43cb4 (patch)
treeed105e41a7dd450ffcf46ee5dbfef8ed1bfcdb82 /source/blender/editors/space_outliner/outliner_dragdrop.c
parentc92f125e75b5980db1dbe08bd30df8dc0ecb3d56 (diff)
Outliner: only drag element under mouse if it was not selected before
Reviewers: brecht Differential Revision: https://developer.blender.org/D3811
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_dragdrop.c')
-rw-r--r--source/blender/editors/space_outliner/outliner_dragdrop.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/editors/space_outliner/outliner_dragdrop.c b/source/blender/editors/space_outliner/outliner_dragdrop.c
index 978a2cc4af4..293c1d5f29c 100644
--- a/source/blender/editors/space_outliner/outliner_dragdrop.c
+++ b/source/blender/editors/space_outliner/outliner_dragdrop.c
@@ -875,7 +875,12 @@ static int outliner_item_drag_drop_invoke(bContext *C, wmOperator *UNUSED(op), c
if (ELEM(GS(data.drag_id->name), ID_OB, ID_GR)) {
/* For collections and objects we cheat and drag all selected. */
- TREESTORE(te)->flag |= TSE_SELECTED;
+
+ /* Only drag element under mouse if it was not selected before. */
+ if ((TREESTORE(te)->flag & TSE_SELECTED) == 0) {
+ outliner_flag_set(&soops->tree, TSE_SELECTED, 0);
+ TREESTORE(te)->flag |= TSE_SELECTED;
+ }
/* Gather all selected elements. */
struct IDsSelectedData selected = {