From 0ba5e1f394911c66441ea770e09338e82fb6ef49 Mon Sep 17 00:00:00 2001 From: Rémi Tétreault Date: Sun, 30 Apr 2017 15:14:11 -0400 Subject: fixed `SVG.FX.once` so that it add its callback on the last situation instead of the current one --- src/fx.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src') diff --git a/src/fx.js b/src/fx.js index f9fbbc7..a4d0ecd 100644 --- a/src/fx.js +++ b/src/fx.js @@ -660,10 +660,10 @@ SVG.FX = SVG.invent({ // adds an once-callback which is called at a specific position and never again , once: function(pos, fn, isEased){ + var c = this.last() + if(!isEased) pos = c.ease(pos) - if(!isEased)pos = this.situation.ease(pos) - - this.situation.once[pos] = fn + c.once[pos] = fn return this } -- cgit v1.2.3