aboutsummaryrefslogtreecommitdiff
path: root/client/menu/settings/settings_category.gd
diff options
context:
space:
mode:
Diffstat (limited to 'client/menu/settings/settings_category.gd')
-rw-r--r--client/menu/settings/settings_category.gd13
1 files changed, 5 insertions, 8 deletions
diff --git a/client/menu/settings/settings_category.gd b/client/menu/settings/settings_category.gd
index a80c12c9..4f5fbbc4 100644
--- a/client/menu/settings/settings_category.gd
+++ b/client/menu/settings/settings_category.gd
@@ -30,20 +30,17 @@ func set_parent(parent: GameSetting):
c.set_parent(self)
func _update_row():
- if row == null: row = ScrollContainerCustom.new()
- if options == null: options = VBoxContainer.new()
+ var row = ScrollContainerCustom.new()
+ var options = VBoxContainer.new()
row.name = tr(nskey)
row.size_flags_horizontal = Control.SIZE_EXPAND_FILL
options.size_flags_horizontal = Control.SIZE_EXPAND_FILL
-
- if options.get_parent() != row:
- row.add_child(options)
+ row.add_child(options)
for r in settings:
r._update_row()
- print(r.row)
- if r.row.get_parent() != options:
- options.add_child(r.row)
+ options.add_child(r.row)
+ return row
func check():
for c in settings: