hide overlay when leaving application