Merge pull request #113 from rogerhu/push_notify

Initial framework for push notifications
We need this if else since apparently lines after startActivity calls() still take time to happen.