[Bf-blender-cvs] [9cc380e] master: Fix own error in recent commit with red-alert flag becoming stale
Campbell Barton
noreply at git.blender.org
Wed Feb 12 23:14:14 CET 2014
Commit: 9cc380e02668a7ff4c28e9541cfe84fdb1ff47ba
Author: Campbell Barton
Date: Thu Feb 13 09:12:47 2014 +1100
https://developer.blender.org/rB9cc380e02668a7ff4c28e9541cfe84fdb1ff47ba
Fix own error in recent commit with red-alert flag becoming stale
===================================================================
M source/blender/editors/interface/interface.c
===================================================================
diff --git a/source/blender/editors/interface/interface.c b/source/blender/editors/interface/interface.c
index aa3be71..80311a6 100644
--- a/source/blender/editors/interface/interface.c
+++ b/source/blender/editors/interface/interface.c
@@ -583,8 +583,6 @@ static void ui_but_update_linklines(uiBlock *block, uiBut *oldbut, uiBut *newbut
*/
static bool ui_but_update_from_old_block(const bContext *C, uiBlock *block, uiBut **but_p, uiBut **but_old_p)
{
- /* flags from the buttons we want to refresh, may want to add more here... */
- const int flag_copy = UI_BUT_REDALERT | UI_BUT_DRAG_MULTI;
const int drawflag_copy = 0; /* None currently. */
uiBlock *oldblock = block->oldblock;
@@ -617,6 +615,9 @@ static bool ui_but_update_from_old_block(const bContext *C, uiBlock *block, uiBu
}
if (oldbut->active) {
+ /* flags from the buttons we want to refresh, may want to add more here... */
+ const int flag_copy = UI_BUT_REDALERT;
+
found_active = true;
#if 0
@@ -695,6 +696,8 @@ static bool ui_but_update_from_old_block(const bContext *C, uiBlock *block, uiBu
/* note: if layout hasn't been applied yet, it uses old button pointers... */
}
else {
+ const int flag_copy = UI_BUT_DRAG_MULTI;
+
but->flag = (but->flag & ~flag_copy) | (oldbut->flag & flag_copy);
/* ensures one button can get activated, and in case the buttons
More information about the Bf-blender-cvs
mailing list