Fix button state (enabled/disabled)
This commit is contained in:
parent
b7e2c9dfa2
commit
25e1542827
1 changed files with 6 additions and 6 deletions
|
@ -41,13 +41,13 @@ func _input(event):
|
|||
#
|
||||
|
||||
func set_buttons_disabled(disabled: bool):
|
||||
if disabled:
|
||||
for b in [open_shader_button, open_image_button, save_image_button, fit_image_button, apply_shader_button, status_indicator]:
|
||||
b.disabled = disabled
|
||||
var btns = []
|
||||
if disabled or (Filesystem.input_image_path != "" and Filesystem.shader_path != ""):
|
||||
btns = [open_shader_button, open_image_button, save_image_button, fit_image_button, apply_shader_button, status_indicator]
|
||||
else:
|
||||
for b in [open_shader_button, open_image_button, fit_image_button, apply_shader_button, status_indicator]:
|
||||
b.disabled = disabled
|
||||
|
||||
btns = [open_shader_button, open_image_button, fit_image_button, apply_shader_button, status_indicator]
|
||||
for b in btns:
|
||||
b.disabled = disabled
|
||||
#
|
||||
|
||||
func _on_open_shader_button_pressed():
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue