Added polling mechanism.
Refactored ges-lite.js.