mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2025-01-19 00:20:09 +00:00
gtktreemodelfilter: only maintain cache at 1 level depth instead of 2
This commit is contained in:
parent
aa9151a6ee
commit
6cd134d39e
@ -881,8 +881,7 @@ gtk_tree_model_filter_build_level (GtkTreeModelFilter *filter,
|
||||
* possible changes in state of the parent are not requested.
|
||||
*/
|
||||
if (empty &&
|
||||
(parent_level && parent_level->parent_level &&
|
||||
parent_level->parent_elt->ext_ref_count == 0))
|
||||
(parent_level && parent_elt->ext_ref_count == 0))
|
||||
{
|
||||
gtk_tree_model_filter_free_level (filter, new_level, FALSE);
|
||||
return;
|
||||
@ -1190,8 +1189,7 @@ gtk_tree_model_filter_clear_cache_helper (GtkTreeModelFilter *filter,
|
||||
*/
|
||||
if (level->ext_ref_count == 0 && level != filter->priv->root &&
|
||||
level->parent_level && level->parent_elt &&
|
||||
level->parent_level->parent_level &&
|
||||
level->parent_level->parent_elt->ext_ref_count == 0)
|
||||
level->parent_elt->ext_ref_count == 0)
|
||||
{
|
||||
gtk_tree_model_filter_free_level (filter, level, TRUE);
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user