fixing way we animate GIfs so garbage collection works