1
0
Fork 0
mirror of https://github.com/Orama-Interactive/Pixelorama.git synced 2025-01-18 17:19:50 +00:00

Optimize linked cels emitting the texture_changed signal, if multiple cels are selected

This commit is contained in:
Emmanouil Papadeas 2023-05-09 01:29:03 +03:00
parent 6b94b55f04
commit 3052d2756e

View file

@ -49,8 +49,11 @@ func get_image() -> Image:
func update_texture() -> void:
emit_signal("texture_changed")
if link_set != null:
for cel in link_set["cels"]:
cel.emit_signal("texture_changed")
var frame: int = Global.current_project.current_frame
# This check is needed in case the user has selected multiple cels that are also linked
if self in Global.current_project.frames[frame].cels:
for cel in link_set["cels"]:
cel.emit_signal("texture_changed")
return