fixed the initial flicker on click, various performance improvements
Merge pull request #1 from adamschroder/master

Fix for flicker on initial click, various performance improvements