Fix #91223: Draw Non-Object Active Items in Text Hi
In the Outliner, draw the text of active collections, scenes, and view layers in "text highlight" color, by default a brighter white than the regular items. This helps differentiate the active ones a bit better and also allows them to be themed separately. Pull Request: https://projects.blender.org/blender/blender/pulls/133390
This commit is contained in:
committed by
Harley Acheson
parent
e07cd2b982
commit
62a0350f6d
@@ -3380,11 +3380,19 @@ static void outliner_draw_tree_element(uiBlock *block,
|
||||
/* Active items like camera or material. */
|
||||
icon_bgcolor[3] = 0.2f;
|
||||
active = OL_DRAWSEL_ACTIVE;
|
||||
if (te->idcode == ID_SCE) {
|
||||
UI_GetThemeColor3ubv(TH_TEXT_HI, text_color);
|
||||
text_color[3] = 255;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else {
|
||||
active = tree_element_type_active_state_get(tvc, te, tselem);
|
||||
if (active != OL_DRAWSEL_NONE) {
|
||||
UI_GetThemeColor3ubv(TH_TEXT_HI, text_color);
|
||||
text_color[3] = 255;
|
||||
}
|
||||
}
|
||||
|
||||
/* Active circle. */
|
||||
|
||||
@@ -995,11 +995,6 @@ static eOLDrawState tree_element_posechannel_state_get(const Object *ob_pose,
|
||||
static eOLDrawState tree_element_viewlayer_state_get(const ViewLayer *view_layer,
|
||||
const TreeElement *te)
|
||||
{
|
||||
/* paranoia check */
|
||||
if (te->idcode != ID_SCE) {
|
||||
return OL_DRAWSEL_NONE;
|
||||
}
|
||||
|
||||
const ViewLayer *te_view_layer = static_cast<ViewLayer *>(te->directdata);
|
||||
|
||||
if (view_layer == te_view_layer) {
|
||||
|
||||
Reference in New Issue
Block a user