mirror of
https://github.com/Orama-Interactive/Pixelorama.git
synced 2025-01-19 01:29:49 +00:00
Don't let preview animation play if there's only one frame
This commit is contained in:
parent
7269b45fc5
commit
5bbea6fa03
|
@ -13,6 +13,9 @@ func _on_PreviewZoomSlider_value_changed(value : float) -> void:
|
||||||
|
|
||||||
func _on_PlayButton_toggled(button_pressed : bool) -> void:
|
func _on_PlayButton_toggled(button_pressed : bool) -> void:
|
||||||
if button_pressed:
|
if button_pressed:
|
||||||
|
if Global.current_project.frames.size() <= 1:
|
||||||
|
play_button.pressed = false
|
||||||
|
return
|
||||||
canvas_preview.animation_timer.start()
|
canvas_preview.animation_timer.start()
|
||||||
Global.change_button_texturerect(play_button.get_child(0), "pause.png")
|
Global.change_button_texturerect(play_button.get_child(0), "pause.png")
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue