Fixed up current warnings.

Implemented the base of the event driven main loop.
Merge pull request #5 from codyjackson/event_driven_main_loop

Fixed warnings. Implemented the base of the event driven main loop.