mirror of
https://github.com/Relintai/broken_seals.git
synced 2024-11-20 21:07:17 +01:00
Small improvements to the slot and int fields of the world generator addon's ResourcePropertyList.
This commit is contained in:
parent
86ff313d6b
commit
701b7c08bc
@ -115,13 +115,14 @@ func add_slot_int(getter : String, setter : String, slot_name : String, prange :
|
||||
|
||||
var l : Label = Label.new()
|
||||
l.text = slot_name
|
||||
l.size_flags_horizontal = SIZE_EXPAND_FILL
|
||||
# l.size_flags_horizontal = SIZE_EXPAND_FILL
|
||||
bc.add_child(l)
|
||||
|
||||
var sb : SpinBox = SpinBox.new()
|
||||
sb.rounded = true
|
||||
sb.min_value = prange.x
|
||||
sb.max_value = prange.y
|
||||
sb.set_h_size_flags(SIZE_EXPAND_FILL)
|
||||
bc.add_child(sb)
|
||||
|
||||
var slot_idx : int = add_slot(getter, setter, bc)
|
||||
@ -149,7 +150,7 @@ func add_slot_float(getter : String, setter : String, slot_name : String, step :
|
||||
|
||||
var l : Label = Label.new()
|
||||
l.text = slot_name
|
||||
l.size_flags_horizontal = SIZE_EXPAND_FILL
|
||||
# l.size_flags_horizontal = SIZE_EXPAND_FILL
|
||||
bc.add_child(l)
|
||||
|
||||
var sb : SpinBox = SpinBox.new()
|
||||
@ -161,6 +162,7 @@ func add_slot_float(getter : String, setter : String, slot_name : String, step :
|
||||
sb.min_value = prange.x
|
||||
sb.max_value = prange.y
|
||||
sb.value = _edited_resource.call(getter)
|
||||
sb.set_h_size_flags(SIZE_EXPAND_FILL)
|
||||
|
||||
sb.connect("value_changed", self, "on_float_spinbox_value_changed", [ slot_idx ])
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user