mirror of
https://github.com/zoriya/astal.git
synced 2026-06-01 09:45:31 +00:00
rename: box implicit_destroy to no_implicit_destroy
This commit is contained in:
@@ -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<weak Gtk.Widget> children {
|
||||
set { _set_children(value); }
|
||||
@@ -42,10 +42,10 @@ public class Box : Gtk.Box {
|
||||
|
||||
private void _set_children(List<weak Gtk.Widget> 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)
|
||||
|
||||
Reference in New Issue
Block a user