appdelegate - react to sleep/wake