[Bf-blender-cvs] [765c16bbd08] blender-v3.2-release: Fix wrong asset dropped when dragging from loc. of just cleared asset

Julian Eisel noreply at git.blender.org
Tue May 31 12:29:23 CEST 2022


Commit: 765c16bbd08b06c2b17454bac695f51276f01e41
Author: Julian Eisel
Date:   Tue May 31 12:24:03 2022 +0200
Branches: blender-v3.2-release
https://developer.blender.org/rB765c16bbd08b06c2b17454bac695f51276f01e41

Fix wrong asset dropped when dragging from loc. of just cleared asset

See previous commit for an explanation of what went wrong. Similar to
the fix there, we also have to update the dragged data (e.g. the
data-block) referenced by the button.

Committing separately since this could cause further issues.

===================================================================

M	source/blender/editors/interface/interface.cc

===================================================================

diff --git a/source/blender/editors/interface/interface.cc b/source/blender/editors/interface/interface.cc
index ffd9ab86ee3..76dead57b0a 100644
--- a/source/blender/editors/interface/interface.cc
+++ b/source/blender/editors/interface/interface.cc
@@ -927,7 +927,7 @@ static void ui_but_update_old_active_from_new(uiBut *oldbut, uiBut *but)
     BLI_strncpy(oldbut->strdata, but->strdata, sizeof(oldbut->strdata));
   }
 
-  if (but->dragpoin && (but->dragflag & UI_BUT_DRAGPOIN_FREE)) {
+  if (but->dragpoin) {
     SWAP(void *, but->dragpoin, oldbut->dragpoin);
   }
   if (but->imb) {



More information about the Bf-blender-cvs mailing list