Added UI hooks.
Merge pull request #14 from my-koop/mg_uihooks

Added UI hooks