make button closeable
This commit is contained in:
parent
c561e855e1
commit
dc7962a45d
|
|
@ -195,7 +195,10 @@ func _ready():
|
||||||
self.connect(\"toggled\", Callable(self, \"_on_toggled\"))
|
self.connect(\"toggled\", Callable(self, \"_on_toggled\"))
|
||||||
|
|
||||||
func _on_toggled(was_button_pressed: bool):
|
func _on_toggled(was_button_pressed: bool):
|
||||||
|
if get_parent().get_child(1).visible == false:
|
||||||
get_parent().get_child(1).visible = was_button_pressed
|
get_parent().get_child(1).visible = was_button_pressed
|
||||||
|
else:
|
||||||
|
get_parent().get_child(1).visible = false
|
||||||
"
|
"
|
||||||
|
|
||||||
[node name="Startup Menu" type="Panel"]
|
[node name="Startup Menu" type="Panel"]
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue