From f5d5376ff90b7fef5016fef23d832c9929399785 Mon Sep 17 00:00:00 2001 From: Aylur Date: Mon, 2 Sep 2024 17:10:50 +0000 Subject: rename: box implicit_destroy to no_implicit_destroy --- core/src/widget/box.vala | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'core/src') diff --git a/core/src/widget/box.vala b/core/src/widget/box.vala index 39dee92..6bd1bcb 100644 --- a/core/src/widget/box.vala +++ b/core/src/widget/box.vala @@ -9,7 +9,7 @@ public class Box : Gtk.Box { /** * wether to implicity destroy previous children when setting them */ - public bool implicit_destroy { get; set; default = true; } + public bool no_implicit_destroy { get; set; default = false; } public List children { set { _set_children(value); } @@ -42,10 +42,10 @@ public class Box : Gtk.Box { private void _set_children(List arr) { foreach(var child in get_children()) { - if (implicit_destroy && arr.find(child).length() == 0) - child.destroy(); - else + if (no_implicit_destroy) remove(child); + else if (arr.find(child).length() == 0) + child.destroy(); } foreach(var child in arr) -- cgit v1.2.3