craftyjs/Crafty — pull request #664 by starwed (2013-12-24 08:57:10+00:00)
Title: Fix problem with DOM sprite animation in webkit browsers

The backgroundPosition CSS attribute isn't always getting set correctly in Safari. This seems to be some sort of hard to trigger webkit-only bug that occurs when we do sprite animation, but not when setting regular sprite positions.

I was unable to produce a simple test case without using Crafty, so I'm not sure what the exact problem is. This "fixes" things by setting the background position separately from the rest of the background properties.

This fixes issue #656.