Remove an unnecessary check

Since the demise of theme engines, we can no longer hit
the case of id >= GTK_CSS_PROPERTY_N_PROPERTIES. So don't
check for this in a very frequently called function.
This commit is contained in:
Matthias Clasen 2017-01-10 19:53:08 -05:00
parent c1dc36dff0
commit 9133ec5cd4

View File

@ -46,13 +46,6 @@ gtk_css_static_style_get_value (GtkCssStyle *style,
{
GtkCssStaticStyle *sstyle = GTK_CSS_STATIC_STYLE (style);
if (G_UNLIKELY (id >= GTK_CSS_PROPERTY_N_PROPERTIES))
{
GtkCssStyleProperty *prop = _gtk_css_style_property_lookup_by_id (id);
return _gtk_css_style_property_get_initial_value (prop);
}
return sstyle->values[id];
}