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:
authorHans Goudey <h.goudey@me.com>2020-12-19 02:13:15 +0300
committerHans Goudey <h.goudey@me.com>2020-12-19 02:13:15 +0300
commit6942dd9f49003ead61f9a0e52b398ebc74a5e3cb (patch)
treebd1cf16233fb7004889d40d24ad7f08be08e5919 /source/blender/editors/space_outliner/outliner_draw.c
parent002722bb800e5b5d5d7e1c54e92e7d66037cb891 (diff)
Fix T83868: Button animation states no longer visible without emboss
This bug was caused by making it so that non-embossed modifier icon buttons could become an operator button and retain their red highlight for disabled modifiers. The icon button needs emboss turned off, but in earlier versions of Blender, `UI_EMBOSS_NONE` would be overridden by animation or red alert states. Instead of abusing "NONE" to mean "none unless there is animation or red alert", this commit adds a new emboss flag for that situation, `UI_EMBOSS_NONE_OR_STATUS`, which uses no emboss unless there is an animation state, or another status. There are only a few situations where this is necessary, so the change isn't too big. Differential Revision: https://developer.blender.org/D9902
Diffstat (limited to 'source/blender/editors/space_outliner/outliner_draw.c')
-rw-r--r--source/blender/editors/space_outliner/outliner_draw.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/space_outliner/outliner_draw.c b/source/blender/editors/space_outliner/outliner_draw.c
index d2381cf30db..9223da136e1 100644
--- a/source/blender/editors/space_outliner/outliner_draw.c
+++ b/source/blender/editors/space_outliner/outliner_draw.c
@@ -1996,7 +1996,7 @@ static void outliner_draw_mode_column_toggle(uiBlock *block,
"Change the object in the current mode\n"
"* Ctrl to add to the current mode");
}
-
+ UI_block_emboss_set(block, UI_EMBOSS_NONE_OR_STATUS);
uiBut *but = uiDefIconBut(block,
UI_BTYPE_ICON_TOGGLE,
0,
@@ -3646,7 +3646,7 @@ void draw_outliner(const bContext *C)
outliner_tree_dimensions(space_outliner, &tree_width, &tree_height);
/* Default to no emboss for outliner UI. */
- UI_block_emboss_set(block, UI_EMBOSS_NONE);
+ UI_block_emboss_set(block, UI_EMBOSS_NONE_OR_STATUS);
if (space_outliner->outlinevis == SO_DATA_API) {
int buttons_start_x = outliner_data_api_buttons_start_x(tree_width);
@@ -3655,7 +3655,7 @@ void draw_outliner(const bContext *C)
UI_block_emboss_set(block, UI_EMBOSS);
outliner_draw_rnabuts(block, region, space_outliner, buttons_start_x, &space_outliner->tree);
- UI_block_emboss_set(block, UI_EMBOSS_NONE);
+ UI_block_emboss_set(block, UI_EMBOSS_NONE_OR_STATUS);
}
else if (space_outliner->outlinevis == SO_ID_ORPHANS) {
/* draw user toggle columns */