I noticed that the callback argument to TweenLite.delayedCall is typed Void->Void. However, we clearly want to be able to supply a callback that might accept any number of arguments, that will be passed the contents of the optional params array. As also explained in the GSAP documentation.
so that the types match. Do you think there is a good fix for this? Obviously it depends a great deal on how the callback is evoked by the underlying GSAP library.
Hello there
I noticed that the
callback
argument toTweenLite.delayedCall
is typedVoid->Void
. However, we clearly want to be able to supply a callback that might accept any number of arguments, that will be passed the contents of the optionalparams
array. As also explained in the GSAP documentation.Here is the relevant line.
For the time being I have replaced
TweenLite.delayedCall( delay, myCallback, [a,b,c])
with
TweenLite.delayedCall( delay, myCallback.bind(a,b,c))
so that the types match. Do you think there is a good fix for this? Obviously it depends a great deal on how the callback is evoked by the underlying GSAP library.
Thoughts? -colin