Open Phoscur opened 10 years ago
There is a bug in the current code that causes some events to not be sent to your callback function all the time.
The solution I used, which works for handling all events as they are called, in order, is to replace the function asyncCallback with the one below:
/**
* Call callback asynchronously for better performance
*/
function asyncCallback(e)
{
if (ft.callback)
{
// Remove empty values
var events = [];
e.map(function (e, i) { if (e) { events.push(e); } });
//clearTimeout(timeout);
//timeout = setTimeout(function () { if (ft.callback) { ft.callback(ft, events); } }, 1);
if (ft.callback) { ft.callback(ft, events); }
}
}
Updating this library breaks my code:
Inspecting this, only "init", "apply" and "drag end" events are fired. Reverting to older freeTransform revision.