Simplify if statement

And make the end of st_theme_node_lookup_length() consistent with
st_theme_node_lookup_color() and st_theme_node_lookup_shadow().

Part of https://gitlab.gnome.org/GNOME/gnome-shell/issues/1934
This commit is contained in:
Federico Mena Quintero 2019-11-21 17:02:37 -06:00 committed by Florian Müllner
parent 05c3ac2359
commit 1e8e08ce61

View File

@ -1193,10 +1193,9 @@ st_theme_node_lookup_length (StThemeNode *node,
else if (result == VALUE_INHERIT) else if (result == VALUE_INHERIT)
inherit = TRUE; inherit = TRUE;
if (inherit && node->parent_node && if (inherit && node->parent_node)
st_theme_node_lookup_length (node->parent_node, property_name, inherit, length)) return st_theme_node_lookup_length (node->parent_node, property_name, inherit, length);
return TRUE;
else
return FALSE; return FALSE;
} }