chriseppstein/compass — pull request #595 by brainopia (2011-10-08 22:43:18+00:00)
Title: Optimizations for sprites

Hello, I've been profiling performance of sprite generation and noticed a couple of places which can be improved.

First of all, SpriteMap doesn't reset stored `mtime` of sprite after regeneration so not only first call to old sprite invokes regeneration but all subsequent ones too.

Secondly, `stat` call is issued for every sprite image when a few can be enough to see that sprite is outdated.

I've fixed aforementioned issues and removed trailing whitespace too :)