UI: Improved Area Icon Using a SpaceType Callback #124556

Merged
Harley Acheson merged 5 commits from Harley/blender:AreaIcons into main 2024-07-12 00:08:35 +02:00
Showing only changes of commit d60c7b1223 - Show all commits

View File

@ -1343,7 +1343,7 @@ static blender::StringRefNull node_space_name_get(ScrArea *area)
static int node_space_icon_get(ScrArea *area)
{
SpaceNode *snode = (SpaceNode *)area->spacedata.first;
SpaceNode *snode = static_cast<SpaceNode *>(area->spacedata.first);
Harley marked this conversation as resolved Outdated

static_cast

`static_cast`

Will post a separate PR changing to static_cast for node_space_name_get and other places in the same file.

Will post a separate PR changing to static_cast for node_space_name_get and other places in the same file.
bke::bNodeTreeType *tree_type = bke::ntreeTypeFind(snode->tree_idname);
return tree_type->ui_icon;
}