Added fromTime and toTime parameters when setting
and adding animations.