Outliner: Correct check for element culling

I don't see a reason to use 2x the element height for the "in-view"
checks. That seems incorrect (although shouldn't cause issues). So
remove that, I don't expect behavior changes.
This commit is contained in:
Julian Eisel 2022-03-09 15:22:35 +01:00
parent c4d3d10401
commit 8e3a58578a
1 changed files with 1 additions and 1 deletions

View File

@ -388,7 +388,7 @@ bool outliner_is_element_visible(const TreeElement *te)
bool outliner_is_element_in_view(const TreeElement *te, const View2D *v2d)
{
return ((te->ys + 2 * UI_UNIT_Y) >= v2d->cur.ymin) && (te->ys <= v2d->cur.ymax);
return ((te->ys + UI_UNIT_Y) >= v2d->cur.ymin) && (te->ys <= v2d->cur.ymax);
}
bool outliner_item_is_co_over_name_icons(const TreeElement *te, float view_co_x)